[Lldb-commits] [PATCH] D54452: [NativePDB] Add support for handling S_CONSTANT records

Zachary Turner via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Mon Nov 12 15:31:46 PST 2018

zturner created this revision.
zturner added reviewers: aleksandr.urakov, lemo.

clang-cl does not emit these, but MSVC does, so we need to be able to handle them.

Because clang-cl does not generate them, it was a bit hard to write a test.  So what I had to do was get an PDB file with some `S_CONSTANT` records in using cl and link, dump it using `llvm-pdbutil dump -globals -sym-data` to get the bytes of the records, generate the same object file using `clang-cl` but with `-S` to emit an assembly file, and replace all the `S_LDATA32` records with the bytes of the `S_CONSTANT` records.  This way, we can compile the file using `llvm-mc` and link it with `lld-link`.



-------------- next part --------------
A non-text attachment was scrubbed...
Name: D54452.173775.patch
Type: text/x-patch
Size: 43705 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20181112/630d3821/attachment-0001.bin>

More information about the lldb-commits mailing list