[Bug bootstrap/14671] [3.3/3.4 regression] caller-save.c:491: internal compiler error: Segmentation fault
dave at hiauly1 dot hia dot nrc dot ca
gcc-bugzilla@gcc.gnu.org
Wed Apr 7 04:24:00 GMT 2004
------- Additional Comments From dave at hiauly1 dot hia dot nrc dot ca 2004-04-07 04:24 -------
Subject: Re: [3.3/3.4 regression] caller-save.c:491: int
> ------- Additional Comments From mmitchel at gcc dot gnu dot org 2004-04-04
> 23:05 -------
> Dave, can you confirm whether or not this PR is fixed?
I studied this problem further today. The in_use flag for the node
that causes the segfault is being cleared by clear_marks. clear_marks
is called from ggc_collect. ggc_collect is called from loop_optimize.
It would appear that there are a few ggc objects created after the last
context push (possibly in init_alias_once). These get garbage collected
and cause the segfault.
I believe that the enclosed patch will fix the problem. The problem
affects 3.3 onward.
The patch is not fully tested. I'm still struggling with bootstrap/14829.
CVS access for me has been terrible the last couple of days.
Dave
--
J. David Anglin dave.anglin@nrc-cnrc.gc.ca
National Research Council of Canada (613) 990-0752 (FAX: 952-6602)
2004-04-07 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
PR bootstrap/14671
* loop.c (loop_optimize): Push and pop ggc context.
Index: loop.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/loop.c,v
retrieving revision 1.497
diff -u -3 -p -r1.497 loop.c
--- loop.c 18 Mar 2004 16:42:31 -0000 1.497
+++ loop.c 6 Apr 2004 23:27:05 -0000
@@ -498,6 +498,7 @@ loop_optimize (rtx f, FILE *dumpfile, in
We could have added a call to reg_scan after gcse_main in toplev.c,
but moving this call to init_alias_analysis is more efficient. */
init_alias_analysis ();
+ ggc_push_context ();
/* See if we went too far. Note that get_max_uid already returns
one more that the maximum uid of all insn. */
@@ -543,6 +544,7 @@ loop_optimize (rtx f, FILE *dumpfile, in
}
}
+ ggc_pop_context ();
end_alias_analysis ();
/* Clean up. */
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14671
More information about the Gcc-bugs
mailing list