[PATCH] D36004: AMDGPU: Analyze callee resource usage in AsmPrinter

Stanislav Mekhanoshin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 29 12:24:30 PDT 2017


rampitec added inline comments.


================
Comment at: lib/Target/AMDGPU/AMDGPUAsmPrinter.cpp:516
+
+  for (const MachineBasicBlock &MBB : MF) {
+    for (const MachineInstr &MI : MBB) {
----------------
arsenm wrote:
> rampitec wrote:
> > Is this expensive loop really needed? Why cannot we rely on isPhysRegUsed?
> This is what it did prior to r300482. isPhysRegUsed sees the regmasks on the calls, which assume essentially every high register is used.
So r300482 is committed, I guess you can get rid of the loop now.


https://reviews.llvm.org/D36004





More information about the llvm-commits mailing list