Hi,
The following fix suggested by Richard fixes chromium build failing
due to segfault in inline_call.
Bootstrapped and tested on x86_64-unknown-linux-gnu.
Cross-tested on arm*-*-* and aarch64*-*-*.
Ok for trunk ?

Thanks,
Prathamesh
diff --git a/gcc/ipa-inline-transform.c b/gcc/ipa-inline-transform.c
index 5dc0b5a..f966fb0 100644
--- a/gcc/ipa-inline-transform.c
+++ b/gcc/ipa-inline-transform.c
@@ -329,8 +329,7 @@ inline_call (struct cgraph_edge *e, bool update_original,
     {
       struct gcc_options opts = global_options;
 
-      cl_optimization_restore (&opts,
-        TREE_OPTIMIZATION (DECL_FUNCTION_SPECIFIC_OPTIMIZATION (to->decl)));
+      cl_optimization_restore (&opts, opts_for_fn (to->decl));
       opts.x_flag_strict_aliasing = false;
       if (dump_file)
        fprintf (dump_file, "Dropping flag_strict_aliasing on %s:%i\n",

Attachment: ChangeLog
Description: Binary data

Reply via email to