[LLVMdev] Increasing TargetRegisterInfo::FirstVirtualRegister?
Jakob Stoklund Olesen
stoklund at 2pi.dk
Sun Jan 9 16:07:31 PST 2011
On Jan 9, 2011, at 3:15 PM, Jakob Stoklund Olesen wrote:
> So I moved the virtual register range to 2^31 growing upwards.
Note that this allows the index translation in an IndexedMap to be optimized away completely in 32-bit builds.
MachineRegisterInfo::setRegClass(unsigned Reg, const TargetRegisterClass *RC) {
const TargetRegisterClass *OldRC = VRegInfo[Reg].first;
Becomes:
movl 12(%ebp), %esi
movl 8(%ebp), %eax
movl (%eax), %ecx
movl (%ecx,%esi,8), %edx
The high bit on the virtual register number falls off in the address computation.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110109/ee9c58db/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 1929 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110109/ee9c58db/attachment.bin>
More information about the llvm-dev
mailing list