This is an archive of the discontinued LLVM Phabricator instance.

AMDGPU: Analyze callee resource usage in AsmPrinter
ClosedPublic

Authored by arsenm on Jul 28 2017, 10:16 AM.

Diff Detail

Event Timeline

arsenm created this revision.Jul 28 2017, 10:16 AM
rampitec added inline comments.Jul 28 2017, 11:35 AM
lib/Target/AMDGPU/AMDGPUAsmPrinter.cpp
516

Is this expensive loop really needed? Why cannot we rely on isPhysRegUsed?

609

Some compilers will warn about absence of parenthesis around condition.

617

Add otherwise unused operand to s_swappc_b64 maybe?

arsenm added a comment.Aug 1 2017, 6:34 PM

I accidentally committed this in r309781

lib/Target/AMDGPU/AMDGPUAsmPrinter.cpp
516

This is what it did prior to r300482. isPhysRegUsed sees the regmasks on the calls, which assume essentially every high register is used.

617

The verifier doesn't accept that

617

Specifically you can't have an implicit use of a non-register operand

rampitec added inline comments.Aug 29 2017, 12:24 PM
lib/Target/AMDGPU/AMDGPUAsmPrinter.cpp
516

So r300482 is committed, I guess you can get rid of the loop now.

arsenm accepted this revision.Nov 28 2017, 6:31 PM
This revision is now accepted and ready to land.Nov 28 2017, 6:31 PM
arsenm closed this revision.Nov 28 2017, 6:31 PM