Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-devel / 2009-11

oddity with dwarf debug / fpc

3 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Martin

I have compile all of lazarus with dwarf, and then compiled a project with dwarf, using Synedit (wich is also compiled with dwarf)

I can set a breakpoint in any unit in synEdit => works (The project is just a form with a synedit on it. The breakpoint is set in the constructor of some of the objects created in synedit. so the stack below is during startup.)

Except for the stackframes returned are somewhat odd. again all units have been compiled with dwarf => Yet even units within the same synedit package differ in their result

Why do some units not show the readable format, including line numbers? Besides the linenumbers must be stored somewhere, since I was able to set a breakpoint there (and execution stopped at the breakpoint....

stack=[
frame={level="0",addr="0x005684ca",func="SYNGUTTERBASE_TSYNGUTTERPARTLIST_$__CREATE$TCOMPONENT$TSYNGUTTERBASE$$TSYNGUTTERPARTLIST"}, frame={level="1",addr="0x00567709",func="SYNGUTTERBASE_TSYNGUTTERBASE_$__CREATE$TSYNEDITBASE$TSYNEDITFOLDEDVIEW$THETEXTDRAWER$$TSYNGUTTERBASE"}, frame={level="2",addr="0x0056642d",func="SYNGUTTER_TSYNGUTTER_$__CREATE$TSYNEDITBASE$TSYNEDITFOLDEDVIEW$THETEXTDRAWER$$TSYNGUTTER"}, frame={level="3",addr="0x005507e1",func="CREATE",file="synedit.pp",fullname="C:/lazarus_latest/components/synedit/synedit.pp",line="1568"}, frame={level="4",addr="0x00439461",func="READCOMPONENT",file="../objpas/classes/reader.inc",fullname="C:/FPC/SVN/trunc/rtl/win32/../objpas/classes/reader.inc",line="875"}, frame={level="5",addr="0x00439a15",func="READDATA",file="../objpas/classes/reader.inc",fullname="C:/FPC/SVN/trunc/rtl/win32/../objpas/classes/reader.inc",line="976"}, frame=
....

Reply by email

Martin
to Martin

Sorry my fault.

I forgot to compile the actual project with dwar...

But it raises another question. If the LCL + SynEdit + all of that is compiled with dwarf info, and the project is compiled with stabs => how come any debug info for Synedit is included.

and still why different levels?

Martin wrote 34 lines
I have compile all of lazarus with dwarf, and then compiled a project with dwarf, using Synedit (wich is also compiled with dwarf) I can set a breakpoint in any unit in synEdit => works (The project is just a form with a synedit on it. The breakpoint is set in the constructor of some of the objects created in synedit. so the stack below is during startup.) Except for the stackframes returned are somewhat odd. again all units have been compiled with dwarf => Yet even units within the same synedit package differ in their result Why do some units not show the readable format, including line numbers? Besides the linenumbers must be stored somewhere, since I was able to set a breakpoint there (and execution stopped at the breakpoint.... stack=[ frame={level="0",addr="0x005684ca",func="SYNGUTTERBASE_TSYNGUTTERPARTLIST_$__CREATE$TCOMPONENT$TSYNGUTTERBASE$$TSYNGUTTERPARTLIST"}, frame={level="1",addr="0x00567709",func="SYNGUTTERBASE_TSYNGUTTERBASE_$__CREATE$TSYNEDITBASE$TSYNEDITFOLDEDVIEW$THETEXTDRAWER$$TSYNGUTTERBASE"}, frame={level="2",addr="0x0056642d",func="SYNGUTTER_TSYNGUTTER_$__CREATE$TSYNEDITBASE$TSYNEDITFOLDEDVIEW$THETEXTDRAWER$$TSYNGUTTER"}, frame={level="3",addr="0x005507e1",func="CREATE",file="synedit.pp",fullname="C:/lazarus_latest/components/synedit/synedit.pp",line="1568"}, frame={level="4",addr="0x00439461",func="READCOMPONENT",file="../objpas/classes/reader.inc",fullname="C:/FPC/SVN/trunc/rtl/win32/../objpas/classes/reader.inc",line="875"}, frame={level="5",addr="0x00439a15",func="READDATA",file="../objpas/classes/reader.inc",fullname="C:/FPC/SVN/trunc/rtl/win32/../objpas/classes/reader.inc",line="976"}, frame= .... _______________________________________________ fpc-devel maillist - http://lists.freepascal.org/mailman/listinfo/fpc-devel

Reply by email

Jonas Maebe
to Martin

Martin wrote on Sat, 07 Nov 2009:

Show quoted text 5 lines
But it raises another question. If the LCL + SynEdit + all of that is compiled with dwarf info, and the project is compiled with stabs => how come any debug info for Synedit is included. and still why different levels?

Probably because either the linker or the debugger got confused. Mixing different debug formats in the same project is simply not supported and the resulting behaviour is undefined.

Maybe the compiler should store the kind of debug information that has been generated per unit, and give a warning when mixing different kinds of debug info.

Jonas

---------------------------------------------------------------- This message was sent using IMP, the Internet Messaging Program.

Reply by email