re PR middle-end/54211 (ICE: verify_gimple failed building freetype with -Os)
gcc: 2012-08-10 Bill Schmidt <wschmidt@linux.vnet.ibm.com> PR middle-end/54211 * gimple-ssa-strength-reduction.c (analyze_candidates_and_replace): Use cand_type to determine whether pointer arithmetic will be generated. gcc/testsuite: 2012-08-10 Bill Schmidt <wschmidt@linux.vnet.ibm.com> PR middle-end/54211 * gcc.dg/tree-ssa/pr54211.c: New test. From-SVN: r190294
This commit is contained in:
parent
75bc384117
commit
99cababb4b
|
@ -1,3 +1,9 @@
|
|||
2012-08-10 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
|
||||
|
||||
PR middle-end/54211
|
||||
* gimple-ssa-strength-reduction.c (analyze_candidates_and_replace):
|
||||
Use cand_type to determine whether pointer arithmetic will be generated.
|
||||
|
||||
2012-08-10 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
|
||||
|
||||
* doc/sourcebuild.texi: Document long_neq_int effective target.
|
||||
|
|
|
@ -2534,7 +2534,7 @@ analyze_candidates_and_replace (void)
|
|||
/* Determine whether we'll be generating pointer arithmetic
|
||||
when replacing candidates. */
|
||||
address_arithmetic_p = (c->kind == CAND_ADD
|
||||
&& POINTER_TYPE_P (TREE_TYPE (c->base_expr)));
|
||||
&& POINTER_TYPE_P (c->cand_type));
|
||||
|
||||
/* If all candidates have already been replaced under other
|
||||
interpretations, nothing remains to be done. */
|
||||
|
|
|
@ -1,3 +1,8 @@
|
|||
2012-08-10 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
|
||||
|
||||
PR middle-end/54211
|
||||
* gcc.dg/tree-ssa/pr54211.c: New test.
|
||||
|
||||
2012-08-10 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
|
||||
|
||||
* lib/target-supports.exp (check_effective_target_long_neq_int): New.
|
||||
|
|
|
@ -0,0 +1,28 @@
|
|||
/* { dg-do compile } */
|
||||
/* { dg-options "-Os" } */
|
||||
|
||||
int a, b;
|
||||
unsigned char e;
|
||||
void fn1 ()
|
||||
{
|
||||
unsigned char *c=0;
|
||||
for (;; a++)
|
||||
{
|
||||
unsigned char d = *(c + b);
|
||||
for (; &e<&d; c++)
|
||||
goto Found_Top;
|
||||
}
|
||||
Found_Top:
|
||||
if (0)
|
||||
goto Empty_Bitmap;
|
||||
for (;; a++)
|
||||
{
|
||||
unsigned char *e = c + b;
|
||||
for (; c < e; c++)
|
||||
goto Found_Bottom;
|
||||
c -= b;
|
||||
}
|
||||
Found_Bottom:
|
||||
Empty_Bitmap:
|
||||
;
|
||||
}
|
Loading…
Reference in New Issue