Loading clang/lib/Basic/Targets/Mips.cpp +3 −0 Original line number Diff line number Diff line Loading @@ -189,6 +189,9 @@ void MipsTargetInfo::getTargetDefines(const LangOptions &Opts, Builder.defineMacro("_MIPS_ARCH", "\"" + CPU + "\""); Builder.defineMacro("_MIPS_ARCH_" + StringRef(CPU).upper()); if (StringRef(CPU).startswith("octeon")) Builder.defineMacro("__OCTEON__"); // These shouldn't be defined for MIPS-I but there's no need to check // for that since MIPS-I isn't supported. Builder.defineMacro("__GCC_HAVE_SYNC_COMPARE_AND_SWAP_1"); Loading clang/test/Preprocessor/init.c +1 −0 Original line number Diff line number Diff line Loading @@ -4839,6 +4839,7 @@ // MIPS-ARCH-OCTEON:#define _MIPS_ARCH "octeon" // MIPS-ARCH-OCTEON:#define _MIPS_ARCH_OCTEON 1 // MIPS-ARCH-OCTEON:#define _MIPS_ISA _MIPS_ISA_MIPS64 // MIPS-ARCH-OCTEON:#define __OCTEON__ 1 // MIPS-ARCH-OCTEON:#define __mips_isa_rev 2 // // Check MIPS float ABI macros Loading Loading
clang/lib/Basic/Targets/Mips.cpp +3 −0 Original line number Diff line number Diff line Loading @@ -189,6 +189,9 @@ void MipsTargetInfo::getTargetDefines(const LangOptions &Opts, Builder.defineMacro("_MIPS_ARCH", "\"" + CPU + "\""); Builder.defineMacro("_MIPS_ARCH_" + StringRef(CPU).upper()); if (StringRef(CPU).startswith("octeon")) Builder.defineMacro("__OCTEON__"); // These shouldn't be defined for MIPS-I but there's no need to check // for that since MIPS-I isn't supported. Builder.defineMacro("__GCC_HAVE_SYNC_COMPARE_AND_SWAP_1"); Loading
clang/test/Preprocessor/init.c +1 −0 Original line number Diff line number Diff line Loading @@ -4839,6 +4839,7 @@ // MIPS-ARCH-OCTEON:#define _MIPS_ARCH "octeon" // MIPS-ARCH-OCTEON:#define _MIPS_ARCH_OCTEON 1 // MIPS-ARCH-OCTEON:#define _MIPS_ISA _MIPS_ISA_MIPS64 // MIPS-ARCH-OCTEON:#define __OCTEON__ 1 // MIPS-ARCH-OCTEON:#define __mips_isa_rev 2 // // Check MIPS float ABI macros Loading