re PR rtl-optimization/78527 (ice on valid C code at -O3 in both 32-bit and 64-bit modes on x86_64-linux-gnu (internal compiler error: in smallest_mode_for_size, at stor-layout.c:364))
PR rtl-optimization/78527 * combine.c (make_compound_operation_int): Ignore LSHIFTRT with out of bounds shift count. * gcc.c-torture/compile/pr78527.c: New test. From-SVN: r242879
This commit is contained in:
parent
be40f3cd82
commit
27d0862e62
|
@ -1,3 +1,9 @@
|
|||
2016-11-25 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR rtl-optimization/78527
|
||||
* combine.c (make_compound_operation_int): Ignore LSHIFTRT with
|
||||
out of bounds shift count.
|
||||
|
||||
2016-11-25 Martin Liska <mliska@suse.cz>
|
||||
|
||||
PR web/71666
|
||||
|
|
|
@ -8091,6 +8091,8 @@ make_compound_operation_int (machine_mode mode, rtx *x_ptr,
|
|||
if (GET_CODE (inner) == LSHIFTRT
|
||||
&& CONST_INT_P (XEXP (inner, 1))
|
||||
&& GET_MODE_SIZE (mode) < GET_MODE_SIZE (GET_MODE (inner))
|
||||
&& (UINTVAL (XEXP (inner, 1))
|
||||
< GET_MODE_PRECISION (GET_MODE (inner)))
|
||||
&& subreg_lowpart_p (x))
|
||||
{
|
||||
new_rtx = make_compound_operation (XEXP (inner, 0), next_code);
|
||||
|
|
|
@ -1,3 +1,8 @@
|
|||
2016-11-25 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR rtl-optimization/78527
|
||||
* gcc.c-torture/compile/pr78527.c: New test.
|
||||
|
||||
2016-11-25 Martin Liska <mliska@suse.cz>
|
||||
|
||||
PR gcov-profile/78086
|
||||
|
|
|
@ -0,0 +1,21 @@
|
|||
/* PR rtl-optimization/78527 */
|
||||
|
||||
unsigned a;
|
||||
short b, e;
|
||||
int *c;
|
||||
char d;
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
int f = 80;
|
||||
for (;;) {
|
||||
if (f > 432)
|
||||
*c = a;
|
||||
while (b)
|
||||
if (d)
|
||||
e = -(a >> f);
|
||||
c = &f;
|
||||
b = e;
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue