unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
From: Tom Lord <lord@regexps.com>
Cc: guile-devel@gnu.org, guile-user@gnu.org
Subject: Re: Threads and asyncs
Date: Mon, 2 Sep 2002 14:24:50 -0700 (PDT)	[thread overview]
Message-ID: <9208.48505707017$1031001099@news.gmane.org> (raw)
In-Reply-To: <87it1oglmq.fsf@zagadka.ping.de> (message from Marius Vollmer on 02 Sep 2002 22:52:13 +0200)



	> I would like to specify explicitely that marking a system-async will
	> run its thunk in the thread that did the marking.


Why can't that be layered?

In other words, start with thread-independent asyncs (which have the
virtue of simplicity and speed) and then build thread-specific on top
of that (at additional cost).

Is there no use for thread-independent system-asyncs?

There is a definate design tension trying to model stack-based,
kernel-driven execution in Scheme.

I've often considered layering call/cc for that reason -- making it
strictly optional, perhaps with a modest performance penalty,
implementing it via a transformation to continuation passing style.
One difficulty is primitives that call apply or eval: you can do away
with them or give them their own threads or mirror them in
tail-recursive scheme (somehow).

There are other alternatives, such as radical changes to the execution
model, so that C stacks aren't used by Scheme at all.  In my personal
Scheme design, this is the route I've (more or less) decided on.  When
worked out, and made to work cleanly with primitives written in
"classic C style" (i.e., freely calling eval or apply), I think it
winds up converging on more-or-less the same solution as making
call/cc work by transformation to CPS.

Anyway, where I to hack Guile, I'd look into building up the
abstractions to a point where eval is potentially a stackless graph
machine, instead of a hybrid stack/graph machine -- but preserving
optimizations such as SCM's copying-gc for environment frames.

-t


_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://mail.gnu.org/mailman/listinfo/guile-user


       reply	other threads:[~2002-09-02 21:24 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <87it1oglmq.fsf@zagadka.ping.de>
2002-09-02 21:24 ` Tom Lord [this message]
     [not found] ` <200209022124.OAA07625@morrowfield.regexps.com>
2002-09-02 21:53   ` Threads and asyncs Marius Vollmer
2002-09-02 22:24     ` Tom Lord
     [not found]     ` <200209022224.PAA07962@morrowfield.regexps.com>
2002-09-02 23:51       ` Marius Vollmer
2002-09-02 23:02   ` Rob Browning
     [not found]   ` <87k7m43si7.fsf@raven.i.defaultvalue.org>
2002-09-02 23:24     ` Tom Lord
     [not found]     ` <200209022324.QAA08246@morrowfield.regexps.com>
2002-09-02 23:36       ` Tom Lord
     [not found]       ` <200209022336.QAA08304@morrowfield.regexps.com>
2002-09-02 23:52         ` Lynn Winebarger
     [not found]         ` <0209021852361X.19624@locke.free-expression.org>
2002-09-03  0:57           ` Tom Lord
     [not found]           ` <200209030057.RAA08617@morrowfield.regexps.com>
2002-09-03  1:13             ` Thomas Bushnell, BSG
     [not found]             ` <87admzub73.fsf@becket.becket.net>
2002-09-03  1:29               ` Tom Lord
2002-09-03  1:31               ` Tom Lord
2002-09-03  1:00         ` Thomas Bushnell, BSG
     [not found] ` <87ptvvubst.fsf@becket.becket.net>
2002-09-03  1:28   ` Tom Lord
     [not found]   ` <200209030128.SAA08719@morrowfield.regexps.com>
2002-09-03  1:23     ` RnRS process/history/documentation (was Re: Threads and asyncs) Lynn Winebarger
2002-09-03  1:27     ` Threads and asyncs Rob Browning
2002-09-03  1:34     ` Thomas Bushnell, BSG
     [not found]     ` <87u1l73ls1.fsf@raven.i.defaultvalue.org>
2002-09-03  1:45       ` Tom Lord
2002-09-03  1:48       ` Lynn Winebarger
2002-09-03 18:06 ` Marius Vollmer
2002-09-04  0:28   ` NIIBE Yutaka
2002-09-04 18:02     ` Marius Vollmer
2002-09-04 22:30       ` NIIBE Yutaka
2002-09-02 20:52 Marius Vollmer

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='9208.48505707017$1031001099@news.gmane.org' \
    --to=lord@regexps.com \
    --cc=guile-devel@gnu.org \
    --cc=guile-user@gnu.org \
    /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).