mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-31 20:51:52 +01:00
AMDGPU/RelocVisitor: Handle R_AMDGPU_ABS64
Test is in the separate patch. Differential Revision: https://reviews.llvm.org/D30027 llvm-svn: 297604
This commit is contained in:
parent
58a204a9d1
commit
54c08f6036
@ -155,6 +155,8 @@ private:
|
||||
switch (RelocType) {
|
||||
case llvm::ELF::R_AMDGPU_ABS32:
|
||||
return visitELF_AMDGPU_ABS32(R, Value);
|
||||
case llvm::ELF::R_AMDGPU_ABS64:
|
||||
return visitELF_AMDGPU_ABS64(R, Value);
|
||||
default:
|
||||
HasError = true;
|
||||
return RelocToApply();
|
||||
@ -450,6 +452,11 @@ private:
|
||||
return RelocToApply(Value + Addend, 4);
|
||||
}
|
||||
|
||||
RelocToApply visitELF_AMDGPU_ABS64(RelocationRef R, uint64_t Value) {
|
||||
int64_t Addend = getELFAddend(R);
|
||||
return RelocToApply(Value + Addend, 8);
|
||||
}
|
||||
|
||||
/// I386 COFF
|
||||
RelocToApply visitCOFF_I386_SECREL(RelocationRef R, uint64_t Value) {
|
||||
return RelocToApply(static_cast<uint32_t>(Value), /*Width=*/4);
|
||||
|
Loading…
x
Reference in New Issue
Block a user