[PATCH] [X86][SSE] Added general integer shuffle matching for MOVQ instruction

Chandler Carruth chandlerc at gmail.com
Tue Feb 3 10:20:07 PST 2015


Minor comments. Good to go with these.


REPOSITORY
  rL LLVM

================
Comment at: lib/Target/X86/X86ISelLowering.cpp:7961
@@ +7960,3 @@
+
+  auto MatchMOVQ = [&]() -> SDValue {
+    // MOVQ copies the lower 64-bits of a vector and zeros the upper 64-bits.
----------------
I would call this "CanZExtLowHalf", and document that it returns the input whose low half can be zext-ed.

Also, no need to use an explicit return in the lambda, it should be deduced.

================
Comment at: lib/Target/X86/X86ISelLowering.cpp:7973
@@ +7972,3 @@
+
+  if (SDValue MOVQ = MatchMOVQ()) {
+    MOVQ = DAG.getNode(ISD::BITCAST, DL, MVT::v2i64, MOVQ);
----------------
I would call the variable 'V'. It isn't a MOVQ (yet).

http://reviews.llvm.org/D7256

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/






More information about the llvm-commits mailing list