diff options
author | Andi Kleen <ak@linux.intel.com> | 2010-12-19 19:36:25 +0000 |
---|---|---|
committer | Andi Kleen <ak@gcc.gnu.org> | 2010-12-19 19:36:25 +0000 |
commit | 595c8dfa0bc38bda6e4b652b047bc47be851da19 (patch) | |
tree | 6655ab7912104ec1b20fdb522bca9fcb57e8c63d /gcc | |
parent | ef7ed5df72fb2cfb6a1dab38e335eb65e02b6204 (diff) | |
download | gcc-595c8dfa0bc38bda6e4b652b047bc47be851da19.zip gcc-595c8dfa0bc38bda6e4b652b047bc47be851da19.tar.gz gcc-595c8dfa0bc38bda6e4b652b047bc47be851da19.tar.bz2 |
Fix -fno-lto (PR lto/46905)
gcc/
2010-12-19 Andi Kleen <ak@linux.intel.com>
PR lto/46905
* collect2.c (main): Handle -fno-lto.
* opts.c (common_handle_option): Handle -fno-lto.
From-SVN: r168071
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/collect2.c | 2 | ||||
-rw-r--r-- | gcc/opts.c | 2 |
3 files changed, 9 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index fee3cf7..9bc1d93 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2010-12-19 Andi Kleen <ak@linux.intel.com> + + PR lto/46905 + * collect2.c (main): Handle -fno-lto. + * opts.c (common_handle_option): Handle -fno-lto. + 2010-12-19 Eric Botcazou <ebotcazou@adacore.com> PR target/46729 diff --git a/gcc/collect2.c b/gcc/collect2.c index 89b21d5..77f794f 100644 --- a/gcc/collect2.c +++ b/gcc/collect2.c @@ -1211,6 +1211,8 @@ main (int argc, char **argv) else if ((! strncmp (argv[i], "-flto=", 6) || ! strcmp (argv[i], "-flto")) && ! use_plugin) lto_mode = LTO_MODE_WHOPR; + else if (!strncmp (argv[i], "-fno-lto", 8)) + lto_mode = LTO_MODE_NONE; else if (! strcmp (argv[i], "-plugin")) { use_plugin = true; @@ -1670,7 +1670,7 @@ common_handle_option (struct gcc_options *opts, break; case OPT_flto: - opts->x_flag_lto = ""; + opts->x_flag_lto = value ? "" : NULL; break; case OPT_w: |