Skip to content

Make elf loading respect phdr VAs #1408

@syntactically

Description

@syntactically

Currently, we load the elf binary in an odd way that does not really respect the VAs on the segments in the file, because, in the past, the virtual memory system depended on identity-mapping for code segments, and we were trying not to use too much VA space. The logic assumes the binary is PIE, although it currently works somewhat by happenstance for at least one non-PIE binary (#1385 (comment)).

Now that we have much less dependence on identity-mapped code segments, we should change this to a more normal loader that actually creates the VAs in the header (basing PIE executables at some reasonable base address).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions