URL
https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk
Only display areas with differences |
Details |
Blame |
View Log
Rev 298 |
Rev 384 |
/* PR tree-optimization/20702
|
/* PR tree-optimization/20702
|
VRP did not insert ASSERT_EXPRs into dominator dominator children
|
VRP did not insert ASSERT_EXPRs into dominator dominator children
|
of a basic block ending with COND_EXPR unless the children are also
|
of a basic block ending with COND_EXPR unless the children are also
|
immediate successors of the basic block. */
|
immediate successors of the basic block. */
|
|
|
/* { dg-do compile } */
|
/* { dg-do compile } */
|
/* { dg-options "-O2 -fno-tree-dominator-opts -fdump-tree-vrp1-details" } */
|
/* { dg-options "-O2 -fno-tree-dominator-opts -fdump-tree-vrp1-details" } */
|
|
|
extern void bar (int);
|
extern void bar (int);
|
|
|
int
|
int
|
foo (int *p, int b)
|
foo (int *p, int b)
|
{
|
{
|
int a;
|
int a;
|
|
|
if (b)
|
if (b)
|
bar (123);
|
bar (123);
|
else
|
else
|
bar (321);
|
bar (321);
|
|
|
a = *p;
|
a = *p;
|
if (p == 0)
|
if (p == 0)
|
return 0;
|
return 0;
|
|
|
return a;
|
return a;
|
}
|
}
|
|
|
/* Target with fno-delete-null-pointer-checks should not fold checks */
|
/* Target with fno-delete-null-pointer-checks should not fold checks */
|
/* { dg-final { scan-tree-dump-times "Folding predicate" 1 "vrp1" { target { ! keeps_null_pointer_checks } } } } */
|
/* { dg-final { scan-tree-dump-times "Folding predicate" 1 "vrp1" { target { ! keeps_null_pointer_checks } } } } */
|
/* { dg-final { scan-tree-dump-times "Folding predicate" 0 "vrp1" { target { keeps_null_pointer_checks } } } } */
|
/* { dg-final { scan-tree-dump-times "Folding predicate" 0 "vrp1" { target { keeps_null_pointer_checks } } } } */
|
/* { dg-final { cleanup-tree-dump "vrp1" } } */
|
/* { dg-final { cleanup-tree-dump "vrp1" } } */
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.