Skip to content

Commit

Permalink
Fix typo in time passes
Browse files Browse the repository at this point in the history
Summary:
Previously NamedRegionTimer's constructor was being called
with no local variable associated with it owing to a typo. We need a
local variable to keep track of the time spent in the scope. At the
end of the scope, the destructor will be called an then the timer will
stop.

(cherry picked from FBD4301844)
  • Loading branch information
rafaelauler authored and maksfb committed Dec 8, 2016
1 parent c570038 commit 06caefd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bolt/BinaryPassManager.cpp
Expand Up @@ -156,7 +156,7 @@ void BinaryFunctionPassManager::runPasses() {

auto &Pass = OptPassPair.second;

NamedRegionTimer(Pass->getName(), TimerGroupName, TimeOpts);
NamedRegionTimer T(Pass->getName(), TimerGroupName, TimeOpts);

callWithDynoStats(
[this,&Pass] {
Expand Down

0 comments on commit 06caefd

Please sign in to comment.