diff options
Diffstat (limited to 'gcc/testsuite/gcc.target/i386/udivmod-5.c')
-rw-r--r-- | gcc/testsuite/gcc.target/i386/udivmod-5.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/i386/udivmod-5.c b/gcc/testsuite/gcc.target/i386/udivmod-5.c new file mode 100644 index 000000000..7c31a0a9c --- /dev/null +++ b/gcc/testsuite/gcc.target/i386/udivmod-5.c @@ -0,0 +1,14 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -m8bit-idiv" } */ + +extern void foo (unsigned int, unsigned int, unsigned int, + unsigned int, unsigned int, unsigned int); + +void +bar (unsigned int x, unsigned int y) +{ + foo (0, 0, 0, 0, x / y, x % y); +} + +/* { dg-final { scan-assembler-times "divb" 1 } } */ +/* { dg-final { scan-assembler-times "divl" 1 } } */ |