[clang] [llvm] [X86][AMX] Support AMX-AVX512 (PR #114070)
Phoebe Wang via cfe-commits
cfe-commits at lists.llvm.org
Wed Nov 6 01:56:43 PST 2024
================
@@ -559,12 +559,68 @@ bool X86ExpandPseudo::expandMI(MachineBasicBlock &MBB,
return true;
}
case X86::PTILELOADDV:
- case X86::PTILELOADDT1V: {
+ case X86::PTILELOADDT1V:
+ case X86::PTCVTROWD2PSrreV:
+ case X86::PTCVTROWD2PSrriV:
+ case X86::PTCVTROWPS2PBF16HrreV:
+ case X86::PTCVTROWPS2PBF16HrriV:
+ case X86::PTCVTROWPS2PBF16LrreV:
+ case X86::PTCVTROWPS2PBF16LrriV:
+ case X86::PTCVTROWPS2PHHrreV:
+ case X86::PTCVTROWPS2PHHrriV:
+ case X86::PTCVTROWPS2PHLrreV:
+ case X86::PTCVTROWPS2PHLrriV:
+ case X86::PTILEMOVROWrreV:
+ case X86::PTILEMOVROWrriV: {
for (unsigned i = 2; i > 0; --i)
MI.removeOperand(i);
- unsigned Opc = Opcode == X86::PTILELOADDV
- ? GET_EGPR_IF_ENABLED(X86::TILELOADD)
- : GET_EGPR_IF_ENABLED(X86::TILELOADDT1);
+ unsigned Opc;
+ switch (Opcode) {
+ case X86::PTILELOADDV:
+ Opc = GET_EGPR_IF_ENABLED(X86::TILELOADD);
+ break;
+ case X86::PTILELOADDT1V:
+ Opc = GET_EGPR_IF_ENABLED(X86::TILELOADDT1);
+ break;
+ case X86::PTCVTROWD2PSrreV:
+ Opc = X86::TCVTROWD2PSrre;
+ break;
+ case X86::PTCVTROWD2PSrriV:
+ Opc = X86::TCVTROWD2PSrri;
+ break;
+ case X86::PTCVTROWPS2PBF16HrreV:
+ Opc = X86::TCVTROWPS2PBF16Hrre;
+ break;
+ case X86::PTCVTROWPS2PBF16HrriV:
+ Opc = X86::TCVTROWPS2PBF16Hrri;
+ break;
+ case X86::PTCVTROWPS2PBF16LrreV:
+ Opc = X86::TCVTROWPS2PBF16Lrre;
+ break;
+ case X86::PTCVTROWPS2PBF16LrriV:
+ Opc = X86::TCVTROWPS2PBF16Lrri;
+ break;
+ case X86::PTCVTROWPS2PHHrreV:
+ Opc = X86::TCVTROWPS2PHHrre;
+ break;
+ case X86::PTCVTROWPS2PHHrriV:
+ Opc = X86::TCVTROWPS2PHHrri;
+ break;
+ case X86::PTCVTROWPS2PHLrreV:
+ Opc = X86::TCVTROWPS2PHLrre;
+ break;
+ case X86::PTCVTROWPS2PHLrriV:
+ Opc = X86::TCVTROWPS2PHLrri;
+ break;
+ case X86::PTILEMOVROWrreV:
+ Opc = X86::TILEMOVROWrre;
+ break;
+ case X86::PTILEMOVROWrriV:
+ Opc = X86::TILEMOVROWrri;
+ break;
+ default:
+ llvm_unreachable("Impossible Opcode!");
----------------
phoebewang wrote:
Done.
https://github.com/llvm/llvm-project/pull/114070
More information about the cfe-commits
mailing list