]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
backport: [multiple changes]
authorRichard Biener <rguenther@suse.de>
Mon, 12 Aug 2019 12:59:08 +0000 (12:59 +0000)
committerRichard Biener <rguenth@gcc.gnu.org>
Mon, 12 Aug 2019 12:59:08 +0000 (12:59 +0000)
2019-08-12  Richard Biener  <rguenther@suse.de>

Backport from mainline
2019-08-12  Richard Biener  <rguenther@suse.de>

PR lto/91375
* tree.c (free_lang_data_in_type): Do not free TYPE_BINFO dependent on
flag_devirtualize.

2019-08-12  Richard Biener  <rguenther@suse.de>

PR driver/91130
* lto-wrapper.c (get_options_from_collect_gcc_options): Remove
lang_mask option, always use CL_DRIVER.
(find_and_merge_options): Adjust.
(run_gcc): Likewise.

2019-08-07  Richard Earnshaw  <rearnsha@arm.com>

PR driver/91130
* lto-wrapper.c (find_and_merge_options): Use CL_DRIVER when
processing COLLECT_GCC_OPTIONS.
(run_gcc): Likewise.

From-SVN: r274311

gcc/ChangeLog
gcc/lto-wrapper.c
gcc/tree.c

index 7e041f1c318d71c3bca6a35e13943ed43d20f736..2befb71beaa4bcc20adad50483235047bee051e3 100644 (file)
@@ -1,3 +1,27 @@
+2019-08-12  Richard Biener  <rguenther@suse.de>
+
+       Backport from mainline
+       2019-08-12  Richard Biener  <rguenther@suse.de>
+
+       PR lto/91375
+       * tree.c (free_lang_data_in_type): Do not free TYPE_BINFO dependent on
+       flag_devirtualize.
+
+       2019-08-12  Richard Biener  <rguenther@suse.de>
+
+       PR driver/91130
+       * lto-wrapper.c (get_options_from_collect_gcc_options): Remove
+       lang_mask option, always use CL_DRIVER.
+       (find_and_merge_options): Adjust.
+       (run_gcc): Likewise.
+
+       2019-08-07  Richard Earnshaw  <rearnsha@arm.com>
+
+       PR driver/91130
+       * lto-wrapper.c (find_and_merge_options): Use CL_DRIVER when
+       processing COLLECT_GCC_OPTIONS.
+       (run_gcc): Likewise.
+
 2019-08-12  Jakub Jelinek  <jakub@redhat.com>
 
        * BASE-VER: Set to 9.2.1.
index ac971494054914e5b68691bbac8c1e7eb0609628..10bd7c9becbc22b2ba4701a3fd43b3234c617cb8 100644 (file)
@@ -128,12 +128,11 @@ maybe_unlink (const char *file)
 #define DUMPBASE_SUFFIX ".ltrans18446744073709551615"
 
 /* Create decoded options from the COLLECT_GCC and COLLECT_GCC_OPTIONS
-   environment according to LANG_MASK.  */
+   environment.  */
 
 static void
 get_options_from_collect_gcc_options (const char *collect_gcc,
                                      const char *collect_gcc_options,
-                                     unsigned int lang_mask,
                                      struct cl_decoded_option **decoded_options,
                                      unsigned int *decoded_options_count)
 {
@@ -175,8 +174,7 @@ get_options_from_collect_gcc_options (const char *collect_gcc,
   argc = obstack_object_size (&argv_obstack) / sizeof (void *) - 1;
   argv = XOBFINISH (&argv_obstack, const char **);
 
-  decode_cmdline_options_to_array (argc, (const char **)argv,
-                                  lang_mask,
+  decode_cmdline_options_to_array (argc, (const char **)argv, CL_DRIVER,
                                   decoded_options, decoded_options_count);
   obstack_free (&argv_obstack, NULL);
 }
@@ -1008,8 +1006,7 @@ find_and_merge_options (int fd, off_t file_offset, const char *prefix,
     {
       struct cl_decoded_option *f2decoded_options;
       unsigned int f2decoded_options_count;
-      get_options_from_collect_gcc_options (collect_gcc,
-                                           fopts, CL_LANG_ALL,
+      get_options_from_collect_gcc_options (collect_gcc, fopts,
                                            &f2decoded_options,
                                            &f2decoded_options_count);
       if (!fdecoded_options)
@@ -1150,7 +1147,6 @@ run_gcc (unsigned argc, char *argv[])
     fatal_error (input_location,
                 "environment variable COLLECT_GCC_OPTIONS must be set");
   get_options_from_collect_gcc_options (collect_gcc, collect_gcc_options,
-                                       CL_LANG_ALL,
                                        &decoded_options,
                                        &decoded_options_count);
 
index 73102c4e75bd3bf21815023d93bbef698a724d0d..b82d73c8517dca1153786aaa27d3fbf76ad31f37 100644 (file)
@@ -5514,8 +5514,7 @@ free_lang_data_in_type (tree type, struct free_lang_data_d *fld)
          free_lang_data_in_binfo (TYPE_BINFO (type));
          /* We need to preserve link to bases and virtual table for all
             polymorphic types to make devirtualization machinery working.  */
-         if (!BINFO_VTABLE (TYPE_BINFO (type))
-             || !flag_devirtualize)
+         if (!BINFO_VTABLE (TYPE_BINFO (type)))
            TYPE_BINFO (type) = NULL;
        }
     }