Allow compiler generated functions like __clang_call_terminate to be
blocked in the special case list (SCL) passed by the -fprofile-list= option.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
clang/lib/CodeGen/CodeGenModule.cpp | ||
---|---|---|
3894–3896 | Do we still need https://github.com/llvm/llvm-project/blob/759e5e0096f650515799805828f9ac5b7d4a7303/clang/lib/CodeGen/CodeGenFunction.cpp#L856 if we set the attribute here? |
clang/lib/CodeGen/CodeGenModule.cpp | ||
---|---|---|
3894–3896 | Both are needed. Here the attribute is added in GetOrCreateLLVMFunction() which I believe only creates compiler generated functions. Where you linked is called when normal functions are generated. |
clang/lib/CodeGen/CodeGenModule.cpp | ||
---|---|---|
3894–3896 | Oh sorry, I was mistaken. I'd like to figure out how to only have this code in one location. |
The function __clang_call_terminate seems to be a special case that clang builds itself. This diff might be too much for this rare specific case. Closing.
Do we still need https://github.com/llvm/llvm-project/blob/759e5e0096f650515799805828f9ac5b7d4a7303/clang/lib/CodeGen/CodeGenFunction.cpp#L856 if we set the attribute here?