Skip to content

Commit

Permalink
Reorganize ELF writer, add jit::elf namespace
Browse files Browse the repository at this point in the history
Summary:
There's a lot of changes in this diff, but it's just refactoring, the resulting
ELF object is unchanged.

Switches to writing the section headers first, then the segment headers (aka the
program headers).  The segments will be defined in terms of the sections.

Moves the scattered state of the file (symbol tables, string tables, current
section offset) into an `Object` class that represents the entire file, minus
the code entries themselves.

Also prepare for adding more segments by turning the segment header field into
an array.

Reviewed By: swtaarrs

Differential Revision: D56069175

fbshipit-source-id: cc905d4a3beef78d8733aa0a11c94a51bd40958c
  • Loading branch information
Alex Malyshev authored and facebook-github-bot committed Apr 15, 2024
1 parent 109a6fa commit 674275b
Show file tree
Hide file tree
Showing 4 changed files with 382 additions and 338 deletions.
Loading

0 comments on commit 674275b

Please sign in to comment.