mirror of
https://codeberg.org/ziglang/zig.git
synced 2026-04-26 13:01:34 +03:00
link.Elf: support R_X86_64_PC64
This commit is contained in:
@@ -983,7 +983,7 @@ const x86_64 = struct {
|
||||
}
|
||||
},
|
||||
|
||||
.PC32 => {
|
||||
.PC32, .PC64 => {
|
||||
try atom.scanReloc(symbol, rel, pcRelocAction(symbol, elf_file), elf_file);
|
||||
},
|
||||
|
||||
@@ -1083,6 +1083,7 @@ const x86_64 = struct {
|
||||
|
||||
.PLT32 => mem.writeInt(i32, code[r_offset..][0..4], @as(i32, @intCast(S + A - P)), .little),
|
||||
.PC32 => mem.writeInt(i32, code[r_offset..][0..4], @as(i32, @intCast(S + A - P)), .little),
|
||||
.PC64 => mem.writeInt(i64, code[r_offset..][0..8], S + A - P, .little),
|
||||
|
||||
.GOTPCREL => mem.writeInt(i32, code[r_offset..][0..4], @as(i32, @intCast(G + GOT + A - P)), .little),
|
||||
.GOTPC32 => mem.writeInt(i32, code[r_offset..][0..4], @as(i32, @intCast(GOT + A - P)), .little),
|
||||
|
||||
Reference in New Issue
Block a user