[PATCH] D33105: [AMDGPU] Turn register pressure estimation into forward tracker

Stanislav Mekhanoshin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon May 15 10:22:53 PDT 2017


rampitec added a comment.

In https://reviews.llvm.org/D33105#755231, @vpykhtin wrote:

> I really don't understand it all. Why not just have reset(MachineInstr *, LiveRegSet ) and do a reset on the next BB with liveset from previous BB? It looks like your code does it. Another question: your reset does skip debugs, but the caller doesn't know about it and can supply unskipped iterator to the next advance.


Reset with liveset will mean copying of the map. This copy is inevitable in other places because that is really a backup copy, but here we do not need anything like that.
The unskipped iterator is not an issue, advance() will immediately return on a debug value. Caller will increment iterator and call advance again(). No problem.


Repository:
  rL LLVM

https://reviews.llvm.org/D33105





More information about the llvm-commits mailing list