Subject: Re: Is conversion of debug format of g++ to a native Windows format possible?
From: "Jay Krell" <[email-masked]>
To: <[email-masked]>
Cc: <[email-masked]>
Date: Tue, 14 Mar 2000 03:35:05 -0800

Microsoft's compiler/linker can produce Coff symbols and/or CodeView
symbols. Either type can be in the "image" (.exe/.dll), a "seperate" .dbg
file, and CodeView, not sure about Coff, can be in a .pdb, "program
database". Eexe/.dll/.dbg can contain both Coff and CodeView. The format of
.exe/.dll and .dbg is documented. The format of .pdb is not documented. The
"format" of CodeView symbols is documented, though of course, it is not
simple.

The Visual C++ debugger will only consume CodeView symbols, from any of the
three places. (eh..there might be some support for Coff esp. VC6, but
CodeView seems vastly preferred by it).
WinDbg and the other "NT" debuggers (kd, cdb, ntsd) used to only consume
Coff but I believe "now" consume both CodeView and Coff.

I really like the Visual C++ debugger and have never gotten comfortable with
any command line debugger or any Gdb gui wrapper, but the Gcc front end
seems to be approaching conformance much more rapidly than Visual C++'s
front end. I would like to use the Visual C++ debugger with the Gcc front
end. I've looked into writing a utility that will read in the .stabs and
write out CodeView to a .dbg. It should be doable, but it isn't easy.
(getting the support into Gcc itself I figure is probably harder and has
licensing requirements.. I haven't gotten Gcc out of Cvs to even build on
Win32 yet, error about INT_ASM_OP not being defined, perhaps I first need to
apply cygwin patches..)

 - Jay

-----Original Message-----
From: Mikey <[email-masked]>
To: [email-masked] <[email-masked]>
Cc: [email-masked] <[email-masked]>
Date: Thursday, March 09, 2000 6:14 PM
Subject: Re: Is conversion of debug format of g++ to a native Windows format
possible?

>The "New" windows debug format is coff,
>which gdb understands just fine.
>
>VTune may only recognize CodeView, I don't know
>but compiling/linking with /Z7 and /ZI  will allow
>you to use gdb with any MS .obj.
>
>You can force the Microsoft Compiler/Linker to store the debug
>information in the *.exe files
>
>Look at the following help file from Developer Studio
>--------------------------------------------------------------------
>Note      To create a library that contains debugging information
>without using .PDB files, you must select the compilers C7 Compatible
>(/Z7) option and clear the linkers Use Program Database (/PDB:NONE)
>option. If you use the precompiled headers options, debugging
>information for both the precompiled header and the rest of the source
>code is placed in the PDB. The /Yd option is ignored when the Program
>Database option is specified.
>------------------------------------------------------------------------
>
>On Thu, 9 Mar 2000 11:16:39 -0500, you wrote:
>
>>On Thu, Mar 09, 2000 at 04:53:23PM +0100, Max Griessl wrote:
>>>Is it possible to convert the debug format produced by g++ (i.e.  for
>>>C++ files) to a native Windows format which is correctly handled by
>>>e.g.  VTune of Intel?
>>
>>I wish.  I would love to be able to convert back and forth between the
>>two formats or, better, have bfd/gdb understand Microsoft format.
>>
>>I'm not aware of any such functionality but I'm sure that Mumit Khan can
>>give a definitive answer.
>>
>>cgf

--
Want to unsubscribe from this list?
Send a message to [email-masked]