[PATCH] Code Generator Patterns for X86 Gather and Scatter
Craig Topper
craig.topper at gmail.com
Mon Mar 2 21:50:41 PST 2015
REPOSITORY
rL LLVM
================
Comment at: ../include/llvm/Target/TargetSelectionDAG.td:199
@@ -198,1 +198,3 @@
+def SDTMaskedGather: SDTypeProfile<1, 3, [ // masked gather
+ SDTCisVec<0>, SDTCisSameAs<0, 1>, SDTCisVec<2>
----------------
Why isn't this SDTypeProfile<2. 3 ?
================
Comment at: ../lib/Target/X86/X86InstrFragmentsSIMD.td:294
@@ -293,1 +293,3 @@
def X86rcp28s : SDNode<"X86ISD::RCP28", STDFp2SrcRm>;
+def X86mgather : SDNode<"X86ISD::GATHER", SDTypeProfile<1, 3,
+ [SDTCisVec<0>, SDTCisVec<1>, SDTCisVec<2>]>>;
----------------
This doesn't appear to be used.
================
Comment at: ../lib/Target/X86/X86InstrFragmentsSIMD.td:499
@@ +498,3 @@
+ (masked_gather node:$src1, node:$src2, node:$src3) , [{
+ //if (MaskedGatherSDNode *Mgt = dyn_cast<MaskedGatherSDNode>(N))
+ // return (Mgt->getIndex().getValueType() == MVT::v8i32 ||
----------------
Why so much commented out code?
================
Comment at: ../lib/Target/X86/X86InstrInfo.td:723
@@ +722,3 @@
+def vectoraddr : ComplexPattern<iPTR, 5, "SelectAddr", [],[SDNPWantParent]>;
+//def vectoraddr : ComplexPattern<iPTR, 5, "SelectVectorAddr", [],[SDNPWantParent]>;
+
----------------
Why is this commented out?
================
Comment at: ../utils/TableGen/CodeGenDAGPatterns.cpp:1623
@@ +1622,3 @@
+ TreePatternNode *Set2Val = getChild(NC-2);
+ MadeChange = Set2Val->ApplyTypeConstraints(TP, NotRegisters);
+ NumOfSrcs --;
----------------
Shouldn't this be "MadeChange |=" as it is it overwrites the change from the first call.
================
Comment at: ../utils/TableGen/CodeGenDAGPatterns.cpp:1624
@@ +1623,3 @@
+ MadeChange = Set2Val->ApplyTypeConstraints(TP, NotRegisters);
+ NumOfSrcs --;
+ }
----------------
Remove space before the --.
http://reviews.llvm.org/D7665
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
More information about the llvm-commits
mailing list