aboutsummaryrefslogtreecommitdiff
path: root/lib/Driver/Driver.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2011-04-18 19:44:09 +0000
committerDaniel Dunbar <daniel@zuster.org>2011-04-18 19:44:09 +0000
commit877ded8532736d49b3cda8708cf0e5e9c44a760b (patch)
tree1e1297009163085750f634ff7ec84a0ae2f4f008 /lib/Driver/Driver.cpp
parentd130c7df5db47e5467fd7f7888fecd403fed796d (diff)
Driver: Support -fno-lto.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@129712 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Driver/Driver.cpp')
-rw-r--r--lib/Driver/Driver.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Driver/Driver.cpp b/lib/Driver/Driver.cpp
index a3c93bd88c..39ace114e6 100644
--- a/lib/Driver/Driver.cpp
+++ b/lib/Driver/Driver.cpp
@@ -950,7 +950,8 @@ Action *Driver::ConstructPhaseAction(const ArgList &Args, phases::ID Phase,
} else if (Args.hasArg(options::OPT_emit_ast)) {
return new CompileJobAction(Input, types::TY_AST);
} else if (Args.hasArg(options::OPT_emit_llvm) ||
- Args.hasArg(options::OPT_flto) || HasO4) {
+ Args.hasFlag(options::OPT_flto, options::OPT_fno_lto, false) ||
+ HasO4) {
types::ID Output =
Args.hasArg(options::OPT_S) ? types::TY_LTO_IR : types::TY_LTO_BC;
return new CompileJobAction(Input, Output);