Avoid looping through program to determine register counts.
This avoids needing to look at regmask operands.
Also fixes some counting errors with flat_scr when there
are no stack objects.
Paths
| Differential D31411
AMDGPU: Use MachineRegisterInfo to find max used register ClosedPublic Authored by arsenm on Mar 27 2017, 5:12 PM.
Details
Summary Avoid looping through program to determine register counts. Also fixes some counting errors with flat_scr when there
Diff Detail Event TimelineHerald added subscribers: t-tye, tpr, dstuttard and 4 others. · View Herald TranscriptMar 27 2017, 5:12 PM This revision is now accepted and ready to land.Apr 12 2017, 1:27 PM
Revision Contents
Diff 93201 lib/Target/AMDGPU/AMDGPUAsmPrinter.h
lib/Target/AMDGPU/AMDGPUAsmPrinter.cpp
test/CodeGen/AMDGPU/code-object-metadata-from-llvm-ir-full.ll
test/CodeGen/AMDGPU/exceed-max-sgprs.ll
test/CodeGen/AMDGPU/flat-scratch-reg.ll
|
RI->getEncodingValue(NumVGPRReg) & 0xff -> RI->getHWRegIndex(NumVGPRReg)?