mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-01-26 10:34:12 +08:00
* gcc.target/mips/branch-1.c: New test.
From-SVN: r98522
This commit is contained in:
parent
0e61db61a0
commit
eb7058ce96
@ -1,3 +1,7 @@
|
||||
2005-04-21 Richard Sandiford <rsandifo@redhat.com>
|
||||
|
||||
* gcc.target/mips/branch-1.c: New test.
|
||||
|
||||
2005-04-21 Richard Henderson <rth@redhat.com>
|
||||
|
||||
* gcc.dg/vect/vect-85.c: Don't xfail on alpha.
|
||||
|
11
gcc/testsuite/gcc.target/mips/branch-1.c
Normal file
11
gcc/testsuite/gcc.target/mips/branch-1.c
Normal file
@ -0,0 +1,11 @@
|
||||
/* We should implement these "if" statements using an "andi" instruction
|
||||
followed by a branch on zero. */
|
||||
/* { dg-mips-options "-O2 -mno-mips16" } */
|
||||
void bar (void);
|
||||
void f1 (int x) { if (x & 4) bar (); }
|
||||
void f2 (int x) { if ((x >> 2) & 1) bar (); }
|
||||
void f3 (unsigned int x) { if (x & 0x10) bar (); }
|
||||
void f4 (unsigned int x) { if ((x >> 4) & 1) bar (); }
|
||||
/* { dg-final { scan-assembler "\tandi\t.*\tandi\t.*\tandi\t.*\tandi\t" } } */
|
||||
/* { dg-final { scan-assembler-not "\tsrl\t" } } */
|
||||
/* { dg-final { scan-assembler-not "\tsra\t" } } */
|
Loading…
Reference in New Issue
Block a user