summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* more pre-DWARF5 refactoring: unit headers, location cursor, range cursorNeeraj Singh2021-12-025-152/+243
| | | | | | | | | | | Read the compilation unit header byte-by-byte rather than by casting the data to a structure. Add the currentBaseAddress contextual info to the compilation unit data. Move the LOCCursor into readDwarf.cpp. Implement a RangeCursor similar to the LOCCursor. Add more debug printing.
* carry contextual information with the DIECursorNeeraj Singh2021-12-024-77/+91
| | | | | | | | | | DWARF5 has more contextual information that is associated with the compilation unit. As a preparation for using such information, carry it with the DIECursor and eliminate places where we're passing in the parent compilation unit. Also add the RDAddr helper to read a target-address according to the specification in the compilation unit.
* Refactor PE image section handling. Add debug logging.Neeraj Singh2021-12-029-171/+291
| | | | | | | | | | | Encapsulate dwarf-related PE sections into the PESection class. Remove some unused sections. Add helpers for common section operations. 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.
* update to version 0.49v0.49Rainer Schuetze2021-11-062-1/+7
|
* Merge pull request #66 from dscho/vswhereRainer Schuetze2021-11-032-0/+122
|\ | | | | Allow the mspdb DLL to be found via vswhere.exe
| * Verify in the GitHub workflow that cv2pdb can handle GCC's outputJohannes Schindelin2021-11-031-1/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Git for Windows uses cv2pdb to convert the debugging information produced by GCC to `.pdb` format, for use with Visual C's tools. A recent GCC upgrade broke this because the debugging information was produced in DWARF5 format, and the Git for Windows maintainer had to scramble to implement (minimal) support for that format. Let's verify in the GitHub workflow that cv2pdb can handle GCC's output format, and let's use the very same GCC version that Git for Windows uses to verify that. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
| * Add a GitHub workflow to build cv2pdbJohannes Schindelin2021-11-031-0/+28
| | | | | | | | Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
| * Allow the mspdb DLL to be found via vswhere.exeJohannes Schindelin2021-11-031-0/+67
|/ | | | | | | | | | | | | | The incredibly useful `vswhere.exe` tool can be used to abstract away all the nitty-gritty details of figuring out where Visual Studio is installed. This patch adds support for making use of that tool. Since spawning a process is pretty expensive compared to looking at the registry, we only fall back on this tool (if it exists) if the other methods to find the DLL have failed. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
* Merge pull request #67 from dscho/dwarf5Rainer Schuetze2021-10-305-27/+174
|\ | | | | Add rudimentary support for DWARF5
| * Add rudimentary support for DWARF5Johannes Schindelin2021-10-295-27/+174
|/ | | | | | | | | | | This allows `cv2pdb` to process executables produced by the mingw-w64 version of GCC v11.x. The symptoms of the fixed issue would look like this: error: cannot add line number info to module Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
* fix #61: implement DWARF4 line number headersv0.48Rainer Schuetze2020-05-082-4/+39
|
* Merge pull request #60 from oltolm/cache_onlyRainer Schuetze2020-05-053-26/+38
|\ | | | | introduce a symbol cache
| * introduce a symbol cacheoltolm2020-05-043-26/+38
|/
* DWRAF: fix BSS handling and symbol-sectionRainer Schuetze2020-03-302-3/+4
|
* fix issue #59: add DWARF support for symbol to imported dataRainer Schuetze2020-03-265-5/+39
|
* fix loading 64-bit mspdb140.dll in VS2019Rainer Schuetze2020-03-092-1/+26
|
* adapt wchar/dchar to newer versions of dmd, add cent/ucentRainer Schuetze2020-03-091-1/+4
|
* Merge pull request #58 from dscho/invalidate-symbol-tableRainer Schuetze2020-03-091-0/+13
|\ | | | | Fix `.exe` files (according to dumpbin/objdump)
| * Force invalidation of the symbol table offsetJohannes Schindelin2020-03-081-0/+13
|/ | | | | | | | | | | | | When writing a new `.exe`/`.pdb` pair, the `.exe` might not contain any symbols. Therefore, the stale info needs to be zeroed out. This lets `dumpbin` and `objdump` accept the generated `.exe` files without problems. This fixes https://github.com/rainers/cv2pdb/issues/35 and https://github.com/git-for-windows/git/issues/2200. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
* DWARF: fix writing info for aggregates larger than 32kBRainer Schuetze2019-07-183-5/+11
|
* Merge pull request #51 from marc-groundctl/more-line-numbersRainer Schuetze2019-02-152-70/+74
|\ | | | | Add more line number information
| * Don't write line sequences containing decreasing addressesMarc Aldorasi2019-02-151-1/+6
| |
| * Removed unnecessary headerMarc Aldorasi2019-02-131-2/+0
| |
| * Delay adding lines until we know the end of the line's address rangeMarc Aldorasi2019-02-132-61/+61
| |
| * VS2013 doesn't like lambdas with auto parametersMarc Aldorasi2019-02-071-1/+1
| |
| * Work around ld bug 24192Marc Aldorasi2019-02-071-6/+1
| |
| * Rewrite line translation to handle decreasing line numbersMarc Aldorasi2019-02-071-30/+36
| |
* | Merge pull request #49 from marc-groundctl/label-more-functionsRainer Schuetze2019-02-083-22/+115
|\ \ | |/ | | Label more functions
| * Improve merging DWARF_InfoDataMarc Aldorasi2019-02-062-3/+10
| |
| * Exclude artificial functions and inherit attributes from abstract originsMarc Aldorasi2019-02-043-55/+88
| |
| * Try harder to get function entry pointsMarc Aldorasi2019-02-043-3/+56
|/
* DWARF: fixed converting unnamed structs/unions as part of other structsRainer Schuetze2019-01-256-63/+113
|
* Merge pull request #46 from rainers/readme_mdRainer Schuetze2019-01-242-9/+18
|\ | | | | rename README to README.MD
| * adjust fomrattingreadme_mdRainer Schuetze2019-01-242-9/+18
| |
| * rename README to README.MDRainer Schuetze2019-01-241-0/+0
|/
* update README with existing optionsRainer Schuetze2019-01-242-8/+20
|
* select Windows SDK automaticallyRainer Schuetze2019-01-063-0/+24
|
* fix issue #43: initialize DWARF_LineState's members file_ptr and last_addrRainer Schuetze2018-12-211-0/+3
|
* emit "elemtype[keytype]" instead of "dAssocArray"Rainer Schuetze2018-12-161-37/+43
| | | | always convert S_BPREL_V1 to S_BPREL_V3 (no longer supported by mspdb 14.16.27012/VS 15.9)
* fix #40: set architecture of .pdb for a 64 bit .dbgRainer Schuetze2018-12-122-7/+12
|
* fix #41: cv2pdb crashes if mspdb*.dll cannot be loaded from pathRainer Schuetze2018-12-121-1/+3
|
* add Setup.Configuration package contents and reference them directlyRainer Schuetze2018-09-295-7/+1029
|
* Merge pull request #38 from akihikodaki/masterRainer Schuetze2018-09-295-0/+55
|\ | | | | Improve Visual Studio detection
| * Add Visual Studio detection by the COM APIAkihiko Odaki2018-09-275-0/+55
|/ | | | | The new COM API is expected to work on Visual Studio 2017 and newer installations. It is also compatible with non-x86 runtime.
* DWARF: fix line info translation for pointer_size 8Rainer Schuetze2018-07-183-14/+20
| | | | do not assert for "Block" in DW_AT_upper_bound (but not supported)
* Merge pull request #34 from dakotahawkins/fix_dumpDebugLineInfoCOFFRainer Schuetze2018-07-181-17/+34
|\ | | | | Fix PEImage::dumpDebugLineInfoCOFF()
| * Fix PEImage::dumpDebugLineInfoCOFF()Dakota Hawkins2018-07-171-17/+34
|/ | | | | | Fixes #31 Signed-off-by: Dakota Hawkins <dakotahawkins@gmail.com>
* DWARF:Rainer Schuetze2018-04-213-35/+44
| | | | | | - fix code only executed in debug builds - fix evaluation of DW_OP_const1u/DW_OP_const1s not advancing pointer - add support for local variables with location list via DW_FORM_sec_offset
* Merge pull request #27 from AlexWhiter/masterRainer Schuetze2018-04-084-10/+13
|\ | | | | Access violation fixed. Better aligning of debug section.
| * Debug directory aligning moved to PEImage::replaceDebugSection.AlexWhiter2018-04-082-8/+7
| |