Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/gcc.dg/pr48837.c @ 158:494b0b89df80 default tip
...
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 25 May 2020 18:13:55 +0900 |
parents | 04ced10e8804 |
children |
line wrap: on
line source
/* PR tree-optimization/48837 */ /* { dg-do run } */ /* { dg-options "-O2" } */ void abort (void); __attribute__((noinline)) int baz(void) { return 1; } inline const int *bar(const int *a, const int *b) { return *a ? a : b; } int foo(int a, int b) { return a || b ? baz() : foo(*bar(&a, &b), 1) + foo(1, 0); } int main(void) { if (foo(0, 0) != 2) abort(); return 0; }