OSDN Git Service

2010-11-15 Richard Guenther <rguenther@suse.de>
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 15 Nov 2010 09:43:01 +0000 (09:43 +0000)
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 15 Nov 2010 09:43:01 +0000 (09:43 +0000)
PR lto/44150
* lto-opts.c (lto_write_options): Write -fexceptions even if
not set by the user.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@166744 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/lto-opts.c

index ea3e335..08864a5 100644 (file)
@@ -1,3 +1,9 @@
+2010-11-15  Richard Guenther  <rguenther@suse.de>
+
+       PR lto/44150
+       * lto-opts.c (lto_write_options): Write -fexceptions even if
+       not set by the user.
+
 2010-11-13  Paolo Bonzini  <bonzini@gnu.org>
 
        PR c/46462
index eeb41e9..807f55b 100644 (file)
@@ -299,6 +299,13 @@ lto_write_options (void)
   struct lto_simple_header header;
   struct lto_output_stream *header_stream;
 
+  /* Targets and languages can provide defaults for -fexceptions but
+     we only process user options from the command-line.  Until we
+     serialize out a white list of options from the new global state
+     explicitly append important options as user options here.  */
+  if (flag_exceptions)
+    lto_register_user_option (OPT_fexceptions, NULL, 1, CL_COMMON);
+
   lto_begin_section (section_name, !flag_wpa);
   free (section_name);