diff options
author | Peter Bell <peterbell10@live.co.uk> | 2021-08-25 23:58:31 (GMT) |
---|---|---|
committer | Peter Bell <peterbell10@live.co.uk> | 2021-08-27 18:42:31 (GMT) |
commit | 5b8d19b24b00973976990303524f47750e3e1dc4 (patch) | |
tree | 28c78861c281e070bea15a7c6247ce7e62c6e8ba /src | |
parent | 63b0a9a6a170793f98aa22da827ee3ac11eb1a50 (diff) | |
download | Ninja-5b8d19b24b00973976990303524f47750e3e1dc4.zip Ninja-5b8d19b24b00973976990303524f47750e3e1dc4.tar.gz Ninja-5b8d19b24b00973976990303524f47750e3e1dc4.tar.bz2 |
Fix total_time computation
Diffstat (limited to 'src')
-rw-r--r-- | src/build.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/build.cc b/src/build.cc index fd220e5..08b0cc6 100644 --- a/src/build.cc +++ b/src/build.cc @@ -492,7 +492,9 @@ void Plan::ComputeCriticalTime(BuildLog* build_log) { edge->run_time_ms_ = 1; continue; } - edge->run_time_ms_ = entry->end_time - entry->start_time; + const int64_t duration = entry->end_time - entry->start_time; + edge->run_time_ms_ = duration; + total_time += duration; } // Use backflow algorithm to compute critical times for all nodes, starting |