Forward -save-temps to llvm-gcc.
authorMikhail Glushenkov <foldr@codedgers.com>
Tue, 1 Dec 2009 06:51:30 +0000 (06:51 +0000)
committerMikhail Glushenkov <foldr@codedgers.com>
Tue, 1 Dec 2009 06:51:30 +0000 (06:51 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@90214 91177308-0d34-0410-b5e6-96231b3b80d8

tools/llvmc/plugins/Base/Base.td.in
utils/TableGen/LLVMCConfigurationEmitter.cpp

index 0f481e270d7f3e5f1a3eb41c6c444ce7e21f2e5c..4acb1bd92177d64e50f2f71d9e7e639845e9f9c9 100644 (file)
@@ -111,6 +111,7 @@ class llvm_gcc_based <string cmd_prefix, string in_lang, string E_ext> : Tool<
          (and (switch_on "emit-llvm"), (switch_on "c")), (stop_compilation),
          (switch_on "fsyntax-only"), (stop_compilation),
          (not_empty "include"), (forward "include"),
+         (not_empty "save-temps"), (append_cmd "-save-temps"),
          (not_empty "I"), (forward "I"),
          (not_empty "F"), (forward "F"),
          (not_empty "D"), (forward "D"),
index 546988a10e4d1cf9d027130e772789d743854809..8b55b81eae46dd9910c2f2b4f6a86248e1511690 100644 (file)
@@ -1155,6 +1155,9 @@ public:
     if (OptName == "o") {
       O << Neg << "OutputFilename.empty()";
     }
+    else if (OptName == "save-temps") {
+      O << Neg << "(SaveTemps == SaveTempsEnum::Unset)";
+    }
     else {
       const OptionDescription& OptDesc = OptDescs_.FindListOrParameter(OptName);
       O << Neg << OptDesc.GenVariableName() << ".empty()";