re PR middle-end/33670 (cc1 segfault with -O2 -fsched-stalled-insns=0 for twolf)

PR middle-end/33670
	* haifa-sched.c (ok_for_early_queue_removal): Don't walk out of the
	current sched region.

	* gcc.dg/pr33670.c: New test.

From-SVN: r129863
This commit is contained in:
Jakub Jelinek 2007-11-03 00:06:36 +01:00 committed by Jakub Jelinek
parent eba5fc70ad
commit ec8628e835
4 changed files with 36 additions and 0 deletions

View File

@ -1,3 +1,9 @@
2007-11-03 Jakub Jelinek <jakub@redhat.com>
PR middle-end/33670
* haifa-sched.c (ok_for_early_queue_removal): Don't walk out of the
current sched region.
2007-11-02 Jakub Jelinek <jakub@redhat.com>
* config/ia64/ia64.c (struct reg_write_state): Change into

View File

@ -1590,6 +1590,12 @@ ok_for_early_queue_removal (rtx insn)
{
int cost;
if (prev_insn == current_sched_info->prev_head)
{
prev_insn = NULL;
break;
}
if (!NOTE_P (prev_insn))
{
dep_t dep;

View File

@ -1,3 +1,8 @@
2007-11-03 Jakub Jelinek <jakub@redhat.com>
PR middle-end/33670
* gcc.dg/pr33670.c: New test.
2007-11-02 Jakub Jelinek <jakub@redhat.com>
PR c++/33516

View File

@ -0,0 +1,19 @@
/* PR middle-end/33670 */
/* { dg-do compile } */
/* { dg-options "-O2 -fsched-stalled-insns=0" } */
struct B
{
int p;
int n;
};
extern struct B ***b;
extern int a;
int
foo (int d, int e)
{
int c;
for (c = d; c <= e; c++)
b[a][c]->n = b[a][c]->p;
}