Mercurial > hg > CbC > CbC_gcc
diff gcc/testsuite/gcc.dg/pr88444.c @ 145:1830386684a0
gcc-9.2.0
author | anatofuz |
---|---|
date | Thu, 13 Feb 2020 11:34:05 +0900 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/gcc/testsuite/gcc.dg/pr88444.c Thu Feb 13 11:34:05 2020 +0900 @@ -0,0 +1,30 @@ +/* PR tree-optimization/88444 */ +/* { dg-do compile } */ +/* { dg-options "-O1 -ftree-vrp -fno-tree-ccp -fno-tree-forwprop -fno-tree-fre" } */ + +int v; + +int +foo (int, int); + +static inline int +bar (long int x) +{ + return !!x ? x : 1; +} + +static inline void +baz (int x) +{ + v += foo (0, 0) + bar (x); +} + +void +qux (void) +{ + int a = 0; + v = v || foo (0, 0); + v = v || foo (0, 0); + v = v || foo (0, 0); + baz (a); +}