aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-08-27 22:40:26 +0000
committerChris Lattner <sabre@nondot.org>2006-08-27 22:40:26 +0000
commit3b2493e2a19ef7186023a3b3ccb66356a297de67 (patch)
tree76af3ba9ae4fdabf9d33a4c8de6a27686f2fdeda /tools
parent43d64b85263ea44f021c933f0803198e04e2a76c (diff)
downloadexternal_llvm-3b2493e2a19ef7186023a3b3ccb66356a297de67.zip
external_llvm-3b2493e2a19ef7186023a3b3ccb66356a297de67.tar.gz
external_llvm-3b2493e2a19ef7186023a3b3ccb66356a297de67.tar.bz2
-analyze mode shouldn't output a .bc file.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@29923 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools')
-rw-r--r--tools/opt/opt.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/tools/opt/opt.cpp b/tools/opt/opt.cpp
index 4394c98..5c61549 100644
--- a/tools/opt/opt.cpp
+++ b/tools/opt/opt.cpp
@@ -30,7 +30,6 @@
#include <fstream>
#include <memory>
#include <algorithm>
-
using namespace llvm;
// The OptimizationList is automatically populated with registered Passes by the
@@ -250,7 +249,7 @@ int main(int argc, char **argv) {
Passes.add(createVerifierPass());
// Write bytecode out to disk or cout as the last step...
- if (!NoOutput)
+ if (!NoOutput && !AnalyzeOnly)
Passes.add(new WriteBytecodePass(Out, Out != &std::cout));
// Now that we have all of the passes ready, run them.