SuccessChanges

Summary

  1. [Timers] Fix printing some `-ftime-report` sections twice. Fixes PR40328. Starting from r324788 timer groups aren't cleared automatically when printed out. As a result some timer groups were printed one more time. For example, "Pass execution timing report" was printed again in `ManagedStatic<PassTimingInfo>` destructor, "DWARF Emission" in `ManagedStatic<Name2PairMap> NamedGroupedTimers` destructor. Fix by clearing timer groups manually. Reviewers: thegameg, george.karpenkov Reviewed By: thegameg Subscribers: aprantl, jkorous, dexonsmith, ributzka, aras-p, cfe-commits Differential Revision: https://reviews.llvm.org/D67683
  2. [PGO] Change hardcoded thresholds for cold/inlinehint to use summary Summary: The PGO counter reading will add cold and inlinehint (hot) attributes to functions that are very cold or hot. This was using hardcoded thresholds, instead of the profile summary cutoffs which are used in other hot/cold detection and are more dynamic and adaptable. Switch to using the summary-based cold/hot detection. The hardcoded limits were causing some code that had a medium level of hotness (per the summary) to be incorrectly marked with a cold attribute, blocking inlining. Reviewers: davidxl Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D67673
Revision 372191 by vsapsai:
[Timers] Fix printing some `-ftime-report` sections twice. Fixes PR40328.

Starting from r324788 timer groups aren't cleared automatically when
printed out. As a result some timer groups were printed one more time.
For example, "Pass execution timing report" was printed again in
`ManagedStatic<PassTimingInfo>` destructor, "DWARF Emission" in
`ManagedStatic<Name2PairMap> NamedGroupedTimers` destructor.

Fix by clearing timer groups manually.

Reviewers: thegameg, george.karpenkov

Reviewed By: thegameg

Subscribers: aprantl, jkorous, dexonsmith, ributzka, aras-p, cfe-commits

Differential Revision: https://reviews.llvm.org/D67683
Change TypePath in RepositoryPath in Workspace
The file was modified/cfe/trunk/tools/driver/cc1_main.cpp (diff)clang.src/tools/driver/cc1_main.cpp
The file was modified/cfe/trunk/tools/driver/cc1as_main.cpp (diff)clang.src/tools/driver/cc1as_main.cpp
The file was modified/cfe/trunk/tools/driver/driver.cpp (diff)clang.src/tools/driver/driver.cpp
Revision 372189 by tejohnson:
[PGO] Change hardcoded thresholds for cold/inlinehint to use summary

Summary:
The PGO counter reading will add cold and inlinehint (hot) attributes
to functions that are very cold or hot. This was using hardcoded
thresholds, instead of the profile summary cutoffs which are used in
other hot/cold detection and are more dynamic and adaptable. Switch
to using the summary-based cold/hot detection.

The hardcoded limits were causing some code that had a medium level of
hotness (per the summary) to be incorrectly marked with a cold
attribute, blocking inlining.

Reviewers: davidxl

Subscribers: llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D67673
Change TypePath in RepositoryPath in Workspace
The file was modified/llvm/trunk/lib/ProfileData/InstrProfReader.cpp (diff)llvm.src/lib/ProfileData/InstrProfReader.cpp
The file was modified/llvm/trunk/lib/Transforms/Instrumentation/PGOInstrumentation.cpp (diff)llvm.src/lib/Transforms/Instrumentation/PGOInstrumentation.cpp
The file was modified/llvm/trunk/test/Transforms/PGOProfile/Inputs/func_entry.proftext (diff)llvm.src/test/Transforms/PGOProfile/Inputs/func_entry.proftext
The file was modified/llvm/trunk/test/Transforms/PGOProfile/func_entry.ll (diff)llvm.src/test/Transforms/PGOProfile/func_entry.ll