Skip to content

Commit

Permalink
[ARM] Ensure MVE_TwoOpPattern is used inside Predicate's
Browse files Browse the repository at this point in the history
  • Loading branch information
davemgreen committed Nov 22, 2020
1 parent 191117c commit c8c3a41
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions llvm/lib/Target/ARM/ARMInstrMVE.td
Expand Up @@ -1962,9 +1962,10 @@ multiclass MVE_VQxDMULH_m<string iname, MVEVectorVTInfo VTI,
bit rounding> {
def "" : MVE_VQxDMULH_Base<iname, VTI.Suffix, VTI.Size, rounding>;
defvar Inst = !cast<Instruction>(NAME);
defm : MVE_TwoOpPattern<VTI, Op, pred_int, (? ), Inst>;

let Predicates = [HasMVEInt] in {
defm : MVE_TwoOpPattern<VTI, Op, pred_int, (? ), Inst>;

// Extra unpredicated multiply intrinsic patterns
def : Pat<(VTI.Vec (unpred_int (VTI.Vec MQPR:$Qm), (VTI.Vec MQPR:$Qn))),
(VTI.Vec (Inst (VTI.Vec MQPR:$Qm), (VTI.Vec MQPR:$Qn)))>;
Expand Down Expand Up @@ -5492,7 +5493,10 @@ class MVE_VxxMUL_qr<string iname, string suffix,
multiclass MVE_VxxMUL_qr_m<string iname, MVEVectorVTInfo VTI, bit bit_28,
PatFrag Op, Intrinsic int_unpred, Intrinsic int_pred> {
def "" : MVE_VxxMUL_qr<iname, VTI.Suffix, bit_28, VTI.Size>;
defm : MVE_TwoOpPatternDup<VTI, Op, int_pred, (? ), !cast<Instruction>(NAME)>;

let Predicates = [HasMVEInt] in {
defm : MVE_TwoOpPatternDup<VTI, Op, int_pred, (? ), !cast<Instruction>(NAME)>;
}
defm : MVE_vec_scalar_int_pat_m<!cast<Instruction>(NAME), VTI, int_unpred, int_pred>;
}

Expand Down

0 comments on commit c8c3a41

Please sign in to comment.