diff --git a/clang/include/clang/Basic/BuiltinsRISCV.def b/clang/include/clang/Basic/BuiltinsRISCV.def --- a/clang/include/clang/Basic/BuiltinsRISCV.def +++ b/clang/include/clang/Basic/BuiltinsRISCV.def @@ -17,3 +17,4 @@ #include "clang/Basic/riscv_vector_builtins.inc" +#undef BUILTIN diff --git a/clang/utils/TableGen/RISCVVEmitter.cpp b/clang/utils/TableGen/RISCVVEmitter.cpp --- a/clang/utils/TableGen/RISCVVEmitter.cpp +++ b/clang/utils/TableGen/RISCVVEmitter.cpp @@ -881,7 +881,6 @@ else OS << "\"\")\n"; } - OS << "\n#undef BUILTIN\n"; OS << "#undef RISCVV_BUILTIN\n"; }