<https://github.com/ErisBlastar/osfree/blob/master...
# repolling
a
Unique Title: "Grammatic Retargeting of Executable File Formats Using Specification-Driven Binary Loading" Unique Abstract: This paper presents a formal grammar-based approach to the construction of retargetable loaders for executable binary files. We introduce a Binary-File Format Grammar (BFFG) capable of describing the structure of heterogeneous executable formats through a declarative specification language. The grammar supports dynamic re-referencing of structural metadata—such as array sizes and section offsets—whose values are resolved at load time, a capability absent in conventional programming language type systems. We implement SRL, a Simple Retargetable Loader, which consumes BFFG specifications and generates C-language data structures and loading routines. The system is validated using three distinct binary formats: DOS EXE, Windows NE, and Solaris ELF, covering both CISC and RISC architectures. The generated loader module was successfully integrated into the DCC decompiler, confirming functional equivalence with its handcrafted counterpart. This work contributes a specification-driven methodology for building portable binary manipulation tools, reducing developer effort in multi-platform systems programming and enabling automated interface generation for executable file introspection.