Commit 2ef16e3e by James Greenhalgh Committed by James Greenhalgh

[AArch64] Wire up vqdmullh_laneq_s16 and vqdmullh_laneq_s32

gcc/

	* config/aarch64/aarch64-simd-builtins.def (sqdmull_laneq): Expand
	iterator.
	* config/aarch64/aarch64-simd.md
	(aarch64_sqdmull_laneq<mode>): Expand iterator.
	* config/aarch64/arm_neon.h (vqdmullh_laneq_s16): New.
	(vqdmulls_lane_s32): Fix return type.
	(vqdmulls_laneq_s32): New.

gcc/testsuite/

	* gcc.target/aarch64/simd/vqdmullh_laneq_s16.c: New.
	* gcc.target/aarch64/simd/vqdmulls_laneq_s32.c: Likewise.
	* gcc.target/aarch64/simd/vqdmulls_lane_s32.c: Fix return type.
	* gcc.target/aarch64/scalar_intrinsics.c (test_vqdmulls_s32):  Fix
	return type.

From-SVN: r215722
parent c95e8563
2014-09-30 James Greenhalgh <james.greenhalgh@arm.com>
* config/aarch64/aarch64-simd-builtins.def (sqdmull_laneq): Expand
iterator.
* config/aarch64/aarch64-simd.md
(aarch64_sqdmull_laneq<mode>): Expand iterator.
* config/aarch64/arm_neon.h (vqdmullh_laneq_s16): New.
(vqdmulls_lane_s32): Fix return type.
(vqdmulls_laneq_s32): New.
2014-09-30 Jakub Jelinek <jakub@redhat.com> 2014-09-30 Jakub Jelinek <jakub@redhat.com>
PR inline-asm/63282 PR inline-asm/63282
...@@ -155,7 +155,7 @@ ...@@ -155,7 +155,7 @@
BUILTIN_VSD_HSI (BINOP, sqdmull, 0) BUILTIN_VSD_HSI (BINOP, sqdmull, 0)
BUILTIN_VSD_HSI (TERNOP, sqdmull_lane, 0) BUILTIN_VSD_HSI (TERNOP, sqdmull_lane, 0)
BUILTIN_VD_HSI (TERNOP, sqdmull_laneq, 0) BUILTIN_VSD_HSI (TERNOP, sqdmull_laneq, 0)
BUILTIN_VD_HSI (BINOP, sqdmull_n, 0) BUILTIN_VD_HSI (BINOP, sqdmull_n, 0)
BUILTIN_VQ_HSI (BINOP, sqdmull2, 0) BUILTIN_VQ_HSI (BINOP, sqdmull2, 0)
BUILTIN_VQ_HSI (TERNOP, sqdmull2_lane, 0) BUILTIN_VQ_HSI (TERNOP, sqdmull2_lane, 0)
......
...@@ -3398,7 +3398,7 @@ ...@@ -3398,7 +3398,7 @@
(define_expand "aarch64_sqdmull_laneq<mode>" (define_expand "aarch64_sqdmull_laneq<mode>"
[(match_operand:<VWIDE> 0 "register_operand" "=w") [(match_operand:<VWIDE> 0 "register_operand" "=w")
(match_operand:VD_HSI 1 "register_operand" "w") (match_operand:VSD_HSI 1 "register_operand" "w")
(match_operand:<VCONQ> 2 "register_operand" "<vwx>") (match_operand:<VCONQ> 2 "register_operand" "<vwx>")
(match_operand:SI 3 "immediate_operand" "i")] (match_operand:SI 3 "immediate_operand" "i")]
"TARGET_SIMD" "TARGET_SIMD"
......
...@@ -19420,16 +19420,28 @@ vqdmullh_lane_s16 (int16_t __a, int16x4_t __b, const int __c) ...@@ -19420,16 +19420,28 @@ vqdmullh_lane_s16 (int16_t __a, int16x4_t __b, const int __c)
return __builtin_aarch64_sqdmull_lanehi (__a, __b, __c); return __builtin_aarch64_sqdmull_lanehi (__a, __b, __c);
} }
__extension__ static __inline int32_t __attribute__ ((__always_inline__))
vqdmullh_laneq_s16 (int16_t __a, int16x8_t __b, const int __c)
{
return __builtin_aarch64_sqdmull_laneqhi (__a, __b, __c);
}
__extension__ static __inline int64_t __attribute__ ((__always_inline__)) __extension__ static __inline int64_t __attribute__ ((__always_inline__))
vqdmulls_s32 (int32_t __a, int32_t __b) vqdmulls_s32 (int32_t __a, int32_t __b)
{ {
return __builtin_aarch64_sqdmullsi (__a, __b); return __builtin_aarch64_sqdmullsi (__a, __b);
} }
__extension__ static __inline int64x1_t __attribute__ ((__always_inline__)) __extension__ static __inline int64_t __attribute__ ((__always_inline__))
vqdmulls_lane_s32 (int32_t __a, int32x2_t __b, const int __c) vqdmulls_lane_s32 (int32_t __a, int32x2_t __b, const int __c)
{ {
return (int64x1_t) {__builtin_aarch64_sqdmull_lanesi (__a, __b, __c)}; return __builtin_aarch64_sqdmull_lanesi (__a, __b, __c);
}
__extension__ static __inline int64_t __attribute__ ((__always_inline__))
vqdmulls_laneq_s32 (int32_t __a, int32x4_t __b, const int __c)
{
return __builtin_aarch64_sqdmull_laneqsi (__a, __b, __c);
} }
/* vqmovn */ /* vqmovn */
......
2014-09-30 James Greenhalgh <james.greenhalgh@arm.com>
* gcc.target/aarch64/simd/vqdmullh_laneq_s16.c: New.
* gcc.target/aarch64/simd/vqdmulls_laneq_s32.c: Likewise.
* gcc.target/aarch64/simd/vqdmulls_lane_s32.c: Fix return type.
* gcc.target/aarch64/scalar_intrinsics.c (test_vqdmulls_s32): Fix
return type.
2014-30-09 Dominique d'Humieres <dominiq@lps.ens.fr> 2014-30-09 Dominique d'Humieres <dominiq@lps.ens.fr>
* gfortran.dg/coarray_collectives_9.f90: Fix some dg-error. * gfortran.dg/coarray_collectives_9.f90: Fix some dg-error.
......
...@@ -501,7 +501,7 @@ test_vqdmulls_s32 (int32_t a, int32_t b) ...@@ -501,7 +501,7 @@ test_vqdmulls_s32 (int32_t a, int32_t b)
/* { dg-final { scan-assembler-times "\\tsqdmull\\td\[0-9\]+, s\[0-9\]+, v" 1 } } */ /* { dg-final { scan-assembler-times "\\tsqdmull\\td\[0-9\]+, s\[0-9\]+, v" 1 } } */
int64x1_t int64_t
test_vqdmulls_lane_s32 (int32_t a, int32x2_t b) test_vqdmulls_lane_s32 (int32_t a, int32x2_t b)
{ {
return vqdmulls_lane_s32 (a, b, 1); return vqdmulls_lane_s32 (a, b, 1);
......
/* Test the vqdmullh_laneq_s16 AArch64 SIMD intrinsic. */
/* { dg-do compile } */
/* { dg-options "-save-temps -O3 -fno-inline" } */
#include "arm_neon.h"
int32_t
t_vqdmullh_laneq_s16 (int16_t a, int16x8_t b)
{
return vqdmullh_laneq_s16 (a, b, 0);
}
/* { dg-final { scan-assembler-times "sqdmull\[ \t\]+\[sS\]\[0-9\]+, ?\[hH\]\[0-9\]+, ?\[vV\]\[0-9\]+\.\[hH\]\\\[0\\\]\n" 1 } } */
/* { dg-final { cleanup-saved-temps } } */
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
#include "arm_neon.h" #include "arm_neon.h"
int64x1_t int64_t
t_vqdmulls_lane_s32 (int32_t a, int32x2_t b) t_vqdmulls_lane_s32 (int32_t a, int32x2_t b)
{ {
return vqdmulls_lane_s32 (a, b, 0); return vqdmulls_lane_s32 (a, b, 0);
......
/* Test the vqdmulls_laneq_s32 AArch64 SIMD intrinsic. */
/* { dg-do compile } */
/* { dg-options "-save-temps -O3 -fno-inline" } */
#include "arm_neon.h"
int64_t
t_vqdmulls_laneq_s32 (int32_t a, int32x4_t b)
{
return vqdmulls_laneq_s32 (a, b, 0);
}
/* { dg-final { scan-assembler-times "sqdmull\[ \t\]+\[dD\]\[0-9\]+, ?\[sS\]\[0-9\]+, ?\[vV\]\[0-9\]+\.\[sS\]\\\[0\\\]\n" 1 } } */
/* { dg-final { cleanup-saved-temps } } */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment