[llvm] [WIP][RFC] Teach MCA constant registers do not create dependencies (PR #89387)

Peter Waller via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 23 03:46:45 PDT 2024


================
@@ -962,7 +962,7 @@ void RegisterInfoEmitter::runMCDesc(raw_ostream &OS, CodeGenTarget &Target,
 
   OS << "extern const MCRegisterDesc " << TargetName
      << "RegDesc[] = { // Descriptors\n";
-  OS << "  { " << RegStrings.get("") << ", 0, 0, 0, 0, 0 },\n";
+  OS << "  { " << RegStrings.get("") << ", 0, 0, 0, 0, 0, 0 },\n";
----------------
peterwaller-arm wrote:

It would be the first entry in the array, which is presumably used to make entry '0' a special, invalid register ID. It worked before your update because if you omit entries in a struct initializer, they get zero-initialized.

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


More information about the llvm-commits mailing list