[fpc-devel] gdb crashes with trunk

Jonas Maebe jonas.maebe at elis.ugent.be
Fri Apr 4 18:50:57 CEST 2008


On 04 Apr 2008, at 07:55, Martin Schreiber wrote:

> On Thursday 03 April 2008 21.33:17 Jonas Maebe wrote:
>> On 03 Apr 2008, at 19:12, Martin Schreiber wrote:
>>> The compiler crashes with -godwarfsets.
>>
>> Fixed.
>>
> It doesn't crash anymore, thanks.
> The display of sets seems to be wrong:
> "
> mse at linux-mse:~/packs/standard/svn/mse/trunk/apps/ide> gdb ./mseidefp
> GNU gdb 6.6.50.20070726-cvs
> Copyright (C) 2007 Free Software Foundation, Inc.
> GDB is free software, covered by the GNU General Public License, and  
> you are
> welcome to change it and/or distribute copies of it under certain  
> conditions.
> Type "show copying" to see the conditions.
> There is absolutely no warranty for GDB.  Type "show warranty" for  
> details.
> This GDB was configured as "i586-suse-linux"...
> Using host libthread_db library "/lib/libthread_db.so.1".
> (gdb) break reader.inc:1260
> Breakpoint 1 at 0x80d6c1e: file ../objpas/classes/reader.inc, line  
> 1260.
> (gdb) run
> Starting program: /home/mse/packs/standard/svn/mse/trunk/apps/ide/ 
> mseidefp
> [Thread debugging using libthread_db enabled]
> [New Thread 0xb7c188d0 (LWP 4821)]
> [Switching to Thread 0xb7c188d0 (LWP 4821)]
>
> Breakpoint 1, READROOTCOMPONENT (READROOTCOMPONENT=0xb786a020,
> AROOT=0xb786a020, this=0xb785a020) at ../objpas/classes/reader.inc: 
> 1260
> 1260              Result.FComponentState :=
> (gdb) print result.fcomponentstate
> $1 = []
> (gdb) next
> 1264              i := 0;
> (gdb) print result.fcomponentstate
> $2 = []

It does work for me:

(gdb) p Result.FComponentState
No symbol "Result" in current context.
(gdb) p result.FComponentState
$1 = []
(gdb) l
1255	      begin
1256	        Result := ARoot;
1257	
1258	        if not (csDesigning in Result.ComponentState) then
1259	        begin
1260	          Result.FComponentState :=
1261	            Result.FComponentState + [csLoading, csReading];
1262	
1263	          { We need an unique name }
1264	          i := 0;
(gdb) n
1264	          i := 0;
(gdb) p result.FComponentState
$2 = [CSLOADING..CSREADING]

$ gdb --version
GNU gdb Red Hat Linux (6.6-45.fc8rh)
Copyright (C) 2006 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and  
you are
welcome to change it and/or distribute copies of it under certain  
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for  
details.
This GDB was configured as "i386-redhat-linux-gnu".

Seems like you may have to update your gdb (fwiw, the 6.5-15.fc6rh I  
have access to crashes even with Dwarf).


Jonas



More information about the fpc-devel mailing list