Jump to page: 1 2
Thread overview
The dmd backend should generate .pdb files for visual studio.
Feb 20, 2021
12345swordy
Feb 20, 2021
bachmeier
Feb 20, 2021
12345swordy
Feb 20, 2021
kinke
Feb 20, 2021
kinke
Feb 20, 2021
12345swordy
Feb 20, 2021
kinke
Feb 20, 2021
12345swordy
Feb 20, 2021
kinke
Feb 21, 2021
12345swordy
Feb 21, 2021
kinke
Feb 21, 2021
12345swordy
Feb 21, 2021
kinke
Feb 21, 2021
kinke
Feb 21, 2021
12345swordy
Feb 21, 2021
Rumbu
February 20, 2021
I think it time for dmd to do so, as the backend is currently opensource. The fine folks at llvm created documentation for the PDB file.
https://llvm.org/docs/PDB/index.html
By doing so, the visual studio debugging experience would be much smoother as the debugging information is now generated for types correctly, without having to rely on converting the dwarf information into a .pdb file.

Anyone else interested in generating .pdb files?

-Alex
February 20, 2021
On Saturday, 20 February 2021 at 16:12:52 UTC, 12345swordy wrote:
> I think it time for dmd to do so, as the backend is currently opensource. The fine folks at llvm created documentation for the PDB file.
> https://llvm.org/docs/PDB/index.html
> By doing so, the visual studio debugging experience would be much smoother as the debugging information is now generated for types correctly, without having to rely on converting the dwarf information into a .pdb file.
>
> Anyone else interested in generating .pdb files?
>
> -Alex

Doesn't it already do that? https://dlang.org/windbg.html

(Maybe I'm not understanding.)
February 20, 2021
On Saturday, 20 February 2021 at 16:48:43 UTC, bachmeier wrote:
>
> Doesn't it already do that? https://dlang.org/windbg.html
>
> (Maybe I'm not understanding.)

Read this line here:
"The debug information format used is an ancient version of CodeView that is only partially supported by more recent debuggers."


-Alex
February 20, 2021
On Saturday, 20 February 2021 at 16:55:30 UTC, 12345swordy wrote:
> On Saturday, 20 February 2021 at 16:48:43 UTC, bachmeier wrote:
>>
>> Doesn't it already do that? https://dlang.org/windbg.html
>>
>> (Maybe I'm not understanding.)
>
> Read this line here:
> "The debug information format used is an ancient version of CodeView that is only partially supported by more recent debuggers."

`dmd -m64 -g foo.d` generates `foo.{exe,pdb}` and can be debugged with VS / Visual D just fine, no Dwarf involved.

February 20, 2021
And with -m32mscoff too for 32-bit. The quoted sentence only applies to the 32-bit OMF backend.
February 20, 2021
On Saturday, 20 February 2021 at 17:07:07 UTC, kinke wrote:
> On Saturday, 20 February 2021 at 16:55:30 UTC, 12345swordy wrote:
>> On Saturday, 20 February 2021 at 16:48:43 UTC, bachmeier wrote:
>>>
>>> Doesn't it already do that? https://dlang.org/windbg.html
>>>
>>> (Maybe I'm not understanding.)
>>
>> Read this line here:
>> "The debug information format used is an ancient version of CodeView that is only partially supported by more recent debuggers."
>
> `dmd -m64 -g foo.d` generates `foo.{exe,pdb}` and can be debugged with VS / Visual D just fine, no Dwarf involved.

What part of "Ancient version of CodeView that is only partially supported" that you do not understand here? It doesn't generate enum type information or any type information at all for the debugger.

Try reading the enum values in your debugging windows in visual d. It makes you want to rip your hair out.

-Alex

February 20, 2021
On Saturday, 20 February 2021 at 19:18:37 UTC, 12345swordy wrote:
> Try reading the enum values in your debugging windows in visual d. It makes you want to rip your hair out.

I don't know what you mean; the fully qualified value name works good enough for me. Can you be more specific or link to some DMD issue?
February 20, 2021
On Saturday, 20 February 2021 at 23:17:15 UTC, kinke wrote:
> On Saturday, 20 February 2021 at 19:18:37 UTC, 12345swordy wrote:
>> Try reading the enum values in your debugging windows in visual d. It makes you want to rip your hair out.
>
> I don't know what you mean; the fully qualified value name works good enough for me. Can you be more specific or link to some DMD issue?

https://ibb.co/0q6NkZk
Look at the bottom left window.
It display enum values as integers!

-Alex
February 20, 2021
On Saturday, 20 February 2021 at 23:33:05 UTC, 12345swordy wrote:
> https://ibb.co/0q6NkZk
> Look at the bottom left window.
> It display enum values as integers!
>
> -Alex

Not for trivial cases: https://ibb.co/YBK4H7q

So this seems to be a bug, most likely not the last, but doesn't entail reinventing the wheel; .pdb output is already there.
February 21, 2021
On Saturday, 20 February 2021 at 23:56:14 UTC, kinke wrote:
> On Saturday, 20 February 2021 at 23:33:05 UTC, 12345swordy wrote:
>> https://ibb.co/0q6NkZk
>> Look at the bottom left window.
>> It display enum values as integers!
>>
>> -Alex
>
> Not for trivial cases: https://ibb.co/YBK4H7q


Have you ever tried to diagnose the pdb file? I did. It doesn't contain any information regarding any types. That's the issue here.

>
> So this seems to be a bug, most likely not the last, but doesn't entail reinventing the wheel; .pdb output is already there.

It does entail reinventing the wheel if you relying on an ancient version of CodeView!

-Alex
« First   ‹ Prev
1 2