This is the mail archive of the gdb-prs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: pascal/2471: Wrong evaluation of functions with pascal calling convention


The following reply was made to PR pascal/2471; it has been noted by GNATS.

From: "Pierre Muller" <muller@ics.u-strasbg.fr>
To: <gdb-gnats@sources.redhat.com>, <muller@ics.u-strasbg.fr>,
        <gdb-prs@sources.redhat.com>, <_tom_@centrum.cz>
Cc: <core@freepascal.org>
Subject: Re: pascal/2471: Wrong evaluation of functions with pascal calling convention
Date: Tue, 1 Jul 2008 09:33:46 +0200

 http://sourceware.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gd
 b&pr=2471
 
 
 I suspect that this is not a GDB problem but rather a
 debugging information generation problem.
 First, you did not tell us which complier you used to test.
 
 Is it were GNU pascal compiler (GPC) or Free Pascal compiler (FPC)
 or some other compiler?
 
 This is important because these two compiler do not use the same
 calling convention by default, and there is
 no setting of the calling convention in the testsuite.
 
  Second, if you are using Free Pascal, the default calling convention will
 also depend on the version.
   Version 1.X use 'free pascal' convention, which isn't 
 the official pascal convention either, whereas version 2.X
 use register convention for i386 cpus.
   I suspect that you are using FPC version 2.X,
 I tried to use it with both dwarf or stabs debugging information,
 with fpc 2.2.0,
 and in both cases, there are problems:
 
 1) with stabs, no stabs information about the register parameters is
 generated, which of course means that GDB will not know where to put 
 the function parameters.
   I think that this is an old known problem...
 
 2) with dwarf, I get an error:
 invalid dwarf2 offset 4239667
 
   I was part of the Free Pascal core team,
 but, due to lack of time, I stopped contributing
 a while ago and don't know the current internals 
 of the compiler.
 
   Are there any tests for the validity of
 the generated debugging information?
 
 
 Pierre Muller
 Pascal language support maintainer for GDB
 
 
 
 
 
 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]