diff options
Diffstat (limited to 'gcc-4.9/gcc/testsuite/gcc.target/powerpc/ti_math1.c')
-rw-r--r-- | gcc-4.9/gcc/testsuite/gcc.target/powerpc/ti_math1.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/gcc-4.9/gcc/testsuite/gcc.target/powerpc/ti_math1.c b/gcc-4.9/gcc/testsuite/gcc.target/powerpc/ti_math1.c new file mode 100644 index 000000000..cdf925100 --- /dev/null +++ b/gcc-4.9/gcc/testsuite/gcc.target/powerpc/ti_math1.c @@ -0,0 +1,20 @@ +/* { dg-do compile { target { powerpc*-*-* && lp64 } } } */ +/* { dg-options "-O2" } */ +/* { dg-final { scan-assembler-times "addc" 1 } } */ +/* { dg-final { scan-assembler-times "adde" 1 } } */ +/* { dg-final { scan-assembler-times "subfc" 1 } } */ +/* { dg-final { scan-assembler-times "subfe" 1 } } */ +/* { dg-final { scan-assembler-not "subf " } } */ + +__int128 +add_128 (__int128 *ptr, __int128 val) +{ + return (*ptr + val); +} + +__int128 +sub_128 (__int128 *ptr, __int128 val) +{ + return (*ptr - val); +} + |