Commit 57b26d65 by Matthew Wahab Committed by Matthew Wahab

[AArch64] Add sqrdmah, sqrdmsh instructions.

	* config/aarch64/aarch64-simd.md
	(aarch64_sqmovun<mode>): Fix some white-space.
	(aarch64_<sur>qmovun<mode>): Likewise.
	(aarch64_sqrdml<SQRDMLH_AS:rdma_as>h<mode>): New.
	(aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_lane<mode>): New.
	(aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_laneq<mode>): New.
	* config/aarch64/iterators.md (UNSPEC_SQRDMLAH): New.
	(UNSPEC_SQRDMLSH): New.
	(SQRDMLH_AS): New.
	(rdma_as): New.

From-SVN: r230959
parent afad4406
2015-11-26 Matthew Wahab <matthew.wahab@arm.com>
* config/aarch64/aarch64-simd.md
(aarch64_sqmovun<mode>): Fix some white-space.
(aarch64_<sur>qmovun<mode>): Likewise.
(aarch64_sqrdml<SQRDMLH_AS:rdma_as>h<mode>): New.
(aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_lane<mode>): New.
(aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_laneq<mode>): New.
* config/aarch64/iterators.md (UNSPEC_SQRDMLAH): New.
(UNSPEC_SQRDMLSH): New.
(SQRDMLH_AS): New.
(rdma_as): New.
2015-11-26 Richard Biener <rguenther@suse.de> 2015-11-26 Richard Biener <rguenther@suse.de>
PR tree-optimization/66721 PR tree-optimization/66721
...@@ -3081,7 +3081,7 @@ ...@@ -3081,7 +3081,7 @@
"TARGET_SIMD" "TARGET_SIMD"
"sqxtun\\t%<vn2>0<Vmntype>, %<v>1<Vmtype>" "sqxtun\\t%<vn2>0<Vmntype>, %<v>1<Vmtype>"
[(set_attr "type" "neon_sat_shift_imm_narrow_q")] [(set_attr "type" "neon_sat_shift_imm_narrow_q")]
) )
;; sqmovn and uqmovn ;; sqmovn and uqmovn
...@@ -3092,7 +3092,7 @@ ...@@ -3092,7 +3092,7 @@
"TARGET_SIMD" "TARGET_SIMD"
"<sur>qxtn\\t%<vn2>0<Vmntype>, %<v>1<Vmtype>" "<sur>qxtn\\t%<vn2>0<Vmntype>, %<v>1<Vmtype>"
[(set_attr "type" "neon_sat_shift_imm_narrow_q")] [(set_attr "type" "neon_sat_shift_imm_narrow_q")]
) )
;; <su>q<absneg> ;; <su>q<absneg>
...@@ -3180,6 +3180,96 @@ ...@@ -3180,6 +3180,96 @@
[(set_attr "type" "neon_sat_mul_<Vetype>_scalar<q>")] [(set_attr "type" "neon_sat_mul_<Vetype>_scalar<q>")]
) )
;; sqrdml[as]h.
(define_insn "aarch64_sqrdml<SQRDMLH_AS:rdma_as>h<mode>"
[(set (match_operand:VSDQ_HSI 0 "register_operand" "=w")
(unspec:VSDQ_HSI
[(match_operand:VSDQ_HSI 1 "register_operand" "0")
(match_operand:VSDQ_HSI 2 "register_operand" "w")
(match_operand:VSDQ_HSI 3 "register_operand" "w")]
SQRDMLH_AS))]
"TARGET_SIMD_RDMA"
"sqrdml<SQRDMLH_AS:rdma_as>h\\t%<v>0<Vmtype>, %<v>2<Vmtype>, %<v>3<Vmtype>"
[(set_attr "type" "neon_sat_mla_<Vetype>_long")]
)
;; sqrdml[as]h_lane.
(define_insn "aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_lane<mode>"
[(set (match_operand:VDQHS 0 "register_operand" "=w")
(unspec:VDQHS
[(match_operand:VDQHS 1 "register_operand" "0")
(match_operand:VDQHS 2 "register_operand" "w")
(vec_select:<VEL>
(match_operand:<VCOND> 3 "register_operand" "w")
(parallel [(match_operand:SI 4 "immediate_operand" "i")]))]
SQRDMLH_AS))]
"TARGET_SIMD_RDMA"
{
operands[4] = GEN_INT (ENDIAN_LANE_N (<VCOND>mode, INTVAL (operands[4])));
return
"sqrdml<SQRDMLH_AS:rdma_as>h\\t%0.<Vtype>, %2.<Vtype>, %3.<Vetype>[%4]";
}
[(set_attr "type" "neon_sat_mla_<Vetype>_scalar_long")]
)
(define_insn "aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_lane<mode>"
[(set (match_operand:SD_HSI 0 "register_operand" "=w")
(unspec:SD_HSI
[(match_operand:SD_HSI 1 "register_operand" "0")
(match_operand:SD_HSI 2 "register_operand" "w")
(vec_select:<VEL>
(match_operand:<VCOND> 3 "register_operand" "w")
(parallel [(match_operand:SI 4 "immediate_operand" "i")]))]
SQRDMLH_AS))]
"TARGET_SIMD_RDMA"
{
operands[4] = GEN_INT (ENDIAN_LANE_N (<VCOND>mode, INTVAL (operands[4])));
return
"sqrdml<SQRDMLH_AS:rdma_as>h\\t%<v>0, %<v>2, %3.<Vetype>[%4]";
}
[(set_attr "type" "neon_sat_mla_<Vetype>_scalar_long")]
)
;; sqrdml[as]h_laneq.
(define_insn "aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_laneq<mode>"
[(set (match_operand:VDQHS 0 "register_operand" "=w")
(unspec:VDQHS
[(match_operand:VDQHS 1 "register_operand" "0")
(match_operand:VDQHS 2 "register_operand" "w")
(vec_select:<VEL>
(match_operand:<VCONQ> 3 "register_operand" "w")
(parallel [(match_operand:SI 4 "immediate_operand" "i")]))]
SQRDMLH_AS))]
"TARGET_SIMD_RDMA"
{
operands[4] = GEN_INT (ENDIAN_LANE_N (<VCONQ>mode, INTVAL (operands[4])));
return
"sqrdml<SQRDMLH_AS:rdma_as>h\\t%0.<Vtype>, %2.<Vtype>, %3.<Vetype>[%4]";
}
[(set_attr "type" "neon_sat_mla_<Vetype>_scalar_long")]
)
(define_insn "aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_laneq<mode>"
[(set (match_operand:SD_HSI 0 "register_operand" "=w")
(unspec:SD_HSI
[(match_operand:SD_HSI 1 "register_operand" "0")
(match_operand:SD_HSI 2 "register_operand" "w")
(vec_select:<VEL>
(match_operand:<VCONQ> 3 "register_operand" "w")
(parallel [(match_operand:SI 4 "immediate_operand" "i")]))]
SQRDMLH_AS))]
"TARGET_SIMD_RDMA"
{
operands[4] = GEN_INT (ENDIAN_LANE_N (<VCONQ>mode, INTVAL (operands[4])));
return
"sqrdml<SQRDMLH_AS:rdma_as>h\\t%<v>0, %<v>2, %3.<v>[%4]";
}
[(set_attr "type" "neon_sat_mla_<Vetype>_scalar_long")]
)
;; vqdml[sa]l ;; vqdml[sa]l
(define_insn "aarch64_sqdml<SBINQOPS:as>l<mode>" (define_insn "aarch64_sqdml<SBINQOPS:as>l<mode>"
......
...@@ -304,6 +304,8 @@ ...@@ -304,6 +304,8 @@
UNSPEC_PMULL2 ; Used in aarch64-simd.md. UNSPEC_PMULL2 ; Used in aarch64-simd.md.
UNSPEC_REV_REGLIST ; Used in aarch64-simd.md. UNSPEC_REV_REGLIST ; Used in aarch64-simd.md.
UNSPEC_VEC_SHR ; Used in aarch64-simd.md. UNSPEC_VEC_SHR ; Used in aarch64-simd.md.
UNSPEC_SQRDMLAH ; Used in aarch64-simd.md.
UNSPEC_SQRDMLSH ; Used in aarch64-simd.md.
]) ])
;; ------------------------------------------------------------------ ;; ------------------------------------------------------------------
...@@ -975,6 +977,8 @@ ...@@ -975,6 +977,8 @@
UNSPEC_SQSHRN UNSPEC_UQSHRN UNSPEC_SQSHRN UNSPEC_UQSHRN
UNSPEC_SQRSHRN UNSPEC_UQRSHRN]) UNSPEC_SQRSHRN UNSPEC_UQRSHRN])
(define_int_iterator SQRDMLH_AS [UNSPEC_SQRDMLAH UNSPEC_SQRDMLSH])
(define_int_iterator PERMUTE [UNSPEC_ZIP1 UNSPEC_ZIP2 (define_int_iterator PERMUTE [UNSPEC_ZIP1 UNSPEC_ZIP2
UNSPEC_TRN1 UNSPEC_TRN2 UNSPEC_TRN1 UNSPEC_TRN2
UNSPEC_UZP1 UNSPEC_UZP2]) UNSPEC_UZP1 UNSPEC_UZP2])
...@@ -1149,3 +1153,5 @@ ...@@ -1149,3 +1153,5 @@
(UNSPEC_SHA1M "m")]) (UNSPEC_SHA1M "m")])
(define_int_attr sha256_op [(UNSPEC_SHA256H "") (UNSPEC_SHA256H2 "2")]) (define_int_attr sha256_op [(UNSPEC_SHA256H "") (UNSPEC_SHA256H2 "2")])
(define_int_attr rdma_as [(UNSPEC_SQRDMLAH "a") (UNSPEC_SQRDMLSH "s")])
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