search for: r_symbolnum

Displaying 2 results from an estimated 2 matches for "r_symbolnum".

2014 Jun 09
4
[LLVMdev] MachO non-external X86_64_RELOC_UNSIGNED
Hello everybody, I would like some insights on the semantics of the X86_64_RELOC_UNSIGNED relocation type. When r_extern=1, the semantics seem pretty clear: Let x be a pointer to r_offset of appropriate size given by r_size, then *x += addr_of_symbol(r_symbolnum) However, when r_extern=0 the correct behavior is not clear. By analogy with the above, I would have expected *x += addr_of_section(r_symbolnum) but what LLVM implements is different. In RTDyld it implements *x = (*x-addr_of_section(r_symbolnum)) + addr_of_section(r_symbolnum) or equivalently...
2014 Jun 10
4
[LLVMdev] MachO non-external X86_64_RELOC_UNSIGNED
Thank you for the explanation. Does that mean r_symbolnum is basically redundant in that case? Also, let me ask you how to handle the following use case which is somewhat related. Currently in MCJIT for MachO we are relocating all the debug sections. Eventually (as ELF does), it would be good to avoid this. However, this means that the debugger would have...