| 1 |
/* { dg-do run { target { ! ia32 } } } */ |
| 2 |
/* { dg-require-effective-target sse4 } */ |
| 3 |
/* { dg-options "-O2 -msse4.1" } */ |
| 4 |
|
| 5 |
#include "sse4_1-check.h" |
| 6 |
|
| 7 |
#include "mmx-reduce-op-1.c" |
| 8 |
|
| 9 |
static void |
| 10 |
sse4_1_test () |
| 11 |
{ |
| 12 |
short p[4] = { -103, 23, 41, 200 }; |
| 13 |
unsigned short up[4] = { 100, 30, 299, 1000 }; |
| 14 |
|
| 15 |
if (reduce_add (p) != 161) |
| 16 |
abort (); |
| 17 |
if (reduce_smin (p) != -103) |
| 18 |
abort (); |
| 19 |
if (reduce_smax (p) != 200) |
| 20 |
abort (); |
| 21 |
if (reduce_umin (up) != 30) |
| 22 |
abort (); |
| 23 |
if (reduce_umax (up) != 1000) |
| 24 |
abort(); |
| 25 |
} |