[PATCH] D126280: [X86][AMX] Reduce the compiling time for non-amx code.
LuoYuanke via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue May 24 01:47:46 PDT 2022
LuoYuanke created this revision.
Herald added subscribers: pengfei, hiraditya.
Herald added a project: All.
LuoYuanke requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D126280
Files:
llvm/lib/Target/X86/X86FastPreTileConfig.cpp
Index: llvm/lib/Target/X86/X86FastPreTileConfig.cpp
===================================================================
--- llvm/lib/Target/X86/X86FastPreTileConfig.cpp
+++ llvm/lib/Target/X86/X86FastPreTileConfig.cpp
@@ -663,6 +663,18 @@
CfgSS = -1;
unsigned NumVirtRegs = MRI->getNumVirtRegs();
+ // Abandon early if there is no tile register to config.
+ bool HasVirtTileReg = false;
+ for (unsigned I = 0, E = NumVirtRegs; I != E; ++I) {
+ Register VirtReg = Register::index2VirtReg(I);
+ if (MRI->getRegClass(VirtReg)->getID() == X86::TILERegClassID) {
+ HasVirtTileReg = true;
+ break;
+ }
+ }
+ if (!HasVirtTileReg)
+ return false;
+
StackSlotForVirtReg.resize(NumVirtRegs);
MayLiveAcrossBlocks.clear();
// We will create register during config. *3 is to make sure
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D126280.431614.patch
Type: text/x-patch
Size: 816 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220524/9beeb92a/attachment.bin>
More information about the llvm-commits
mailing list