unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
* intermittent segfaults in master
@ 2009-10-24 13:30 Andy Wingo, n
  2009-10-24 21:56 ` Ken Raeburn
  0 siblings, 1 reply; 3+ messages in thread
From: Andy Wingo, n @ 2009-10-24 13:30 UTC (permalink / raw)
  To: guile-devel

Hello,

I have been experiencing intermittent segfaults recently, as I worked on
wip-case-lambda. They would almost always go away immediately -- as in,
while rebuilding guile, the process would stop because of a segfault,
but I could type make again and it would succeed.

Here is one core dump I was investigating:

    http://paste.lisp.org/display/88926

The odd thing is that we have a NULL value in there, as the car of a
cell. Here's the top of the backtrace:

#0  scm_is_pair (x=<value optimized out>) at ../libguile/inline.h:293
#1  scm_sloppy_assq (x=<value optimized out>) at alist.c:58
#2  0x00e113c4 in scm_assq_ref (alist=0x98f8458, key=0x976edf0) at alist.c:209
#3  0x00e6c843 in scm_procedure_property (proc=0x989ee00, key=0x976edf0) at procprop.c:207

Now in wip-case-lambda, some things changed regarding procedure
properties. Instead of having a strange "standin closure" thing, for
non-closure procedures, properties get stored in a weak hash table. So
that assq is in a value that we (probably; there is another case there)
just pulled out of a doubly-weak hash table. So could it be somehow that
one of those links just got nulled by a call to GC_malloc, perhaps by
another thread?

For the meantime I could just make this a key-weak hash table. But this
seems like the kind of problem that could hit user code. Ludovic I think
you will start to see these crashes now that case-lambda was merged (and
specifically 56164a5a). Would you be on the lookout for this kind of
problem, and in contact with the libgc list? If this analysis is correct
anyway, it's very possibly I have misinterpreted things.

Regards,

Andy
-- 
http://wingolog.org/




^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2009-11-03 23:58 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-10-24 13:30 intermittent segfaults in master Andy Wingo, n
2009-10-24 21:56 ` Ken Raeburn
2009-11-03 23:58   ` Neil Jerram

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).