Uros Bizjak <ubiz...@gmail.com> wrote: > Please also add the testcase from the PR to the testsuite.
For the record, I've committed the testcase below from the PR. Regards, kaz -- 2012-11-07 Kaz Kojima <kkoj...@gcc.gnu.org> * gcc.c-torture/compile/pr49220.c: New test. --- ORIG/trunk/gcc/testsuite/gcc.c-torture/compile/pr49220.c 1970-01-01 09:00:00.000000000 +0900 +++ trunk/gcc/testsuite/gcc.c-torture/compile/pr49220.c 2012-11-07 19:29:26.000000000 +0900 @@ -0,0 +1,25 @@ +int array[2]; + +static int +func1 (int b) +{ + return b; +} + +static int +func2 (int a, int b) +{ + return b == 0 ? a : b; +} + +int +func3 (int a) +{ +} + +int * +func4 (int *arg) +{ + *arg = func1 ((func2 (func3 (array[0]), *arg)) | array[0]); + return &array[1]; +}