[PATCH] D46570: [AMDGPU] Optimzed old value for dpp if unused

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue May 8 00:21:11 PDT 2018


arsenm added inline comments.


================
Comment at: lib/Target/AMDGPU/SIISelLowering.cpp:7402-7418
+  case AMDGPU::V_MOV_B32_dpp: {
+    ConstantSDNode *RM = cast<ConstantSDNode>(Node->getOperand(3));
+    ConstantSDNode *BM = cast<ConstantSDNode>(Node->getOperand(4));
+    ConstantSDNode *BC = cast<ConstantSDNode>(Node->getOperand(5));
+    if (!BC->getZExtValue() ||
+        RM->getZExtValue() != 0xf || BM->getZExtValue() != 0xf)
+      break;
----------------
Can this be done earlier before selection?


https://reviews.llvm.org/D46570





More information about the llvm-commits mailing list