Inline asm linter #159
Labels
decompiler
Improvements to decompiler tooling
good first issue
Good for newcomers
help wanted
Extra attention is needed
Background
The task of "splitting" consists of reconstructing translation units using C/C++ source files using inline assembly. The resulting object files should be relocatable.
To facilitate splitting, we use a set of scripts that auto-generate missing C files based on the global symbol table (symbols.txt).
Problem
The splitting script's outputs is dumb and emits direct data references to absolute addresses. This results in non-relocatable code that will crash when recompiling in a context that differs from the original game.
Examples of violating patterns.
Wrong:
Correct:
Wrong:
Correct:
Wrong:
Correct:
Work to be done
Create a script that scans through source files with violating patterns.
A bunch of regex is likely more than enough.
The text was updated successfully, but these errors were encountered: