[PATCH] D11218: AVX512 : Integer Truncate with/without saturation support

Elena Demikhovsky elena.demikhovsky at intel.com
Thu Jul 16 11:23:54 PDT 2015


delena added inline comments.

================
Comment at: lib/Target/X86/X86ISelLowering.cpp:15242
@@ -15214,6 +15241,3 @@
 
-    // In case when MaskVT equals v2i1 or v4i1, low 2 or 4 elements
-    // are extracted by EXTRACT_SUBVECTOR.
-    SDValue VMask = DAG.getNode(ISD::EXTRACT_SUBVECTOR, dl, MaskVT,
-                                DAG.getBitcast(BitcastVT, Mask),
-                                DAG.getIntPtrConstant(0, dl));
+    if (MaskVT.bitsGT(Mask.getValueType())){
+      EVT newMaskVT =  EVT::getIntegerVT(*DAG.getContext(),
----------------
space before {

================
Comment at: lib/Target/X86/X86ISelLowering.cpp:15264
@@ -15227,1 +15263,3 @@
         return DAG.getNode(ISD::AND, dl, VT, Op, VMask);
+      case X86ISD::VTRUNC:
+      case X86ISD::VTRUNCS:
----------------
Please add a comment why do you need X86ISD::SELECT here

================
Comment at: lib/Target/X86/X86ISelLowering.cpp:16098
@@ +16097,3 @@
+                                               SelectionDAG &DAG,
+                                               const IntrinsicData *IntrData,
+                                               MVT ElementType) {
----------------
You do not use IntrData and Subtarget in this function.

================
Comment at: lib/Target/X86/X86ISelLowering.cpp:16109
@@ +16108,3 @@
+                             ElementType, VT.getVectorNumElements());
+
+
----------------
remove 1 empty line

================
Comment at: lib/Target/X86/X86ISelLowering.cpp:16116
@@ +16115,3 @@
+
+  EVT MaskVT    = EVT::getVectorVT(*DAG.getContext(),
+                                    MVT::i1, VT.getVectorNumElements());
----------------
remove spaces

================
Comment at: lib/Target/X86/X86ISelLowering.cpp:16129
@@ +16128,3 @@
+      getMachineMemOperand(MachinePointerInfo(),
+                            MachineMemOperand::MOStore, SVT.getStoreSize(),
+                            SVT.getScalarSizeInBits()/8);
----------------
indentation


Repository:
  rL LLVM

http://reviews.llvm.org/D11218







More information about the llvm-commits mailing list