[clang] [CIR] Add CIRGenerator and plug it via CIRGenAction (PR #90831)

Nathan Lanza via cfe-commits cfe-commits at lists.llvm.org
Fri May 3 00:26:04 PDT 2024


================
@@ -2900,7 +2900,7 @@ defm clangir : BoolFOption<"clangir",
   PosFlag<SetTrue, [], [ClangOption, CC1Option], "Use the ClangIR pipeline to compile">,
   NegFlag<SetFalse, [], [ClangOption, CC1Option], "Use the AST -> LLVM pipeline to compile">,
   BothFlags<[], [ClangOption, CC1Option], "">>;
-def emit_cir : Flag<["-"], "emit-cir">, Visibility<[CC1Option]>,
+def emit_cir : Flag<["-"], "emit-cir">, Visibility<[ClangOption, CC1Option]>,
----------------
lanza wrote:

I had to readd this. The code in `lib/Driver/Driver.cpp:4810`ish needs to know the file output type from flags to the driver. So we need **a driver flag**. And if we need a driver flag then we might as well merge it with one that correctly feeds the emission type along as well.

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


More information about the cfe-commits mailing list