aclements / libelfin

C++11 ELF/DWARF parser
MIT License
317 stars 99 forks source link

Special handling for LLVM line info opcodes. #2

Closed ccurtsinger closed 8 years ago

ccurtsinger commented 10 years ago

LLVM uses standard line info opcodes from DWARF 3/4, but specifies version 2.

ccurtsinger commented 10 years ago

I just pushed changes to master that drop the standard_opcodes handling. If an opcode is less than opcode_base, it is handled with the standard meaning in DWARF 4. Other opcodes are handled as vendor-specific.

I'll submit the uninitialized null pointer fix as a separate pull request.

aclements commented 10 years ago

Great.

When you resubmit the null pointer fix, would you mind doing it in the constructor initializer list? Currently, libelfin compiles with GCC 4.6, and as nice as member initializers are, I'd like to keep 4.6 compatibility until it dies off a little more (or until there's a really good reason to drop 4.6 support).

aclements commented 8 years ago

I've cherry-picked (and tweaked) most of these. I left out the shared libraries ones because it looked like you had undone those anyway. Feel free to open another PR with a commit to add shared library support.