[PATCH] D117562: [AMDGPU] Sink immediate VGPR defs if high RP

Valery Pykhtin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 26 03:51:29 PST 2022


vpykhtin added a comment.

In D117562#3271947 <https://reviews.llvm.org/D117562#3271947>, @foad wrote:

> 



> As for RA not sinking defs back into the loop, I guess this is because RA does not know about occupancy? So here's a radical idea: after (pre-RA) scheduling, when we know what occupancy we //want// to achieve, why not make that occupancy a hard requirement, marking all other vgprs reserved? Then RA would have to stick to the budget, spilling if necessary. And yes spilling can be really bad, but just failing to meet your occupancy target can also be really bad.

I think we don't know the occupancy we want to achieve unless there is a user requirement. In general its hard to say what is more beneficial: to have larger occupancy or less spills


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D117562



More information about the llvm-commits mailing list