[llvm] [MC][TableGen] Expand Opcode field of MCInstrDesc (PR #179652)

Jay Foad via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 18 08:12:01 PST 2026


================
@@ -455,7 +455,7 @@ void MapTableEmitter::emitMapFuncBody(raw_ostream &OS, unsigned TableSize) {
       OS << ")\n";
       OS << "    return Table[mid][" << I + 1 << "];\n";
     }
-    OS << "  return -1;";
+    OS << "  return (uint32_t)-1U;";
----------------
jayfoad wrote:

I think this is subtly wrong. The old code returned -1 in the wider type (32-bit) so the new code should also return -1 in the wider type (64-bit). But in fact this code is never exercised, so I raised #182052 to remove it.

https://github.com/llvm/llvm-project/pull/179652


More information about the llvm-commits mailing list