[clang] [compiler-rt] [AArch64] Implement __builtin_cpu_supports, compiler-rt tests. (PR #82378)
via cfe-commits
cfe-commits at lists.llvm.org
Wed Feb 28 08:05:17 PST 2024
DanielKristofKiss wrote:
> Hello,
>
> This patch makes the second line fail to compile
>
> ```
> #elif ABSL_HAVE_BUILTIN(__builtin_cpu_supports)
> if (__builtin_cpu_supports("avx2")) {
> ```
>
> `error: invalid cpu feature string for builtin` when built on arm
expected to fail as __builtin_cpu_supports now supported on Arm too, something like this would be better:
`#elif ABSL_HAVE_BUILTIN(__builtin_cpu_supports) && (defined(__x86_64__) || defined(__i386__)`
https://github.com/llvm/llvm-project/pull/82378
More information about the cfe-commits
mailing list