[llvm-commits] [llvm] r47422 - /llvm/trunk/tools/llvm-as/llvm-as.cpp
Devang Patel
dpatel at apple.com
Wed Feb 20 17:41:25 PST 2008
Author: dpatel
Date: Wed Feb 20 19:41:25 2008
New Revision: 47422
URL: http://llvm.org/viewvc/llvm-project?rev=47422&view=rev
Log:
Add -disable-output option.
Modified:
llvm/trunk/tools/llvm-as/llvm-as.cpp
Modified: llvm/trunk/tools/llvm-as/llvm-as.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-as/llvm-as.cpp?rev=47422&r1=47421&r2=47422&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-as/llvm-as.cpp (original)
+++ llvm/trunk/tools/llvm-as/llvm-as.cpp Wed Feb 20 19:41:25 2008
@@ -40,6 +40,9 @@
Force("f", cl::desc("Overwrite output files"));
static cl::opt<bool>
+DisableOutput("disable-output", cl::desc("Disable output"), cl::init(false));
+
+static cl::opt<bool>
DumpAsm("d", cl::desc("Print assembly as parsed"), cl::Hidden);
static cl::opt<bool>
@@ -125,8 +128,9 @@
return 1;
}
- if (Force || !CheckBitcodeOutputToConsole(Out,true))
- WriteBitcodeToFile(M.get(), *Out);
+ if (!DisableOutput)
+ if (Force || !CheckBitcodeOutputToConsole(Out,true))
+ WriteBitcodeToFile(M.get(), *Out);
} catch (const std::string& msg) {
cerr << argv[0] << ": " << msg << "\n";
exitCode = 1;
More information about the llvm-commits
mailing list