rainers / cv2pdb

converter of DMD CodeView/DWARF debug information to PDB files
Artistic License 2.0
466 stars 110 forks source link

Refactor PE image section handling. Add debug logging. #68

Closed neerajsi-msft closed 2 years ago

neerajsi-msft commented 2 years ago

Encapsulate dwarf-related PE sections into a new class. Remove some unused sections.

Move the context set via DIECursor::setContext to be static members of the class and add a debug context there.

Add a standard method of enabling debug logging across the dwarf and PDB code.

These are prep changes for supporting DWARF5

neerajsi-msft commented 2 years ago

@dscho : this is a prep patch for dwarf5 support.

dscho commented 2 years ago

@dscho : this is a prep patch for dwarf5 support.

Thank you!

@rainers FYI @neerajsi-msft noticed that the function symbols are missing from the output of cv2pdb when processing executables produced by GCC v11.x, and is working on extending the DWARF5 support properly (i.e. cleaning up after the mess I left by implementing "too little" of DWARF5 support).

neerajsi-msft commented 2 years ago

Thanks for the feedback Johannes. I have another PR in the stack at https://github.com/neerajsi-msft/cv2pdb/pull/1.

I didn't want to make too many PRs and commits since it's harder to ensure that each one is actually tested.

neerajsi-msft commented 2 years ago

I'm closing this PR in favor of a single PR that implements all of dwarf5 support.

We can split that PR as appropriate according to Rainer's wishes.