================
@@ -452,7 +465,11 @@ bool 
X86PreTileConfigImpl::runOnMachineFunction(MachineFunction &MF) {
         .addReg(Xmm);
   }
   // Fill in the palette first.
-  addFrameReference(BuildMI(MBB, MI, DL, TII->get(X86::MOV8mi)), SS).addImm(1);
+  // Use Palette 2 for ACE v1, Palette 1 for AMX.
+  int PaletteId =
+      X86FI->getACEProgModel() == ACEProgModelEnum::ACE_ManagedRA ? 2 : 1;
+  addFrameReference(BuildMI(MBB, MI, DL, TII->get(X86::MOV8mi)), SS)
+      .addImm(PaletteId);
----------------
ganeshgit wrote:

For ManagedRA, both passes identify the palette the same way, from the 
per-function program model, so neither supports a function holding tiles of 
both palettes. Moving off the subtarget check fixed the case @e-kud raised, AMX 
code on an ACE target.

https://github.com/llvm/llvm-project/pull/208408
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to