[Preprocessor] Fix __has_builtin for CPU ID functions (#80058)
My recent commit (67c1c1db) made the CPU ID builtins target-independent so they can be used on PPC as well. However, that had the unintended consequence of changing the behaviour of __has_builtin in that it reports these as supported at the pre-processor level. This makes it impossible to guard the use of these with this feature test macro which is clearly not ideal. This patch restores the behaviour of __has_builtin for __builtin_cpu_is, __builtin_cpu_init, __builtin_cpu_supports. Now the preprocessor queries the target to determine whether the target supports the builtin.
parent
acf6811d
Please register or sign in to comment