Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/gcc.target/arm/condarith_restrict_it.c @ 152:2b5abeee2509
update gcc11
author | anatofuz |
---|---|
date | Mon, 25 May 2020 07:50:57 +0900 |
parents | 04ced10e8804 |
children |
line wrap: on
line source
/* { dg-do run } */ /* { dg-require-effective-target arm_thumb2_ok } */ /* { dg-options "-mthumb -O2 -mrestrict-it" } */ __attribute__ ((noinline, noclone)) void fn2 () { __builtin_printf ("4"); } enum { ONE = 1, TWO } a; int b; __attribute__ ((noinline, noclone)) int fn1 () { int c = b == 0; if (a <= ONE) if (b == 0) fn2 (); if (a) if (c) a = 0; return a; } int main (void) { a = ONE; b = 1; if (fn1 () != ONE) __builtin_abort (); a = TWO; b = 0; if (fn1 () != 0) __builtin_abort (); return 0; }