re PR tree-optimization/28900 (ICE verify_stmts failed (invalid operand to unary operator))
2006-09-05 Richard Guenther <rguenther@suse.de> PR tree-optimization/28900 * tree-if-conv.c (find_phi_replacement_condition): Gimplify compound conditional before creating COND_EXPR condition. * gcc.dg/torture/pr28900.c: New testcase From-SVN: r116697
This commit is contained in:
parent
b2db922002
commit
575643d56c
4 changed files with 30 additions and 1 deletions
|
@ -1,3 +1,9 @@
|
|||
2006-09-05 Richard Guenther <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/28900
|
||||
* tree-if-conv.c (find_phi_replacement_condition): Gimplify
|
||||
compound conditional before creating COND_EXPR condition.
|
||||
|
||||
2006-09-05 Richard Guenther <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/28905
|
||||
|
|
|
@ -1,3 +1,8 @@
|
|||
2006-09-05 Richard Guenther <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/28900
|
||||
* gcc.dg/torture/pr28900.c: New testcase
|
||||
|
||||
2006-09-05 Richard Guenther <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/28905
|
||||
|
|
15
gcc/testsuite/gcc.dg/torture/pr28900.c
Normal file
15
gcc/testsuite/gcc.dg/torture/pr28900.c
Normal file
|
@ -0,0 +1,15 @@
|
|||
/* { dg-do compile } */
|
||||
/* { dg-options "-ftree-vectorize" } */
|
||||
|
||||
int synths_ ( float * rc)
|
||||
{
|
||||
float r1, r2;
|
||||
int i;
|
||||
for (i = 0; i < 128; ++i)
|
||||
{
|
||||
r2 = rc[i];
|
||||
r1 = ((r2) <= (.99f) ? (r2) : (.99f));
|
||||
rc[i] = ((r1) >= (-.99f) ? (r1) : (-.99f));
|
||||
}
|
||||
}
|
||||
|
|
@ -666,7 +666,7 @@ find_phi_replacement_condition (struct loop *loop,
|
|||
{
|
||||
basic_block first_bb = NULL;
|
||||
basic_block second_bb = NULL;
|
||||
tree tmp_cond;
|
||||
tree tmp_cond, new_stmts;
|
||||
|
||||
gcc_assert (EDGE_COUNT (bb->preds) == 2);
|
||||
first_bb = (EDGE_PRED (bb, 0))->src;
|
||||
|
@ -732,6 +732,9 @@ find_phi_replacement_condition (struct loop *loop,
|
|||
value as condition. Various targets use different means to communicate
|
||||
condition in vector compare operation. Using gimple value allows compiler
|
||||
to emit vector compare and select RTL without exposing compare's result. */
|
||||
*cond = force_gimple_operand (*cond, &new_stmts, false, NULL_TREE);
|
||||
if (new_stmts)
|
||||
bsi_insert_before (bsi, new_stmts, BSI_SAME_STMT);
|
||||
if (!is_gimple_reg (*cond) && !is_gimple_condexpr (*cond))
|
||||
{
|
||||
tree new_stmt;
|
||||
|
|
Loading…
Add table
Reference in a new issue