3 ms·
Of course, functions commonly have multiple rets, jump tables at the end, etc. I don't think theres a robust way sans symbols.
by revelation 13y ago
Of course, functions commonly have multiple rets, jump tables at the end, etc. I don't think theres a robust way sans symbols.
- userbinator 13y agoIf you know the address of the function that comes immediately after it, then subtract the two. This will include padding nops at the end etc. so it might be slightly bigger than the real size but you won't be missing bytes from the tail, which is what really matters in this application.
- revelation 13y agoHence why I mention symbols, that would have been exactly the way I'd do it. But without symbols, you can't know what the next function is, thats entirely upon the compiler (linker even) to decide.
- userbinator 13y agoUsually they'll be in the same order as they were in the source code.