diff options
Diffstat (limited to 'gcc/testsuite/gcc.target/i386/cmov4.c')
-rw-r--r-- | gcc/testsuite/gcc.target/i386/cmov4.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/i386/cmov4.c b/gcc/testsuite/gcc.target/i386/cmov4.c new file mode 100644 index 00000000000..e293b34abc1 --- /dev/null +++ b/gcc/testsuite/gcc.target/i386/cmov4.c @@ -0,0 +1,19 @@ +/* { dg-do compile { target i?86-*-* x86_64-*-* } } */ +/* { dg-options "-O2 -march=k8" } */ +/* { dg-final { scan-assembler "cmov" } } */ + +/* Verify that if conversion happends for memory references. */ +int ARCHnodes; +int *nodekind; +float *nodekindf; +t() +{ +int i; +/* Redefine nodekind to be 1 for all surface nodes */ + + for (i = 0; i < ARCHnodes; i++) { + nodekind[i] = (int) nodekindf[i]; + if (nodekind[i] == 3) + nodekind[i] = 1; + } +} |