[PATCH] D82551: [AMDGPU] Don't combine DPP if DPP register is used more than once per instruction

Valery Pykhtin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 25 10:14:12 PDT 2020


vpykhtin marked an inline comment as done.
vpykhtin added inline comments.


================
Comment at: llvm/lib/Target/AMDGPU/GCNDPPCombine.cpp:359
+  // see defusechain_iterator::operator++
+  if (!Uses.empty() && Uses.back()->getParent() == Use->getParent()) {
+    LLVM_DEBUG(
----------------
rampitec wrote:
> I assume this exploits the fact we have no instructions which may have more than two uses and are dpp combinable at the same time? If so it deserves a comment.
I'm not sure what do you mean - DPP extension can only be applied to src0 operand.

addUse is called in the order of defuse chain traversal: defusechain_iterator::operator++ assumes that all per instruction uses comes continuosly - so I decided to assume the same.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D82551/new/

https://reviews.llvm.org/D82551





More information about the llvm-commits mailing list