summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/i386/avx-floor-sfix-vec.c
diff options
context:
space:
mode:
authoruros <uros@138bc75d-0d04-0410-961f-82ee72b054a4>2011-11-14 19:36:33 +0000
committeruros <uros@138bc75d-0d04-0410-961f-82ee72b054a4>2011-11-14 19:36:33 +0000
commitc34303caf477c1adffeefbe36d2e3e86b3f08689 (patch)
tree398a2f2896c360ca8b4a7aef191b1fe692beb2bf /gcc/testsuite/gcc.target/i386/avx-floor-sfix-vec.c
parentbdb92a1dc48b528d93801495347354b62f2b4e8b (diff)
downloadgcc-c34303caf477c1adffeefbe36d2e3e86b3f08689.tar.gz
* config/i386/sse.md (round<mode>2_sfix): New expander.
(round<mode>2_vec_pack_sfix): Ditto. (<sse4_1>_round<ssemodesuffix>_sfix<avxsizesuffix>): Ditto. (<sse4_1>_round<ssemodesuffix>_vec_pack_sfix<avxsizesuffix>): Ditto. * config/i386/builtin-types.def (V4SI_FTYPE_V4SF_ROUND, V8SI_FTYPE_V8SF_ROUND, V4SI_FTYPE_V2DF_V2DF_ROUND, V8SI_FTYPE_V4DF_V4DF_ROUND): New builtin types. * config/i386/i386.c (ix86_builtins): Add IX86_BUILTIN_{FLOORPD,CEILPD,ROUNDPD_AZ}_VEC_PACK_SFIX{,256} and IX86_BUILTIN_{FLOORPS,CEILPS,ROUNDPS_AZ}_SFIX{,256} defines. (bdesc_args): Add __builtin_ia32_{floorpd,ceilpd}_vec_pack_sfix{,256}, __builtin_ia32_roundpd_az_vec_pack_sfix{,256}, __builtin_ia32_{floorps,ceilps}_sfix{,256}and __builtin_ia32_roundps_az_sfix{,256} descriptions. (ix86_expand_sse_round_vec_pack_sfix): New. (ix86_expand_args_builtin): Handle V4SI_FTYPE_V4SF_ROUND, V8SI_FTYPE_V8SF_ROUND, V4SI_FTYPE_V2DF_V2DF_ROUND and V8SI_FTYPE_V4DF_V4DF_ROUND types. Check last argument of CODE_FOR_sse4_1_roundpd_vec_pack_sfix, CODE_FOR_sse4_1_roundps_sfix, CODE_FOR_avx_roundpd_vec_pack_sfix256 and CODE_FOR_avx_roundps_sfix256. (ix86_builtin_vectorized_function): Handle BUILT_IN_{I,L,LL}FLOOR{,F}, BUILT_IN_{I,L,LL}CEIL{,F} and BUILT_IN_{I,L,LL}ROUND{,F} testsuite/ChangeLog: * gcc.target/i386/sse4_1-floor-sfix-vec.c: New test. * gcc.target/i386/sse4_1-floorf-sfix-vec.c: Ditto. * gcc.target/i386/avx-floor-sfix-vec.c: Ditto. * gcc.target/i386/avx-floorf-sfix-vec.c: Ditto. * gcc.target/i386/sse4_1-ceil-sfix-vec.c: Ditto. * gcc.target/i386/sse4_1-ceilf-sfix-vec.c: Ditto. * gcc.target/i386/avx-ceil-sfix-vec.c: Ditto. * gcc.target/i386/avx-ceilf-sfix-vec.c: Ditto. * gcc.target/i386/sse4_1-round-sfix-vec.c: Ditto. * gcc.target/i386/sse4_1-roundf-sfix-vec.c: Ditto. * gcc.target/i386/avx-round-sfix-vec.c: Ditto. * gcc.target/i386/avx-roundf-sfix-vec.c: Ditto. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@181361 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gcc.target/i386/avx-floor-sfix-vec.c')
-rw-r--r--gcc/testsuite/gcc.target/i386/avx-floor-sfix-vec.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/i386/avx-floor-sfix-vec.c b/gcc/testsuite/gcc.target/i386/avx-floor-sfix-vec.c
new file mode 100644
index 00000000000..efa557cf791
--- /dev/null
+++ b/gcc/testsuite/gcc.target/i386/avx-floor-sfix-vec.c
@@ -0,0 +1,9 @@
+/* { dg-do run } */
+/* { dg-options "-O2 -ffast-math -ftree-vectorize -mavx" } */
+/* { dg-require-effective-target avx } */
+/* { dg-skip-if "no M_PI" { vxworks_kernel } } */
+
+#define CHECK_H "avx-check.h"
+#define TEST avx_test
+
+#include "sse4_1-floor-sfix-vec.c"