Speed up the method RequiresStackProtector by checking the intrinsic
value of the call. The original code calls getName() that returns an
allocating std::string on each check. This change removes about 96072 std::string
instances when compiling sqlite3.c; The function was discovered with a
Facebook-internal performance tool.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Unit Tests
Unit Tests
Time | Test | |
---|---|---|
140 ms | linux > Polly.ScopInfo::Unknown Unit Message ("") |
Event Timeline
llvm/lib/CodeGen/StackProtector.cpp | ||
---|---|---|
257 | Can this just be CI->getIntrinsicID() == Intrinsic::stackprotector? |
clang-tidy: warning: 'auto *II' can be declared as 'const auto *II' [llvm-qualified-auto]
not useful