[PATCH] D154193: [X86]Remove TEST in AND32ri+TEST16rr in peephole-opt

Wang, Xin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 3 19:29:51 PDT 2023


XinWang10 updated this revision to Diff 536934.
XinWang10 marked an inline comment as done.
XinWang10 added a comment.

use isUint instead


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D154193

Files:
  llvm/lib/Target/X86/X86InstrInfo.cpp


Index: llvm/lib/Target/X86/X86InstrInfo.cpp
===================================================================
--- llvm/lib/Target/X86/X86InstrInfo.cpp
+++ llvm/lib/Target/X86/X86InstrInfo.cpp
@@ -1004,7 +1004,7 @@
     // want to.
     if (!((VregDefInstr->getOpcode() == X86::AND32ri ||
            VregDefInstr->getOpcode() == X86::AND64ri32) &&
-          isInt<16>(VregDefInstr->getOperand(2).getImm())))
+          isUInt<16>(VregDefInstr->getOperand(2).getImm())))
       return false;
   }
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D154193.536934.patch
Type: text/x-patch
Size: 501 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230704/6627420b/attachment.bin>


More information about the llvm-commits mailing list