diff options
Diffstat (limited to 'gcc/testsuite/gcc.target/m68k/pr36133.c')
-rw-r--r-- | gcc/testsuite/gcc.target/m68k/pr36133.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/m68k/pr36133.c b/gcc/testsuite/gcc.target/m68k/pr36133.c new file mode 100644 index 000000000..25237a860 --- /dev/null +++ b/gcc/testsuite/gcc.target/m68k/pr36133.c @@ -0,0 +1,16 @@ +/* pr36133.c + + This test ensures that conditional branches can use the condition codes + written by shift instructions, without the need for an extra TST. */ + +/* { dg-do compile } */ +/* { dg-options "-O2" } */ +/* { dg-final { scan-assembler-not "tst" } } */ + +void +f (unsigned int a) +{ + if (a >> 4) + asm volatile ("nop"); + asm volatile ("nop"); +} |