[PATCH] D124378: [X86][AMX] combine tile cast and load/store instruction.
Xiang Zhang via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 26 01:15:30 PDT 2022
xiangzhangllvm added inline comments.
================
Comment at: llvm/lib/Target/X86/X86LowerAMXType.cpp:947
+ if (!isAMXInstrinsic(II))
+ return;
+ std::tie(Row, Col) = getShape(II, OpNo);
----------------
LuoYuanke wrote:
> xiangzhangllvm wrote:
> > >return
> > Here has chance to get shape for other user.
> Yes, how about add TODO for it?
No problem.
================
Comment at: llvm/lib/Target/X86/X86LowerAMXType.cpp:994
+ // Set the operand is null so that load instruction can be erased.
+ Cast->setOperand(0, nullptr);
+ Load->eraseFromParent();
----------------
LuoYuanke wrote:
> xiangzhangllvm wrote:
> > How about the Cast has other non load users
> In line 985, it has checked load only has one use. The cast can have more than one users, compiler would replace all the cast user with tileload instruction.
Yes, there is no problem **if** we can make sure the Cast is only used by Load(s) .
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D124378/new/
https://reviews.llvm.org/D124378
More information about the llvm-commits
mailing list