Commit 7fefb1d1 by Jakub Jelinek Committed by Jakub Jelinek

re PR debug/50827 (ICE: RTL check: expected elt 0 type 'e' or 'u', have '0' (rtx…

re PR debug/50827 (ICE: RTL check: expected elt 0 type 'e' or 'u', have '0' (rtx entry_value) in loc_cmp, at var-tracking.c:3011)

	PR debug/50827
	* var-tracking.c (loc_cmp): For ENTRY_VALUEs use ENTRY_VALUE_EXP
	macro instead of XEXP.

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

From-SVN: r181597
parent 49f7dc9d
2011-11-21 Jakub Jelinek <jakub@redhat.com>
PR debug/50827
* var-tracking.c (loc_cmp): For ENTRY_VALUEs use ENTRY_VALUE_EXP
macro instead of XEXP.
2011-11-21 Andreas Tobler <andreast@fgznet.ch> 2011-11-21 Andreas Tobler <andreast@fgznet.ch>
* configure: Regenerate. * configure: Regenerate.
2011-11-21 Jakub Jelinek <jakub@redhat.com>
PR debug/50827
* gcc.dg/pr50827.c: New test.
2011-11-21 Ed Smith-Rowland <3dw4rd@verizon.net> 2011-11-21 Ed Smith-Rowland <3dw4rd@verizon.net>
PR c++/50958 PR c++/50958
......
/* PR debug/50827 */
/* { dg-do compile } */
/* { dg-options "-g -O2 -funroll-loops" } */
void
foo (int w, int x, int *y, int *z)
{
float f;
while (w--)
{
f = x;
if (y)
*y = (__INTPTR_TYPE__) y + w;
if (z)
*z = w;
}
}
...@@ -3008,7 +3008,7 @@ loc_cmp (rtx x, rtx y) ...@@ -3008,7 +3008,7 @@ loc_cmp (rtx x, rtx y)
if (GET_CODE (y) != ENTRY_VALUE) if (GET_CODE (y) != ENTRY_VALUE)
return 1; return 1;
gcc_assert (GET_MODE (x) == GET_MODE (y)); gcc_assert (GET_MODE (x) == GET_MODE (y));
return loc_cmp (XEXP (x, 0), XEXP (y, 0)); return loc_cmp (ENTRY_VALUE_EXP (x), ENTRY_VALUE_EXP (y));
} }
if (GET_CODE (y) == ENTRY_VALUE) if (GET_CODE (y) == ENTRY_VALUE)
......
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