dexonsmith added a comment.
In D134456#3827263 <https://reviews.llvm.org/D134456#3827263>, @aaron.ballman
wrote:
> My worry is that parallel attributes will be used as:
>
> #if __has_cpp_attribute(clang::likely_but_honor_this_one)
> #define LIKELY [[clang::likely_but_honor_this_one]]
> #elif __has_cpp_attribute(likely)
> #define LIKELY [[likely]]
> #else
> #define LIKELY
> #endif
To be clear, I was imagining:
if (always_false()) [[likely]] [[clang::nopgo]] {
// ...
}
where ``nopgo`` might be independently useful for telling clang to ignore any
collected PGO data when estimating branch weights in a particular control flow
block.
Some users might combine the two into a macro ("always ignore the profile when
I say something is likely!"), but I don't think there'd be a cascade.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D134456/new/
https://reviews.llvm.org/D134456
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits