diff options
author | Bill Wendling <isanbard@gmail.com> | 2013-11-26 13:34:03 +0000 |
---|---|---|
committer | Bill Wendling <isanbard@gmail.com> | 2013-11-26 13:34:03 +0000 |
commit | c23b3b05499f4518c64a953eea0a2496739e6d24 (patch) | |
tree | 516b09c8db5cfa08f656cd6200e47f9b648a0717 /lib | |
parent | e40ef6a9fc96c74f7df5681a070246ea990499eb (diff) | |
download | external_llvm-c23b3b05499f4518c64a953eea0a2496739e6d24.zip external_llvm-c23b3b05499f4518c64a953eea0a2496739e6d24.tar.gz external_llvm-c23b3b05499f4518c64a953eea0a2496739e6d24.tar.bz2 |
Merging r195408:
------------------------------------------------------------------------
r195408 | jiangning | 2013-11-21 18:45:13 -0800 (Thu, 21 Nov 2013) | 2 lines
For AArch64 back-end instruction selection, lower Neon_Lowxxx with EXTRCT_SUBREG.
------------------------------------------------------------------------
git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_34@195762 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Target/AArch64/AArch64InstrNEON.td | 82 |
1 files changed, 41 insertions, 41 deletions
diff --git a/lib/Target/AArch64/AArch64InstrNEON.td b/lib/Target/AArch64/AArch64InstrNEON.td index f6e747a..98512ec 100644 --- a/lib/Target/AArch64/AArch64InstrNEON.td +++ b/lib/Target/AArch64/AArch64InstrNEON.td @@ -1601,29 +1601,29 @@ def Neon_High4S : PatFrag<(ops node:$in), (extract_subvector (v4i32 node:$in), (iPTR 2))>; def Neon_High2D : PatFrag<(ops node:$in), (extract_subvector (v2i64 node:$in), (iPTR 1))>; -def Neon_High4f : PatFrag<(ops node:$in), - (extract_subvector (v4f32 node:$in), (iPTR 2))>; -def Neon_High2d : PatFrag<(ops node:$in), - (extract_subvector (v2f64 node:$in), (iPTR 1))>; +def Neon_High4float : PatFrag<(ops node:$in), + (extract_subvector (v4f32 node:$in), (iPTR 2))>; +def Neon_High2double : PatFrag<(ops node:$in), + (extract_subvector (v2f64 node:$in), (iPTR 1))>; -def Neon_low16B : PatFrag<(ops node:$in), +def Neon_Low16B : PatFrag<(ops node:$in), (v8i8 (extract_subvector (v16i8 node:$in), (iPTR 0)))>; -def Neon_low8H : PatFrag<(ops node:$in), +def Neon_Low8H : PatFrag<(ops node:$in), (v4i16 (extract_subvector (v8i16 node:$in), (iPTR 0)))>; -def Neon_low4S : PatFrag<(ops node:$in), +def Neon_Low4S : PatFrag<(ops node:$in), (v2i32 (extract_subvector (v4i32 node:$in), (iPTR 0)))>; -def Neon_low2D : PatFrag<(ops node:$in), +def Neon_Low2D : PatFrag<(ops node:$in), (v1i64 (extract_subvector (v2i64 node:$in), (iPTR 0)))>; -def Neon_low4f : PatFrag<(ops node:$in), - (v2f32 (extract_subvector (v4f32 node:$in), - (iPTR 0)))>; -def Neon_low2d : PatFrag<(ops node:$in), - (v1f64 (extract_subvector (v2f64 node:$in), - (iPTR 0)))>; +def Neon_Low4float : PatFrag<(ops node:$in), + (v2f32 (extract_subvector (v4f32 node:$in), + (iPTR 0)))>; +def Neon_Low2double : PatFrag<(ops node:$in), + (v1f64 (extract_subvector (v2f64 node:$in), + (iPTR 0)))>; def neon_uimm3_shift : Operand<i32>, ImmLeaf<i32, [{return Imm < 8;}]> { @@ -5606,17 +5606,17 @@ multiclass NeonI_Scalar_DUP_Elt_pattern<Instruction DUPI, ValueType ResTy, multiclass NeonI_SDUP<PatFrag GetLow, PatFrag GetHigh, ValueType ResTy, ValueType OpTy> { def : Pat<(ResTy (GetLow VPR128:$Rn)), - (ResTy (DUPdv_D (OpTy VPR128:$Rn), 0))>; + (ResTy (EXTRACT_SUBREG (OpTy VPR128:$Rn), sub_64))>; def : Pat<(ResTy (GetHigh VPR128:$Rn)), (ResTy (DUPdv_D (OpTy VPR128:$Rn), 1))>; } -defm : NeonI_SDUP<Neon_low16B, Neon_High16B, v8i8, v16i8>; -defm : NeonI_SDUP<Neon_low8H, Neon_High8H, v4i16, v8i16>; -defm : NeonI_SDUP<Neon_low4S, Neon_High4S, v2i32, v4i32>; -defm : NeonI_SDUP<Neon_low2D, Neon_High2D, v1i64, v2i64>; -defm : NeonI_SDUP<Neon_low4f, Neon_High4f, v2f32, v4f32>; -defm : NeonI_SDUP<Neon_low2d, Neon_High2d, v1f64, v2f64>; +defm : NeonI_SDUP<Neon_Low16B, Neon_High16B, v8i8, v16i8>; +defm : NeonI_SDUP<Neon_Low8H, Neon_High8H, v4i16, v8i16>; +defm : NeonI_SDUP<Neon_Low4S, Neon_High4S, v2i32, v4i32>; +defm : NeonI_SDUP<Neon_Low2D, Neon_High2D, v1i64, v2i64>; +defm : NeonI_SDUP<Neon_Low4float, Neon_High4float, v2f32, v4f32>; +defm : NeonI_SDUP<Neon_Low2double, Neon_High2double, v1f64, v2f64>; // Patterns for vector extract of FP data using scalar DUP instructions defm : NeonI_Scalar_DUP_Elt_pattern<DUPsv_S, f32, @@ -5967,7 +5967,7 @@ multiclass NI_2VE_v1_pat<string subop, SDPatternOperator op> def : NI_2VE_laneq<!cast<Instruction>(subop # "_2s4s"), neon_uimm2_bare, op, VPR64, VPR64, VPR128, v2i32, v2i32, v4i32, BinOpFrag<(Neon_vduplane - (Neon_low4S node:$LHS), node:$RHS)>>; + (Neon_Low4S node:$LHS), node:$RHS)>>; def : NI_2VE_laneq<!cast<Instruction>(subop # "_4s4s"), neon_uimm2_bare, op, VPR128, VPR128, VPR128, v4i32, v4i32, v4i32, @@ -5976,7 +5976,7 @@ multiclass NI_2VE_v1_pat<string subop, SDPatternOperator op> def : NI_2VE_laneq<!cast<Instruction>(subop # "_4h8h"), neon_uimm3_bare, op, VPR64, VPR64, VPR128Lo, v4i16, v4i16, v8i16, BinOpFrag<(Neon_vduplane - (Neon_low8H node:$LHS), node:$RHS)>>; + (Neon_Low8H node:$LHS), node:$RHS)>>; def : NI_2VE_laneq<!cast<Instruction>(subop # "_8h8h"), neon_uimm3_bare, op, VPR128, VPR128, VPR128Lo, v8i16, v8i16, v8i16, @@ -6084,7 +6084,7 @@ multiclass NI_2VE_mul_v1_pat<string subop, SDPatternOperator op> { def : NI_2VE_mul_laneq<!cast<Instruction>(subop # "_2s4s"), neon_uimm2_bare, op, VPR64, VPR128, v2i32, v2i32, v4i32, BinOpFrag<(Neon_vduplane - (Neon_low4S node:$LHS), node:$RHS)>>; + (Neon_Low4S node:$LHS), node:$RHS)>>; def : NI_2VE_mul_laneq<!cast<Instruction>(subop # "_4s4s"), neon_uimm2_bare, op, VPR128, VPR128, v4i32, v4i32, v4i32, @@ -6093,7 +6093,7 @@ multiclass NI_2VE_mul_v1_pat<string subop, SDPatternOperator op> { def : NI_2VE_mul_laneq<!cast<Instruction>(subop # "_4h8h"), neon_uimm3_bare, op, VPR64, VPR128Lo, v4i16, v4i16, v8i16, BinOpFrag<(Neon_vduplane - (Neon_low8H node:$LHS), node:$RHS)>>; + (Neon_Low8H node:$LHS), node:$RHS)>>; def : NI_2VE_mul_laneq<!cast<Instruction>(subop # "_8h8h"), neon_uimm3_bare, op, VPR128, VPR128Lo, v8i16, v8i16, v8i16, @@ -6170,7 +6170,7 @@ multiclass NI_2VE_mul_v2_pat<string subop, SDPatternOperator op> { def : NI_2VE_mul_laneq<!cast<Instruction>(subop # "_2s4s"), neon_uimm2_bare, op, VPR64, VPR128, v2f32, v2f32, v4f32, BinOpFrag<(Neon_vduplane - (Neon_low4f node:$LHS), node:$RHS)>>; + (Neon_Low4float node:$LHS), node:$RHS)>>; def : NI_2VE_mul_laneq<!cast<Instruction>(subop # "_4s4s"), neon_uimm2_bare, op, VPR128, VPR128, v4f32, v4f32, v4f32, @@ -6267,7 +6267,7 @@ multiclass NI_2VE_fma_v2_pat<string subop, SDPatternOperator op> { def : NI_2VEswap_laneq<!cast<Instruction>(subop # "_2s4s"), neon_uimm2_bare, op, VPR64, VPR128, v2f32, v4f32, BinOpFrag<(Neon_vduplane - (Neon_low4f node:$LHS), node:$RHS)>>; + (Neon_Low4float node:$LHS), node:$RHS)>>; def : NI_2VEswap_laneq<!cast<Instruction>(subop # "_4s4s"), neon_uimm2_bare, op, VPR128, VPR128, v4f32, v4f32, @@ -6301,12 +6301,12 @@ multiclass NI_2VE_fms_v2_pat<string subop, SDPatternOperator op> def : NI_2VEswap_laneq<!cast<Instruction>(subop # "_2s4s"), neon_uimm2_bare, op, VPR64, VPR128, v2f32, v4f32, BinOpFrag<(fneg (Neon_vduplane - (Neon_low4f node:$LHS), node:$RHS))>>; + (Neon_Low4float node:$LHS), node:$RHS))>>; def : NI_2VEswap_laneq<!cast<Instruction>(subop # "_2s4s"), neon_uimm2_bare, op, VPR64, VPR128, v2f32, v4f32, BinOpFrag<(Neon_vduplane - (Neon_low4f (fneg node:$LHS)), + (Neon_Low4float (fneg node:$LHS)), node:$RHS)>>; def : NI_2VEswap_laneq<!cast<Instruction>(subop # "_4s4s"), @@ -6474,22 +6474,22 @@ multiclass NI_2VEL_v3_pat<string subop, SDPatternOperator op> { def : NI_2VE_laneq<!cast<Instruction>(subop # "_4s4h"), neon_uimm3_bare, op, VPR128, VPR64, VPR128Lo, v4i32, v4i16, v8i16, BinOpFrag<(Neon_vduplane - (Neon_low8H node:$LHS), node:$RHS)>>; + (Neon_Low8H node:$LHS), node:$RHS)>>; def : NI_2VE_laneq<!cast<Instruction>(subop # "_2d2s"), neon_uimm2_bare, op, VPR128, VPR64, VPR128, v2i64, v2i32, v4i32, BinOpFrag<(Neon_vduplane - (Neon_low4S node:$LHS), node:$RHS)>>; + (Neon_Low4S node:$LHS), node:$RHS)>>; def : NI_2VEL2_laneq<!cast<Instruction>(subop # "_4s8h"), neon_uimm3_bare, op, VPR128Lo, v4i32, v8i16, v8i16, v4i16, Neon_High8H, BinOpFrag<(Neon_vduplane - (Neon_low8H node:$LHS), node:$RHS)>>; + (Neon_Low8H node:$LHS), node:$RHS)>>; def : NI_2VEL2_laneq<!cast<Instruction>(subop # "_2d4s"), neon_uimm2_bare, op, VPR128, v2i64, v4i32, v4i32, v2i32, Neon_High4S, BinOpFrag<(Neon_vduplane - (Neon_low4S node:$LHS), node:$RHS)>>; + (Neon_Low4S node:$LHS), node:$RHS)>>; // Index can only be half of the max value for lane in 64-bit vector @@ -6540,23 +6540,23 @@ multiclass NI_2VEL_mul_v3_pat<string subop, SDPatternOperator op> { def : NI_2VE_mul_laneq<!cast<Instruction>(subop # "_4s4h"), neon_uimm3_bare, op, VPR64, VPR128Lo, v4i32, v4i16, v8i16, BinOpFrag<(Neon_vduplane - (Neon_low8H node:$LHS), node:$RHS)>>; + (Neon_Low8H node:$LHS), node:$RHS)>>; def : NI_2VE_mul_laneq<!cast<Instruction>(subop # "_2d2s"), neon_uimm2_bare, op, VPR64, VPR128, v2i64, v2i32, v4i32, BinOpFrag<(Neon_vduplane - (Neon_low4S node:$LHS), node:$RHS)>>; + (Neon_Low4S node:$LHS), node:$RHS)>>; def : NI_2VEL2_mul_laneq<!cast<Instruction>(subop # "_4s8h"), neon_uimm3_bare, op, VPR128Lo, v4i32, v8i16, v8i16, v4i16, Neon_High8H, BinOpFrag<(Neon_vduplane - (Neon_low8H node:$LHS), node:$RHS)>>; + (Neon_Low8H node:$LHS), node:$RHS)>>; def : NI_2VEL2_mul_laneq<!cast<Instruction>(subop # "_2d4s"), neon_uimm2_bare, op, VPR128, v2i64, v4i32, v4i32, v2i32, Neon_High4S, BinOpFrag<(Neon_vduplane - (Neon_low4S node:$LHS), node:$RHS)>>; + (Neon_Low4S node:$LHS), node:$RHS)>>; // Index can only be half of the max value for lane in 64-bit vector @@ -6599,25 +6599,25 @@ multiclass NI_2VEL_v3_qdma_pat<string subop, string op> { !cast<PatFrag>(op # "_4s"), VPR128, VPR64, VPR128Lo, v4i32, v4i16, v8i16, BinOpFrag<(Neon_vduplane - (Neon_low8H node:$LHS), node:$RHS)>>; + (Neon_Low8H node:$LHS), node:$RHS)>>; def : NI_2VE_laneq<!cast<Instruction>(subop # "_2d2s"), neon_uimm2_bare, !cast<PatFrag>(op # "_2d"), VPR128, VPR64, VPR128, v2i64, v2i32, v4i32, BinOpFrag<(Neon_vduplane - (Neon_low4S node:$LHS), node:$RHS)>>; + (Neon_Low4S node:$LHS), node:$RHS)>>; def : NI_2VEL2_laneq<!cast<Instruction>(subop # "_4s8h"), neon_uimm3_bare, !cast<PatFrag>(op # "_4s"), VPR128Lo, v4i32, v8i16, v8i16, v4i16, Neon_High8H, BinOpFrag<(Neon_vduplane - (Neon_low8H node:$LHS), node:$RHS)>>; + (Neon_Low8H node:$LHS), node:$RHS)>>; def : NI_2VEL2_laneq<!cast<Instruction>(subop # "_2d4s"), neon_uimm2_bare, !cast<PatFrag>(op # "_2d"), VPR128, v2i64, v4i32, v4i32, v2i32, Neon_High4S, BinOpFrag<(Neon_vduplane - (Neon_low4S node:$LHS), node:$RHS)>>; + (Neon_Low4S node:$LHS), node:$RHS)>>; // Index can only be half of the max value for lane in 64-bit vector |