[clang] [llvm] [PowerPC][X86] Make cpu id builtins target independent and lower for PPC (PR #68919)
via cfe-commits
cfe-commits at lists.llvm.org
Tue Nov 14 10:34:54 PST 2023
================
@@ -2110,6 +2110,66 @@ static bool checkFPMathBuiltinElementType(Sema &S, SourceLocation Loc,
return false;
}
+/// SemaBuiltinCpuSupports - Handle __builtin_cpu_supports(char *).
+/// This checks that the target supports __builtin_cpu_supports and
+/// that the string argument is constant and valid.
+static bool SemaBuiltinCpuSupports(Sema &S, const TargetInfo &TI,
----------------
diggerlin wrote:
most of the source code of function `SemaBuiltinCpuSupports` and `SemaBuiltinCpuIs` are same , we can add helper function to reduce the code.
https://github.com/llvm/llvm-project/pull/68919
More information about the cfe-commits
mailing list