[PATCH] D86253: [AMDGPU] Disable stall weight calculation in regbank-reassign
Carl Ritson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 19 20:52:17 PDT 2020
critson added inline comments.
================
Comment at: llvm/lib/Target/AMDGPU/GCNRegBankReassign.cpp:119
if (C.Weight) push_back(C);
else push_front(C);
}
----------------
Is push_front more expensive if we are calling it for every candidate?
Probably just always push_back?
================
Comment at: llvm/lib/Target/AMDGPU/GCNRegBankReassign.cpp:446
{
+ if (!UseWeight)
+ return 0;
----------------
Make this an assertion combined with other change to collectCandidate suggested below?
================
Comment at: llvm/lib/Target/AMDGPU/GCNRegBankReassign.cpp:605
unsigned Weight = getOperandGatherWeight(MI, Reg1, Reg2, StallCycles);
Weight += MLI->getLoopDepth(MI.getParent()) * 10;
----------------
Presumably we don't need to do this if we are not using weights at all (i.e. no sorting)?
Perhaps "if (UseWeight)" all of this?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D86253/new/
https://reviews.llvm.org/D86253
More information about the llvm-commits
mailing list