]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
* tree-cfg.c (dump_function_to_file): Be prepared for functions
authorebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 19 Feb 2007 19:26:16 +0000 (19:26 +0000)
committerebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 19 Feb 2007 19:26:16 +0000 (19:26 +0000)
without DECL_STRUCT_FUNCTION initialized.

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

gcc/ChangeLog
gcc/tree-cfg.c

index 0f834e47b0e27d7818aad62fef6c6f41c9cc7643..f52131442161ab2e75d30396d81f2058a8ce8248 100644 (file)
@@ -1,3 +1,8 @@
+2007-02-19  Eric Botcazou  <ebotcazou@adacore.com>
+
+       * tree-cfg.c (dump_function_to_file): Be prepared for functions
+       without DECL_STRUCT_FUNCTION initialized.
+
 2007-02-19  Eric Botcazou  <ebotcazou@adacore.com>
 
        * gimplify.c (gimplify_init_ctor_preeval_1): Detect potential overlap
index a99f3c7f5eb31aaf8a4652abcd500488f6e09c57..593dc0d03c1b72903e1849d64e27330c89991131 100644 (file)
@@ -4998,6 +4998,7 @@ void
 dump_function_to_file (tree fn, FILE *file, int flags)
 {
   tree arg, vars, var;
+  struct function *dsf;
   bool ignore_topmost_bind = false, any_var = false;
   basic_block bb;
   tree chain;
@@ -5015,8 +5016,10 @@ dump_function_to_file (tree fn, FILE *file, int flags)
     }
   fprintf (file, ")\n");
 
-  if (flags & TDF_DETAILS)
-    dump_eh_tree (file, DECL_STRUCT_FUNCTION (fn));
+  dsf = DECL_STRUCT_FUNCTION (fn);
+  if (dsf && (flags & TDF_DETAILS))
+    dump_eh_tree (file, dsf);
+
   if (flags & TDF_RAW)
     {
       dump_node (fn, TDF_SLIM | flags, file);