ubuntu-buildroot/output/build/host-gcc-initial-11.4.0/gcc/testsuite/gcc.target/sparc/movcc-2.c

32 lines
492 B
C
Raw Permalink Normal View History

2024-04-01 15:19:46 +00:00
/* { dg-do compile } */
/* { dg-require-effective-target lp64 } */
/* { dg-options "-O2" } */
long foo1 (long a)
{
long b = a + 1;
if (b != 0)
return b;
return 1;
}
long foo2 (long a)
{
long b = a + 1;
if (b < 0)
return b;
return 1;
}
long foo3 (long a)
{
long b = a + 1;
if (b >= 0)
return b;
return 1;
}
/* { dg-final { scan-assembler "movre\t%" } } */
/* { dg-final { scan-assembler "movrgez\t%" } } */
/* { dg-final { scan-assembler "movrlz\t%" } } */