[llvm] [PowerPC][AIX] Emit PowerPC version for XCOFF (PR #95510)
Chen Zheng via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 5 03:17:20 PDT 2024
================
@@ -107,6 +108,61 @@ StringRef XCOFF::getNameForTracebackTableLanguageId(
}
#undef LANG_CASE
+XCOFF::CFileCpuId XCOFF::getCpuID(StringRef CPU) {
+ return StringSwitch<XCOFF::CFileCpuId>(CPU)
+ .Case("generic", XCOFF::TCPU_PWR7)
+ .Case("601", XCOFF::TCPU_601)
+ .Cases("602", "603", "603e", "603ev", XCOFF::TCPU_603)
+ .Cases("604", "604e", XCOFF::TCPU_604)
+ .Case("620", XCOFF::TCPU_620)
+ .Case("970", XCOFF::TCPU_970)
+ .Cases("pwr3", "power3", "pwr4", "power4", "COM", XCOFF::TCPU_COM)
+ .Cases("pwr5", "power5", "PWR5", XCOFF::TCPU_PWR5)
+ .Cases("pwr5x", "power5x", "PWR5X", XCOFF::TCPU_PWR5X)
+ .Cases("pwr6", "power6", "PWR6", XCOFF::TCPU_PWR6)
+ .Cases("pwr6x", "power6x", "PWR6E", XCOFF::TCPU_PWR6E)
+ .Cases("pwr7", "power7", "PWR7", XCOFF::TCPU_PWR7)
+ .Cases("pwr8", "power8", "PWR8", XCOFF::TCPU_PWR8)
+ .Cases("pwr9", "power9", "PWR9", XCOFF::TCPU_PWR9)
+ .Cases("pwr10", "power10", "PWR10", XCOFF::TCPU_PWR10)
+ .Cases("powerpc", "ppc", "ppc32", XCOFF::TCPU_ANY)
+ .Cases("powerpc64", "ppc64", "powerpc64le", "ppc64le", "PPC64",
----------------
chenzheng1030 wrote:
PPC64LE is actually pwr8 in CLANG
https://github.com/llvm/llvm-project/pull/95510
More information about the llvm-commits
mailing list