lto-wrapper.c (run_gcc): Set have_lto and have_offload if at least one file contains...
authorIlya Verbin <ilya.verbin@intel.com>
Fri, 28 Nov 2014 13:46:28 +0000 (13:46 +0000)
committerIlya Verbin <iverbin@gcc.gnu.org>
Fri, 28 Nov 2014 13:46:28 +0000 (13:46 +0000)
gcc/
* lto-wrapper.c (run_gcc): Set have_lto and have_offload if at least one
file contains sections with LTO and offload IR, respectively.

From-SVN: r218156

gcc/ChangeLog
gcc/lto-wrapper.c

index 4e6da0cd27996b607b7b4dc04698b63cb2282037..9696664645f59bebba06eaa2d76798a088a27ed8 100644 (file)
@@ -1,3 +1,8 @@
+2014-11-28  Ilya Verbin  <ilya.verbin@intel.com>
+
+       * lto-wrapper.c (run_gcc): Set have_lto and have_offload if at least one
+       file contains sections with LTO and offload IR, respectively.
+
 2014-11-28  Ilya Verbin  <ilya.verbin@intel.com>
 
        * cgraphunit.c (ipa_passes): Handle flag_generate_offload.
index 9a540b4ede5b128a669824171ba795cb47552df1..0f69457f4ea62afc1624424ea86eccca58ab7e44 100644 (file)
@@ -921,13 +921,14 @@ run_gcc (unsigned argc, char *argv[])
        continue;
 
       have_lto
-       = find_and_merge_options (fd, file_offset, LTO_SECTION_NAME_PREFIX,
-                                 &fdecoded_options, &fdecoded_options_count,
-                                 collect_gcc);
+       |= find_and_merge_options (fd, file_offset, LTO_SECTION_NAME_PREFIX,
+                                  &fdecoded_options, &fdecoded_options_count,
+                                  collect_gcc);
       have_offload
-       = find_and_merge_options (fd, file_offset, OFFLOAD_SECTION_NAME_PREFIX,
-                                 &offload_fdecoded_options,
-                                 &offload_fdecoded_options_count, collect_gcc);
+       |= find_and_merge_options (fd, file_offset, OFFLOAD_SECTION_NAME_PREFIX,
+                                  &offload_fdecoded_options,
+                                  &offload_fdecoded_options_count,
+                                  collect_gcc);
       close (fd);
     }