[PATCH] D152914: [Draft] Make __builtin_cpu builtins target-independent
Pavel Iliin via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Jul 19 15:52:18 PDT 2023
ilinpv added a comment.
In D152914#4497599 <https://reviews.llvm.org/D152914#4497599>, @nemanjai wrote:
> I took a quick look at your patch. I think it would be preferable to make the builtins target-independent rather than implementing the builtin by the same name for multiple targets. Although I think it is very useful to support a plus-separated list for `__builtin_cpu_supports()`, I think that's probably something for a subsequent patch. We would need to figure out code generation for that - perhaps that part will have to be completely target specific.
I fully agree with you to make `__builtin_cpu_supports()` target-independent ( and I will update my patch on top of yours ). If plus-separated format is not supported by all target then I would suggest to make SemaBuiltinCpuSupports target-dependent - it will allow me to imlement plus-separated format on AArch64 keeping `__builtin_cpu_supports()` target-independent.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D152914/new/
https://reviews.llvm.org/D152914
More information about the cfe-commits
mailing list