all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: storm@cua.dk (Kim F. Storm)
Cc: Stefan Monnier <monnier@iro.umontreal.ca>, emacs-devel@gnu.org
Subject: Re: GC crashes
Date: Tue, 07 Dec 2004 10:37:35 +0100	[thread overview]
Message-ID: <m3llcaqwio.fsf@kfs-l.imdomain.dk> (raw)
In-Reply-To: <87k6rvvybw.fsf_-_@jurta.org> (Juri Linkov's message of "Tue, 07 Dec 2004 00:47:15 +0200")

Juri Linkov <juri@jurta.org> writes:

> Stefan Monnier <monnier@iro.umontreal.ca> writes:
>> It's more important that we release it soon than it is to include
>> each and every new feature.
>
> It seems in its current state Emacs is too far from being ready for
> the release.  In the last three months Emacs became too unstable:
> I have experienced frequent crashes in GC (I had no crashes before
> September 2004).  I haven't debugged them because debugging GC looks
> to me like brain surgery.  However, unless this is a known problem,
> I might try to debug it.

Please do -- I know there is a memory corruption issue somewhere but
so far nobody's been able to identify under what circumstances they
happen.

>
> PS: The latest crash I got was just when composing the previous reply.
> I attached the debug session below if it might help somehow.
> The cause of the crash is the fact that symbol's `xname' contains
> a vector.  I've looked at the contents of this vector, and it has the
> values of variables `load-path' `user-init-file', `byte-boolean-vars',
> etc.  

Sounds like it points to the obarray or some such.  But probably the
pointer to the symbol is bogus, so someone wrote over that pointer,
so maybe you could look at where that pointer came from and see what
data is around there (to see if any other data there gives a clue
to what part of the code wrote over it).

>       The symbol's `value', `function' and `plist' have some absurd
> values.  This looks like a memory corruption.  Could compiling with
> ENABLE_CHECKING or other compiler options help detect where memory
> corruption occurs?

You can try changing the #if 0 at line 32 in lisp.h to #if 1, remove
all *.o files, rebuild emacs, and see if it catches the bug before it
happens (it will still abort emacs, but you can look at the data to
see what may be causing the memory overwrite).


>
> (gdb) bt
> #0  mark_object (arg=137262137) at alloc.c:5193
> #1  0x0812490e in mark_object (arg=165544885) at alloc.c:5301
> #2  0x0812136c in mark_interval (i=0x9e15a64, dummy=137262265) at alloc.c:1356
> #3  0x0816bc39 in traverse_intervals_noorder (tree=0x9e15a10, function=0x8121354 <mark_interval>, arg=137262265) at intervals.c:207
> #4  0x0816bc54 in traverse_intervals_noorder (tree=0x9e15394, function=0x8121354 <mark_interval>, arg=137262265) at intervals.c:212
> #5  0x0816bc54 in traverse_intervals_noorder (tree=0x9e14abc, function=0x8121354 <mark_interval>, arg=137262265) at intervals.c:212
> #6  0x0816bc54 in traverse_intervals_noorder (tree=0x9e16788, function=0x8121354 <mark_interval>, arg=137262265) at intervals.c:212
> #7  0x0816bc54 in traverse_intervals_noorder (tree=0x9e12198, function=0x8121354 <mark_interval>, arg=137262265) at intervals.c:212
> #8  0x0816bc54 in traverse_intervals_noorder (tree=0x9e131e8, function=0x8121354 <mark_interval>, arg=137262265) at intervals.c:212
> #9  0x0812138c in mark_interval_tree (tree=0x9e131e8) at alloc.c:1371
> #10 0x081249a4 in mark_buffer (buf=156504092) at alloc.c:5338
> #11 0x0812401a in mark_object (arg=156504092) at alloc.c:5028
> [...1500 more frames...]
> (gdb) xba
> "font-lock-fontify-keywords-region"
> "font-lock-default-fontify-region"
> "font-lock-fontify-region"
> "run-hook-with-args"
> "byte-code"
> "jit-lock-fontify-now"
> "byte-code"
> "jit-lock-stealth-fontify"
> "apply"
> "byte-code"
> "timer-event-handler"
> (gdb) fr 0
> #0  mark_object (arg=137262137) at alloc.c:5193
> 5193              MARK_STRING (XSTRING (ptr->xname));
> (gdb) p ptr
> $3 = (struct Lisp_Symbol *) 0x82a0ba0
> (gdb) p *$
> $4 = {
>   gcmarkbit = 0, 
>   indirect_variable = 0, 
>   constant = 1, 
>   interned = 0, 
>   xname = 137228604, 
>   value = 137199748, 
>   function = 137199744, 
>   plist = 137199772, 
>   next = 0x82d7008
> }
> (gdb) p ptr->xname
> $5 = 137228604
> (gdb) xtype
> Lisp_Vectorlike
> 167653757
> (gdb) xvector
> $6 = (struct Lisp_Vector *) 0x82df138
> 0
> (gdb) p *$
> $7 = {
>   size = 167653757, 
>   next = 0x82e7501, 
>   contents = {143577373}
> }
> ...
-- 
Kim F. Storm <storm@cua.dk> http://www.cua.dk

  reply	other threads:[~2004-12-07  9:37 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-06 14:32 Items in FOR-RELEASE Stefan
2004-12-06 19:52 ` Juri Linkov
2004-12-06 20:12   ` Stefan Monnier
2004-12-06 21:12     ` Juri Linkov
2004-12-06 21:45       ` Stefan Monnier
2004-12-06 22:33         ` Juri Linkov
2004-12-06 22:47         ` GC crashes (Was: Items in FOR-RELEASE) Juri Linkov
2004-12-07  9:37           ` Kim F. Storm [this message]
2004-12-07 15:54             ` GC crashes Paul Pogonyshev
2004-12-07 20:46               ` Jan D.
2004-12-07 20:53               ` Nick Roberts
2004-12-08  0:17                 ` Paul Pogonyshev
2004-12-08  6:04                   ` Jan D.
2004-12-08  7:31                     ` Nick Roberts
2004-12-08 17:39                       ` Eli Zaretskii
2004-12-08 19:27                         ` Nick Roberts
2004-12-08 22:15                 ` Richard Stallman
2004-12-08  1:34         ` Items in FOR-RELEASE Miles Bader
2004-12-08  3:14           ` Stefan Monnier
2004-12-08 22:15             ` Richard Stallman
2004-12-08  8:37           ` Kim F. Storm
2004-12-08  4:39       ` Richard Stallman
  -- strict thread matches above, loose matches on Subject: below --
2005-12-14 21:49 GC crashes Chong Yidong
2005-12-14 23:18 ` David Kastrup
2005-12-14 23:24   ` Chong Yidong
2005-12-14 23:28     ` David Kastrup
2005-12-17 19:52   ` Chong Yidong
2005-12-18 17:15 ` Richard M. Stallman
2003-11-24 10:09 Werner LEMBERG
2003-11-26  2:03 ` Kenichi Handa
2003-11-28  9:31   ` [mew-int 01653] " Werner LEMBERG
2003-12-01 12:40     ` [mew-int 01661] " Kenichi Handa
2003-12-02 16:25       ` Stefan Monnier
2003-12-02 23:37         ` [mew-int 01671] " Kenichi Handa
2003-12-03 17:25           ` Stefan Monnier
2003-12-03 23:19             ` Kenichi Handa
2003-12-04  0:29               ` Stefan Monnier
2003-12-04  1:12                 ` Kenichi Handa
2003-12-04  2:21                   ` Kenichi Handa
2003-12-04 15:48                     ` Stefan Monnier
2003-12-08  2:31                       ` Kenichi Handa
2003-12-08  2:52                         ` Stefan Monnier
2003-12-08  5:01                           ` Kenichi Handa
2003-12-08  5:16                             ` Stefan Monnier
2003-12-08  6:05                               ` Kenichi Handa
2003-12-08  6:25                                 ` Stefan Monnier
2003-12-08  7:14                                   ` Kenichi Handa
2003-11-26 14:24 ` Stefan Monnier
2003-12-02  7:01 ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m3llcaqwio.fsf@kfs-l.imdomain.dk \
    --to=storm@cua.dk \
    --cc=emacs-devel@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.