gcl-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gcl-devel] HEAD Maxima and HEAD trad GCL


From: Camm Maguire
Subject: Re: [Gcl-devel] HEAD Maxima and HEAD trad GCL
Date: 08 Jan 2004 14:06:40 -0500
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2

Hi Mike!  And thanks, we're getting close!

"Mike Thomas" <address@hidden> writes:

> Hi Camm.
> 
> ============================================================================
> Loading binary of PCL_BRAID...
> Breakpoint 1, call_or_link (sym=0x1022c3a8, link=0x1031d57c) at funlink.c:71
> 71                  ( *(void (*)()) (fun->cf.cf_self)) ();
> (gdb) p fun->cf.cf_name->st
> $10 = {t = 8 '\b', flag = 0 '\0', s = 0 '\0', m = 0 '\0', st_displaced =
> 0x0,
>   st_hasfillp = 4784, st_adjustable = 84,
>   st_self = 0x103ce800 "GET-DFUN-CONSTRUCTORWRAPPER1WRAPPER0ACCESSOR-TYPE",
>   st_fillp = 20, st_dim = 270352720}
> ============================================================================
> 
> 
> 
> 
> The above was included in the last email - also in the last email is some
> output from looking at the args at that breakpoint
> 
> |
> | p/x *(int *)fun->address@hidden
> 
> ============================================================================
> (gdb) p/x *(int *)fun->address@hidden
> $11 = {0x53565755, 0x8b1cec83, 0x5b0ba035, 0x100d8b00, 0x10298bf4,
> 0xd3b1846,
>   0x5a7dd0, 0x18247489, 0x14244489, 0x46b830f, 0xc8890000, 0xf8c1f029,
>   0xfc08502, 0x4468e, 0x4c68300, 0x1824548b, 0x2a8bf139, 0xba03589,
> 0x1c7005b,
>   0x5412b0, 0x870fcb89, 0x404, 0x1424448b, 0x5a7810a3, 0xcda8a100,
> 0x4c8b1031,
>   0x78811824, 0x5412b004, 0x4798b00, 0x1d8b3074, 0x1031cdac, 0x12b0fb81,
>   0x22740054, 0xff08ec83, 0xe8550873, 0xf014c360, 0x8510c483, 0x3e850fc0,
>   0x8b000003, 0xfb81045b, 0x5412b0, 0xa0a1de75, 0x8b1031cd, 0xb03d0440,
>   0x74005412, 0x768d19, 0x3b08508b, 0x840f086a, 0x300, 0x3d04408b, 0x5412b0,
>   0x44c7ea75, 0x12b01024, 0x448b0054, 0x588b1024, 0xb0fb8104, 0x74005412,
>   0x768d30, 0x8b08ec83, 0x70ff0843, 0x81e85708, 0x83f014c5, 0xc08510c4,
>   0x438b0c74, 0x12b03d08, 0xc2890054, 0x5b8b1075, 0xb0fb8104, 0x75005412,
>   0x12b0bad3, 0x94a10054, 0x811031cd, 0x12b00478, 0x840f0054, 0x1f8,
>   0x8b04428b, 0xb03d0840, 0x74005412, 0x24548b25, 0x89d68918, 0x10c683d1,
>   0x8914c183, 0x35891042, 0x5b0ba0, 0x78100d89, 0xc483005a, 0x5f5e5b1c,
>   0x4c8bc35d, 0xcb891824, 0x8b14c383, 0x89142444, 0x10a31469, 0x89005a78,
>   0x5b0ba01d, 0xcf79e800, 0xa0a1f015, 0x8b005b0b, 0x8b182454, 0xb0ff8100,
>   0x89005412, 0xd9891042, 0x1d89fa89, 0x5a7810, 0x428b1974, 0x8b018908,
>   0xc1830452, 0xb0fa8104, 0x75005412, 0x100d89ed, 0x8b005a78, 0x8b18244c,
>   0x108a1041, 0x8915fa80, 0x5b0ba01d, 0x3b840f00, 0x80000001, 0x840f14fa,
>   0x12a, 0x500cec83, 0x1127b9e8, 0x10c483f0, 0x5b0ba0a1, 0x10158b00,
>   0x39005a78, 0xf4830fd0, 0x8d000000, 0x88b0470, 0x4c89d639, 0x35890c24,
>   0x5b0ba0, 0xcb820f, 0x448b0000, 0x10a31424, 0xbe005a78, 0x5412b0,
>   0x1824448b, 0x89107889, 0x10c783c7, 0xba03d89, 0x1d89005b, 0x5a7810,
> ---Type <return> to continue, or q <return> to quit---
>   0x13666de8, 0x24548bf0, 0x10158914, 0xba005a78, 0x5412b0, 0x5b0ba0a1,
>   0x8bd63900, 0x837b7400, 0x52560cec, 0x202474ff, 0xe8046a50, 0xf0133b45,
>   0x8120c483, 0xb010247c, 0x74005412, 0x8ec833d, 0x18244c8b, 0x500471ff,
>   0xf84afe8, 0x24548bf0, 0x4428920, 0x8b10c483, 0x8b18244c, 0x8b0c2444,
>   0x89142454, 0x71891041, 0xa03d8914, 0x89005b0b, 0x5a781015, 0xfea8e900,
>   0x5053ffff, 0xe8026a55, 0xf0133af1, 0xa01d8b5a, 0x591031cd, 0x500473ff,
>   0xf8467e8, 0x44389f0, 0x158bbaeb, 0x1031cdb4, 0xffff7ae9, 0x24548bff,
>   0x4708b14, 0x78101589, 0x31e9005a, 0x8bffffff, 0x8914244c, 0x5a78100d,
>   0x2444c700, 0x5412b00c, 0xff15e900, 0x50ffffff, 0xfedae908, 0x488bffff,
>   0xfc98518, 0xfffeba84, 0xcec83ff, 0x850ff51, 0xfffec0e9...}
> ============================================================================
> 
> 
> 
> | Then if you could please find the function name so reported (as a
> | comment) in one of the pcl C files, and give me objdump -d on that
> | file's .o file.
> 
> The object dump of pcl_dfun.o is attached.
> 
> The function name GET-DFUN-CONSTRUCTORWRAPPER1WRAPPER0ACCESSOR-TYPE seems to
> be a bogus overwriting of several names in pcl_dfun - something is going
> badly wrong with string handling?

GCL strings are not null terminated.  The length is rather given by
the fillp argument.  This is OK.

> 
> Keep in mind when reflecting on this that on Windows, uninitialised
> variables do not get automatically set to 0, they are set to whatever is
> sitting in memory when they are instantiated.
> 

Nor in Linux.

> 
> 
> 
> ============================================================================
> address@hidden /c/cvs/head/gcl/pcl
> $ fgrep -r -i GET-DFUN-CONSTRUCTORWRAPPER1WRAPPER0ACCESSOR-TYPE *.c
> 
> address@hidden /c/cvs/head/gcl/pcl
> $ fgrep -r -i GET-DFUN-CONSTRUCTOR *.c
> pcl_dfun.c:/*   function definition for GET-DFUN-CONSTRUCTOR    */
> pcl_dfun.c:static void LnkT189(){ call_or_link(VV[189],(void **)(void
> *)&Lnk189)
> ;} /* GET-DFUN-CONSTRUCTOR */
> 

OK, I need just a few more lines of context here.  On my system,
GET-DFUN-Constructor is compiled as L2 (pcl_dfun.c):

/*      function definition for GET-DFUN-CONSTRUCTOR    */

static void L2()
{register object *base=vs_base;


> ============================================================================
> 
> 
> 
> | Lastly, if you could please break at fasload,
> | conditionalize this to when the pcl file you found is being loaded,
> | then break at call_init, and report back to me the init_address.
> 
> init_address is 0 see below:
> 
> ============================================================================
> Loading binary of PCL_DFUN...
> 
> Breakpoint 1, fasload (faslfile=0x1024cfc0) at sfasl.c:178
> 178         int init_address=0;
> (gdb) p faslfile->s
> $11 = {t = 13 '\r', flag = 0 '\0', s = 0 '\0', m = 0 '\0', s_dbind =
> 0x5412b0,
>   s_sfdef = 0,
>   st_self = 0x103b5a2c "c:/cvs/head/gcl/unixport/../pcl/pcl_dfun.o",
>   st_fillp = 42, s_gfdef = 0x2a, s_plist = 0xd, s_hpack = 0x5412b0,
>   s_stype = 0, s_mflag = 0}
> (gdb) break call_init
> Breakpoint 2 at 0x418fa3: file cmpaux.c, line 315.
> (gdb) c
> Continuing.
> 
> Breakpoint 2, call_init (init_address=0, memory=0x102d6294,
>     fasl_vec=0x10112ab8, fptr=0) at cmpaux.c:315
> 315       check_type(fasl_vec,t_vector);
> (gdb)


OK I also need at this point:

p memory->cfd


The idea is that the bytes you printed above with 'p/x *(int
*)fun->address@hidden' (would be better next time as (char *),
btw). should match up to relocation the codes found in your objdump,
and the sum of memory->cfd.cfd_start + the offset in your dump file
should be fun->cf.cf_self.  This does not look like it is matching up,
but I need the info above to be sure.

Take care,

> ============================================================================
> 
> | Hopefully we should be able to see things more clearly from here.
> 
> Thanks Camm,
> 
> Mike Thomas.
> 
> _______________________________________________
> Gcl-devel mailing list
> address@hidden
> http://mail.gnu.org/mailman/listinfo/gcl-devel

-- 
Camm Maguire                                            address@hidden
==========================================================================
"The earth is but one country, and mankind its citizens."  --  Baha'u'llah




reply via email to

[Prev in Thread] Current Thread [Next in Thread]