forked from OSchip/llvm-project
getMachineBasicBlockAddress returns a uintptr_t - don't truncate
to unsigned only to extend back to a pointer sized value on the next line. llvm-svn: 107139
This commit is contained in:
parent
a85a90773c
commit
d34bb4e9b0
|
@ -90,7 +90,7 @@ bool ELFCodeEmitter::finishFunction(MachineFunction &MF) {
|
|||
for (std::vector<MachineRelocation>::iterator MRI = JTRelocations.begin(),
|
||||
MRE = JTRelocations.end(); MRI != MRE; ++MRI) {
|
||||
MachineRelocation &MR = *MRI;
|
||||
unsigned MBBOffset = getMachineBasicBlockAddress(MR.getBasicBlock());
|
||||
uintptr_t MBBOffset = getMachineBasicBlockAddress(MR.getBasicBlock());
|
||||
MR.setResultPointer((void*)MBBOffset);
|
||||
MR.setConstantVal(ES->SectionIdx);
|
||||
JTSection.addRelocation(MR);
|
||||
|
|
Loading…
Reference in New Issue