[llvm-dev] LLVM PDB Support

Reid Kleckner via llvm-dev llvm-dev at lists.llvm.org
Tue Oct 31 08:41:54 PDT 2017


The compiler is responsible for emitting codeview records into the .debug$S
(symbol) and .debug$T (type) object file sections. You can run
`llvm-readobj -codeview` or `llvm-pdbutil dump` on object files produced by
cl or clang-cl to get an idea of the kinds of records you need to output.
Take a look at cvinfo.h for reference on the on-disk format:
https://github.com/Microsoft/microsoft-pdb/blob/master/include/cvinfo.h

On Mon, Oct 30, 2017 at 8:46 PM, Meena Jain via llvm-dev <
llvm-dev at lists.llvm.org> wrote:

> Dear Matt,
>
> Thank you so much for providing me these details.
>
> These seems to be very helpful and enough to start with.
>
> Between, I have a query in general,
>
> I read somewhere that Microsoft linker generates the PDB file.
>
> We have a proprietary compiler which generates windows compatible object
> code. We are using Microsoft linker only to generate the executable. Though
> we are able to generate PDB file using the linker /debug option but since
> it does not contain source information, we are not able to do the source
> level debugging. However, we are able to do assembly level debugging.
>
> My doubt is, what role compiler plays which helps Microsoft linker to
> generate the PDB file with source level debugging information.
>
> Thanks and Regards
> Meena
>
>
> -----Original Message-----
> From: llvm-dev [mailto:llvm-dev-bounces at lists.llvm.org] On Behalf Of Matt
> P. Dziubinski via llvm-dev
> Sent: Tuesday, October 31, 2017 5:44 AM
> To: llvm-dev at lists.llvm.org
> Subject: Re: [llvm-dev] LLVM PDB Support
>
> Hi Meena,
>
> On 10/30/2017 08:03, Meena Jain via llvm-dev wrote:
>  > I am trying to understand the Microsoft PDB format and I heard that
> LLVM provides support to Microsoft PDB file format.
>  > It would be great if you can provide some pointers regarding the same
> to start with.
>
> I've made my resources on these topics publicly available -- perhaps they
> can be of some use or help:
>
> Executable and object file formats (ELF, Mach-O, PE: EXE & DLL); debugging
> data formats (DWARF, PDB): articles, documentation, software, and talks.
> https://github.com/MattPD/cpplinks/blob/master/executables.md
>
> In particular, here's the section on PDB:
> https://github.com/MattPD/cpplinks/blob/master/executables.md#pdb-program-
> database
>
> Best regards,
>
> Matt
>
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
>
>
> ::DISCLAIMER::
> ------------------------------------------------------------
> ------------------------------------------------------------
> ----------------------------
>
> The contents of this e-mail and any attachment(s) are confidential and
> intended for the named recipient(s) only.
> E-mail transmission is not guaranteed to be secure or error-free as
> information could be intercepted, corrupted,
> lost, destroyed, arrive late or incomplete, or may contain viruses in
> transmission. The e mail and its contents
> (with or without referred errors) shall therefore not attach any liability
> on the originator or HCL or its affiliates.
> Views or opinions, if any, presented in this email are solely those of the
> author and may not necessarily reflect the
> views or opinions of HCL or its affiliates. Any form of reproduction,
> dissemination, copying, disclosure, modification,
> distribution and / or publication of this message without the prior
> written consent of authorized representative of
> HCL is strictly prohibited. If you have received this email in error
> please delete it and notify the sender immediately.
> Before opening any email and/or attachments, please check them for viruses
> and other defects.
>
> ------------------------------------------------------------
> ------------------------------------------------------------
> ----------------------------
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20171031/a87d777c/attachment.html>


More information about the llvm-dev mailing list