logoalt Hacker News

sjmuldertoday at 3:37 PM3 repliesview on HN

Doesn't the loaded code have to be patched for relocations?


Replies

ptsptstoday at 3:44 PM

It does, so not 100% is reused. The patched parts are in different sections though, so the entire .text (code) section ends up being reused.

monocasatoday at 3:47 PM

Not on modern archs that provide decent support for PIE (position independent executables).

show 1 reply
t-3today at 3:50 PM

Not if it's position-independent.