diff options
Diffstat (limited to 'gcc/testsuite/gcc.target/i386/pr103861-2.c')
-rw-r--r-- | gcc/testsuite/gcc.target/i386/pr103861-2.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/i386/pr103861-2.c b/gcc/testsuite/gcc.target/i386/pr103861-2.c new file mode 100644 index 0000000..471f50c --- /dev/null +++ b/gcc/testsuite/gcc.target/i386/pr103861-2.c @@ -0,0 +1,21 @@ +/* PR target/103861 */ +/* { dg-do compile } */ +/* { dg-options "-O2 -msse2" } */ + +typedef char vec __attribute__((vector_size(2))); + +vec lt (vec a, vec b) { return a < b; } +vec le (vec a, vec b) { return a <= b; } +vec eq (vec a, vec b) { return a == b; } +vec ne (vec a, vec b) { return a != b; } +vec ge (vec a, vec b) { return a >= b; } +vec gt (vec a, vec b) { return a > b; } + +typedef unsigned char uvec __attribute__((vector_size(2))); + +vec ltu (uvec a, uvec b) { return a < b; } +vec leu (uvec a, uvec b) { return a <= b; } +vec geu (uvec a, uvec b) { return a >= b; } +vec gtu (uvec a, uvec b) { return a > b; } + +/* { dg-final { scan-assembler-not "cmpb" } } */ |