summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2003-02-12 18:43:33 +0000
committerChris Lattner <sabre@nondot.org>2003-02-12 18:43:33 +0000
commit4dbe59b5ba77c78160fbe437d74a5cb38e67f3ef (patch)
treef6dd70a3653fb5e230fb8eebfd0f47a2571d8381
parentca959ff6fd6df88e96a6b2967a23dfbc2006acc6 (diff)
downloadbcm5719-llvm-4dbe59b5ba77c78160fbe437d74a5cb38e67f3ef.tar.gz
bcm5719-llvm-4dbe59b5ba77c78160fbe437d74a5cb38e67f3ef.zip
Add a new -no-output option, useful for -aa-eval tests.
llvm-svn: 5541
-rw-r--r--llvm/tools/opt/opt.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/llvm/tools/opt/opt.cpp b/llvm/tools/opt/opt.cpp
index de56080c2c1..9d0837c29d7 100644
--- a/llvm/tools/opt/opt.cpp
+++ b/llvm/tools/opt/opt.cpp
@@ -48,6 +48,9 @@ static cl::opt<bool>
PrintEachXForm("p", cl::desc("Print module after each transformation"));
static cl::opt<bool>
+NoOutput("no-output", cl::desc("Do not write result bytecode file"), cl::Hidden);
+
+static cl::opt<bool>
Quiet("q", cl::desc("Don't print 'program modified' message"));
static cl::alias
@@ -128,7 +131,8 @@ int main(int argc, char **argv) {
Passes.add(createVerifierPass());
// Write bytecode out to disk or cout as the last step...
- Passes.add(new WriteBytecodePass(Out, Out != &std::cout));
+ if (!NoOutput)
+ Passes.add(new WriteBytecodePass(Out, Out != &std::cout));
// Now that we have all of the passes ready, run them.
if (Passes.run(*M.get()) && !Quiet)
OpenPOWER on IntegriCloud