Commit 684ffdc9 by Vladimir Makarov Committed by Vladimir Makarov

re PR rtl-optimization/68691 (ICE at -O3 with -g enabled on x86_64-linux-gnu in…

re PR rtl-optimization/68691 (ICE at -O3 with -g enabled on x86_64-linux-gnu in alter_subregs, at lra-spills.c:610 (in 32-bit mode))

2015-12-10  Vladimir Makarov  <vmakarov@redhat.com>

	PR rtl-optimization/68691
	* lra-spills.c (lra_final_code_change): Check pseudo occurrence
	number in non-debug insns and remove debug insns if necessary.

2015-12-10  Vladimir Makarov  <vmakarov@redhat.com>

	PR rtl-optimization/68691
	* gcc.target/i386/pr68691.c: New.

From-SVN: r231538
parent 0da4edf7
2015-12-10 Vladimir Makarov <vmakarov@redhat.com>
PR rtl-optimization/68691
* lra-spills.c (lra_final_code_change): Check pseudo occurrence
number in non-debug insns and remove debug insns if necessary.
2015-12-10 Martin Sebor <msebor@redhat.com>
* invoke.texi (Warning Options): Update -Wall options. Clarify
......@@ -708,6 +708,30 @@ lra_final_code_change (void)
}
lra_insn_recog_data_t id = lra_get_insn_recog_data (insn);
struct lra_insn_reg *reg;
for (reg = id->regs; reg != NULL; reg = reg->next)
if (reg->regno >= FIRST_PSEUDO_REGISTER
&& lra_reg_info [reg->regno].nrefs == 0)
break;
if (reg != NULL)
{
/* Pseudos still can be in debug insns in some very rare
and complicated cases, e.g. the pseudo was removed by
inheritance and the debug insn is not EBBs where the
inheritance happened. It is difficult and time
consuming to find what hard register corresponds the
pseudo -- so just remove the debug insn. Another
solution could be assigning hard reg/memory but it
would be a misleading info. It is better not to have
info than have it wrong. */
lra_assert (DEBUG_INSN_P (insn));
lra_invalidate_insn_data (insn);
delete_insn (insn);
continue;
}
struct lra_static_insn_data *static_id = id->insn_static_data;
bool insn_change_p = false;
......
2015-12-10 Vladimir Makarov <vmakarov@redhat.com>
PR rtl-optimization/68691
* gcc.target/i386/pr68691.c: New.
2015-12-10 David Malcolm <dmalcolm@redhat.com>
* lib/multiline.exp (_multiline_expected_outputs): Update comment.
......
/* { dg-do compile } */
/* { dg-options "-O3 -g" } */
char a, b, i, j;
int c, d, e, f, g, h, n;
char
fn1 ()
{
char k, l, m;
int p;
e = g > f;
for (b = 0; b < 2; b++)
{
for (p = 0; p < 3; p++)
{
for (; h < 1; h++)
{
for (; m;)
goto lbl;
e = g;
}
l = a < 0 || a < d;
}
d++;
for (;;)
{
k = g;
n = -k;
j = n;
c = j;
e = 2;
if (l)
break;
return 2;
}
}
for (;;)
;
lbl:
return i;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment