[llvm] 5724c8b - Temporarily revert D83903 "[PGO] Enable the extended value profile buckets for mem op sizes."
Fangrui Song via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 22 13:12:28 PDT 2020
Author: Fangrui Song
Date: 2020-07-22T13:12:19-07:00
New Revision: 5724c8ba29baef986a4a9ee77df98f638ee9e641
URL: https://github.com/llvm/llvm-project/commit/5724c8ba29baef986a4a9ee77df98f638ee9e641
DIFF: https://github.com/llvm/llvm-project/commit/5724c8ba29baef986a4a9ee77df98f638ee9e641.diff
LOG: Temporarily revert D83903 "[PGO] Enable the extended value profile buckets for mem op sizes."
`__llvm_profile_instrument_memop` transitively calls calloc, thus calloc
should not be instrumented.
I saw a
`calloc -> __llvm_profile_instrument_memop -> calloc -> __llvm_profile_instrument_memop -> ...`
infinite loop leading to stack overflow
when the malloc implementation (e.g. tcmalloc) is built and instrumented along with the application.
We should figure out the library calls which may be instrumented and disable
their instrumentation before rolling out this change.
Reviewed By: yamauchi
Differential Revision: https://reviews.llvm.org/D84358
Added:
Modified:
llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp b/llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp
index c2e4e932e77b..0a3519502994 100644
--- a/llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp
+++ b/llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp
@@ -78,7 +78,7 @@ cl::opt<bool> UseOldMemOpValueProf(
"use-old-memop-value-prof",
cl::desc("Use the old memop value profiling buckets. This is "
"transitional and to be removed after switching. "),
- cl::init(false));
+ cl::init(true));
namespace {
More information about the llvm-commits
mailing list