[clang] [clang] Add use-sample-profile attribute to thread-local wrapper (PR #245514)
via cfe-commits
cfe-commits at lists.llvm.org
Fri Nov 27 01:40:15 PST 2026
XinlongZHANG-Bob wrote:
> If we aren't calling SetLLVMFunctionAttributesForDefinition on some definition, that's a bug.
>
> If an attribute makes sense on synthetic functions, the code to set it should probably not be in StartFunction.
I move setting `use-sample-profile` from `StartFunction` to `SetLLVMFunctionAttributesForDefinition` and fix case 1 to 3.
For case 4 [#234415](https://github.com/llvm/llvm-project/pull/234415) is better fix.
https://github.com/llvm/llvm-project/pull/245514
More information about the cfe-commits
mailing list