unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
From: Andy Wingo <wingo@pobox.com>
To: linasvepstas@gmail.com
Cc: bug-guile@gnu.org, guile-user <guile-user@gnu.org>, guile-devel@gnu.org
Subject: Re: Does anyone actually use threads with guile?
Date: Thu, 13 Nov 2008 21:46:44 +0100	[thread overview]
Message-ID: <m363mr9wwb.fsf@pobox.com> (raw)
In-Reply-To: <3ae3aa420811122056x3d2b2f75nc22a66ae1d977902@mail.gmail.com> (Linas Vepstas's message of "Wed, 12 Nov 2008 22:56:13 -0600")

Hi Linas,

[cc'ing them all, but followups to just one please -- bug-guile is
probably best]

For my part I apologize for not having the cycles to poke this more
thoroughly. Fortunately you are a good programmer and can figure things
out :)

History: pthread support was new with 1.8, as you probably know. A
number of people have used it, but it seems that perhaps you are
pounding it more than most.

On Thu 13 Nov 2008 05:56, "Linas Vepstas" <linasvepstas@gmail.com> writes:

> Basically, at any given time, some thread might be
> in a critical section. Some other thread may be
> throwing an error for some utterly unrelated reason.
> Yet, when the error is thrown, this "critical section"
> check will trip, and it will do so for an utterly bogus
> reason.  At least, that describes my case.
>
> Is there any reason at all not to remove this check
> entirely? (at  libguile/throw.c line 695.)

I think the idea behind the check sounds good -- it is incorrect to
throw from within a critical section, and the check detects this.

But the check is incorrect as you noticed, it should be checking if the
current thread is in a critical section.

So we have two options, to remove the check or to fix the critical
section counter (possiblity to be thread-local). My instinct would be
that removal is the correct solution in 1.8, and that in master the
decision depends on whether we merge the BDW GC or not, and what the
impact that GC has on the idea of critical sections.

More input appreciated.

Cheers,

Andy
-- 
http://wingolog.org/




  reply	other threads:[~2008-11-13 20:46 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <3ae3aa420811122028w3c069b88q93a8290385188f79@mail.gmail.com>
2008-11-13  4:56 ` Does anyone actually use threads with guile? Linas Vepstas
2008-11-13 20:46   ` Andy Wingo [this message]
2008-11-13 22:56     ` Linas Vepstas
2008-11-17 13:09   ` Han-Wen Nienhuys

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

  List information: https://www.gnu.org/software/guile/

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

  git send-email \
    --in-reply-to=m363mr9wwb.fsf@pobox.com \
    --to=wingo@pobox.com \
    --cc=bug-guile@gnu.org \
    --cc=guile-devel@gnu.org \
    --cc=guile-user@gnu.org \
    --cc=linasvepstas@gmail.com \
    /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.
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).