[PATCH] D130677: [AMDGPU] Fix DGEMM hazard for GFX90a
Stanislav Mekhanoshin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 28 12:09:17 PDT 2022
rampitec added inline comments.
================
Comment at: llvm/lib/Target/AMDGPU/AMDGPU.td:282
+def FeatureDGEMMVALUWriteMemOpBug : SubtargetFeature<"dgemm-valu-write-mem-op-bug",
+ "HasDGEMMVALUWriteMemOpBug",
----------------
I do not believe it deserves a feature bit. These bits are limited.
================
Comment at: llvm/lib/Target/AMDGPU/GCNHazardRecognizer.cpp:2545
+ auto NextMI = std::next(MI.getIterator());
+ if (NextMI == MI.getParent()->end() || !isDGEMM(NextMI->getOpcode()))
+ return false;
----------------
There can be a block with fallthrough, and the next block may start with DGEMM. This check for MBB->end() does not work in this case.
================
Comment at: llvm/lib/Target/AMDGPU/GCNHazardRecognizer.cpp:2551
+
+ for (const MachineOperand &Use : MI->uses()) {
+ if (!Use.isReg() || !TRI.isVectorRegister(MF.getRegInfo(), Use.getReg()))
----------------
There is already a loop across uses above at line 2317, you could just add the check there.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D130677/new/
https://reviews.llvm.org/D130677
More information about the llvm-commits
mailing list