[PATCH] D111737: [AMDGPU] Remove unneeded emit literal check

Joe Nash via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 13 08:51:02 PDT 2021


Joe_Nash created this revision.
Joe_Nash added reviewers: rampitec, foad.
Herald added subscribers: kerbowa, hiraditya, t-tye, tpr, dstuttard, yaxunl, nhaehnle, jvesely, kzhuravl, arsenm.
Joe_Nash requested review of this revision.
Herald added subscribers: llvm-commits, wdng.
Herald added a project: LLVM.

NFC. This check does not verify any functional property since size 8
was added. Remove it for simplicity.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D111737

Files:
  llvm/lib/Target/AMDGPU/MCTargetDesc/SIMCCodeEmitter.cpp


Index: llvm/lib/Target/AMDGPU/MCTargetDesc/SIMCCodeEmitter.cpp
===================================================================
--- llvm/lib/Target/AMDGPU/MCTargetDesc/SIMCCodeEmitter.cpp
+++ llvm/lib/Target/AMDGPU/MCTargetDesc/SIMCCodeEmitter.cpp
@@ -547,8 +547,7 @@
   const MCInstrDesc &Desc = MCII.get(MI.getOpcode());
   if (AMDGPU::isSISrcOperand(Desc, OpNo)) {
     uint32_t Enc = getLitEncoding(MO, Desc.OpInfo[OpNo], STI);
-    if (Enc != ~0U &&
-        (Enc != 255 || Desc.getSize() == 4 || Desc.getSize() == 8))
+    if (Enc != ~0U)
       return Enc;
 
   } else if (MO.isImm())


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D111737.379423.patch
Type: text/x-patch
Size: 595 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20211013/8957d2cf/attachment.bin>


More information about the llvm-commits mailing list