diff options
author | Devang Patel <dpatel@apple.com> | 2008-02-21 01:41:25 +0000 |
---|---|---|
committer | Devang Patel <dpatel@apple.com> | 2008-02-21 01:41:25 +0000 |
commit | c6f915e40dca32e111e3582294eef76bfdf04247 (patch) | |
tree | 605ba2ceb669758492ea715e89e8a71aea531907 /llvm/tools/llvm-as/llvm-as.cpp | |
parent | 05d8cca8b67ad8b0dbb8f055465198791d77ee5b (diff) | |
download | bcm5719-llvm-c6f915e40dca32e111e3582294eef76bfdf04247.tar.gz bcm5719-llvm-c6f915e40dca32e111e3582294eef76bfdf04247.zip |
Add -disable-output option.
llvm-svn: 47422
Diffstat (limited to 'llvm/tools/llvm-as/llvm-as.cpp')
-rw-r--r-- | llvm/tools/llvm-as/llvm-as.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/llvm/tools/llvm-as/llvm-as.cpp b/llvm/tools/llvm-as/llvm-as.cpp index 026533634ee..d9fa1fa7f40 100644 --- a/llvm/tools/llvm-as/llvm-as.cpp +++ b/llvm/tools/llvm-as/llvm-as.cpp @@ -40,6 +40,9 @@ static cl::opt<bool> 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 @@ int main(int argc, char **argv) { 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; |