[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Gcl-devel] memory damaged at (system:STRING-MATCH :anykey :verbose)
From: |
Camm Maguire |
Subject: |
Re: [Gcl-devel] memory damaged at (system:STRING-MATCH :anykey :verbose) |
Date: |
06 Jul 2004 11:09:55 -0400 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 |
Greetings!
I think I've just stumbled on a very useful tool for uses like this
from reading the lush source.
...
> Program received signal SIGSEGV, Segmentation fault.
> 0x1a6f7c5a in ?? ()
> (gdb) bt
> #0 0x1a6f7c5a in ?? ()
> #1 0x006d6ab0 in sKoverwrite ()
> #2 0x006d6ab0 in sKoverwrite ()
> #3 0x006d6ab0 in sKoverwrite ()
> #4 0x006d6ab0 in sKoverwrite ()
> #5 0x00000005 in ?? ()
> #6 0x77c3da2a in msvcrt!getc () from C:\WINDOWS\system32\msvcrt.dll
> #7 0x007465e4 in value_stack ()
> #8 0x007465d8 in value_stack ()
> #9 0x007e7244 in current_fasd ()
> #10 0x1a4c36c8 in ?? ()
> #11 0x006d6ab0 in sKoverwrite ()
> #12 0x006d6ab0 in sKoverwrite ()
> #13 0x0073b048 in small_fixnum_table ()
> #14 0x0073b068 in small_fixnum_table ()
> #15 0x0022e4a8 in ?? ()
> #16 0x0041d18e in funcall (fun=0x7465cc) at eval.c:213
> Previous frame identical to this frame (corrupt stack?)
> (gdb)
>
I'm assuming you can reproduce this crash with --enable-debug. With
such a GCL, do (setq compiler::*default-c-file* t) before compiling
maxima, then build as usual up to this point.
Rerun gdb, and break at fasload, conditionalized on the load of the
file in question (specfn.o). finish the load, and then in gdb, type
add-symbol-file src/specfn.o 0x.....
where the address is that reported by the fasload just completed.
Then you should be able to break and step through the specfn.c source
like any other gcl C source file. In particular, you will see a real
backtrace of this level.
In your particular case, you might not be able to finish the whole
load without triggering the error. Then just break at the
read_fasl_vector or some such call toward the end of fasload. By this
time, you will have loaded the code and know what the address is, and
so can issue the add-symbol-file command before continuing through the
fasl vector read.
It would be great to see if this helps.
Take care,
> (gdb) whatis 0x1a6f7c5a
> type = int
> (gdb) whatis 0x1a4c36c8
> type = int
> (gdb) whatis 0x7465cc
> type = int
> (gdb) up 16
> #16 0x0041d18e in funcall (fun=0x7465cc) at eval.c:213
> 213 MMccall(fun, top);
> (gdb) :help
> Undefined command: "". Try "help".
> (gdb) info frame
> Stack level 16, frame at 0x22e460:
> eip = 0x41d18e in funcall (eval.c:213); saved eip 0x41d18e
> caller of frame at 0x22e460
> source language c.
> Arglist at 0x22e458, args: fun=0x7465cc
> Locals at 0x22e458, Previous frame's sp is 0x22e460
> Saved registers:
> ebp at 0x22e458, eip at 0x22e45c
> (gdb) frame
> #16 0x0041d18e in funcall (fun=0x7465cc) at eval.c:213
> 213 MMccall(fun, top);
>
> (gdb) info locals
> temporary = 0x73b068
> x = 0x73b048
> top = (object * volatile) 0x6d6ab0
> lex = (object *) 0x6d6ab0
> old_bds_top = 0x1a4c36c8
> b = 8286788
> c = 7628248
> res = 0x7465e4
> b = (object *) 0x77c3da2a
> n = 5
> top = (object *) 0x5
> base = (object *) 0x77c3da2a
> l = 0x7465e4
> x = 0x6d6ab0
> not_pushed = 7170736
> (gdb) info threads
> * 1 thread 1356.0x50c 0x0041d18e in funcall (fun=0x7465cc) at eval.c:213
> warning: Couldn't restore frame in current thread, at frame 0
> 0x0041d18e in funcall (fun=0x7465cc) at eval.c:213
> (gdb)
>
>
--
Camm Maguire address@hidden
==========================================================================
"The earth is but one country, and mankind its citizens." -- Baha'u'llah
- RE: [Gcl-devel] memory damaged at (system:STRING-MATCH :anykey :verbose), Mike Thomas, 2004/07/05
- Re: [Gcl-devel] memory damaged in Maxima, Michael Koehne, 2004/07/05
- Re: [Gcl-devel] memory damaged at (system:STRING-MATCH :anykey :verbose),
Camm Maguire <=
- RE: [Gcl-devel] memory damaged at (system:STRING-MATCH :anykey:verbose), Mike Thomas, 2004/07/07
- Re: [Gcl-devel] memory damaged at (system:STRING-MATCH :anykey:verbose), Camm Maguire, 2004/07/07
- RE: [Gcl-devel] memory damaged at (system:STRING-MATCH:anykey:verbose), Mike Thomas, 2004/07/07
- Re: [Gcl-devel] memory damaged at (system:STRING-MATCH:anykey:verbose), Camm Maguire, 2004/07/07
- RE: [Gcl-devel] memory damaged at (system:STRING-MATCH:anykey:verbose), Mike Thomas, 2004/07/07
- RE: [Gcl-devel] memory damaged at (system:STRING-MATCH:anykey:verbose) - PS, Mike Thomas, 2004/07/08
- Re: [Gcl-devel] memory damaged at (system:STRING-MATCH:anykey:verbose) - PS, Camm Maguire, 2004/07/08
- RE: [Gcl-devel] memory damaged at(system:STRING-MATCH:anykey:verbose) - PS, Mike Thomas, 2004/07/09
- Re: [Gcl-devel] memory damaged at(system:STRING-MATCH:anykey:verbose) - PS, Camm Maguire, 2004/07/12
- RE: [Gcl-devel] memory damaged at(system:STRING-MATCH:anykey:verbose) - PS, Mike Thomas, 2004/07/12