[PATCH] D128919: [DAG] Teach isConstOrConstSplat about SPLAT_VECTORs

Paul Walker via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 8 02:48:02 PST 2022


paulwalker-arm added a subscriber: reames.
paulwalker-arm added inline comments.


================
Comment at: llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp:10616
+  EVT VT = N.getValueType();
+  APInt DemandedElts = VT.isVector()
+                           ? APInt::getAllOnes(VT.getVectorMinNumElements())
----------------
Based on @reames's demanded elts patches I think this should be `isFixedLengthVector()`? because we now use a 1bit APInt to represent demanding all elements of a scalable vector.


================
Comment at: llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp:10660
+  EVT VT = N.getValueType();
+  APInt DemandedElts = VT.isVector()
+                           ? APInt::getAllOnes(VT.getVectorMinNumElements())
----------------
As above.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D128919/new/

https://reviews.llvm.org/D128919



More information about the llvm-commits mailing list