Decompollaborate / spimdisasm

MIPS disassembler
https://pypi.org/project/spimdisasm/
MIT License
45 stars 13 forks source link

[Suggestion]: Add Mips Debug .Mdebug symbols support #159

Closed weirdbeardgame closed 3 months ago

weirdbeardgame commented 7 months ago

Explain the feature

Advantage

Example(s)

https://github.com/weirdbeardgame/Fatal-Frame-2/blob/main/Documentation/Types.h - An example of MDebug symbols read from a Tool called CCC created by ChaoticGD

Or his excellent implementation of CCC included in his Ghidra plugin - https://github.com/chaoticgd/ghidra-emotionengine-reloaded

AngheloAlf commented 7 months ago

I'm not sure mdebug parsing may bring much value to spimdisasm.

My recommendation is to use an external tool to parse the mdebug section and generate a symbol_addrs file that spimdisasm can understand. This tool can parse some flavor of mdebug, you could try to adapt it to generate a symbol_addrs file: https://github.com/decompals/ultralib/blob/main/tools/libelf.py