[clang] [llvm] [PowerPC] add TargetParser for PPC target (PR #97541)

Chen Zheng via cfe-commits cfe-commits at lists.llvm.org
Fri Jul 5 03:53:56 PDT 2024


================
@@ -85,8 +85,59 @@
 #define AIX_PPC9_VALUE 0x00020000
 #define AIX_PPC10_VALUE 0x00040000
 
-// __builtin_cpu_is() and __builtin_cpu_supports() are supported only on Power7 and up on AIX.
 // PPC_CPU(Name, Linux_SUPPORT_METHOD, LinuxID, AIX_SUPPORT_METHOD, AIXID)
+
+// Valid CPUs not supported by __builtin_cpu_is()
+PPC_CPU("generic",BUILTIN_PPC_FALSE,0,BUILTIN_PPC_FALSE,0)
+PPC_CPU("440",SYS_CALL,42,BUILTIN_PPC_FALSE,0)
----------------
chenzheng1030 wrote:

I added some cpu checks in `clang/test/CodeGen/builtin-cpu-supports.c`.

https://github.com/llvm/llvm-project/pull/97541


More information about the cfe-commits mailing list