From: Chris Vine <chris@cvine.freeserve.co.uk>
To: Panicz Maciej Godek <godek.maciek@gmail.com>
Cc: "guile-user@gnu.org" <guile-user@gnu.org>
Subject: Re: libguile thread safety
Date: Sat, 4 Jan 2014 17:16:55 +0000 [thread overview]
Message-ID: <20140104171655.3df648d5@bother.homenet> (raw)
In-Reply-To: <CAMFYt2Z_aSgYyW0cAPUmT7UhoNvy=3UOvHnXvyTHn2tQPaFKNw@mail.gmail.com>
On Sat, 4 Jan 2014 16:01:35 +0100
Panicz Maciej Godek <godek.maciek@gmail.com> wrote:
[snip]
> It indeed does seem that the threads share their top-level bindings on
> guile's side, and I suppose that this is the intended behaviour. I
> think that it can be easily adjusted with scm_eval_string_in_module,
> i.e. if you provide a separate module for each thread.
Ye gods.
Your suggestion seems the way to go. However, having a separate module
for each thread is not really a runner with a thread pool. Instead of
doing this on a thread-by-thread basis, it would instead be necessary to
create a new module on the fly for each task. Most variables could of
course be wrapped in an overarching lambda or let expression
encapsulating the task, but there will still be some top level variables
to be exported to the task that the code will need to see.
Is there any procedure to obtain a unique random name in guile?
Chris
next prev parent reply other threads:[~2014-01-04 17:16 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-03 23:34 libguile thread safety Chris Vine
2014-01-04 0:00 ` Ludovic Courtès
2014-01-04 17:19 ` Chris Vine
2014-01-04 0:08 ` Panicz Maciej Godek
2014-01-04 0:22 ` Chris Vine
2014-01-04 0:56 ` Panicz Maciej Godek
2014-01-04 1:22 ` Panicz Maciej Godek
2014-01-04 9:39 ` Chris Vine
2014-01-04 21:28 ` Mark H Weaver
2014-01-04 1:59 ` Mark H Weaver
2014-01-04 9:50 ` Chris Vine
2014-01-04 12:44 ` Chris Vine
2014-01-04 15:01 ` Panicz Maciej Godek
2014-01-04 17:16 ` Chris Vine [this message]
2014-01-04 19:37 ` Mark H Weaver
2014-01-04 21:01 ` Chris Vine
2014-01-04 22:43 ` Panicz Maciej Godek
2014-01-04 23:31 ` Chris Vine
2014-01-05 13:15 ` Panicz Maciej Godek
2014-01-05 17:37 ` Mark H Weaver
2014-03-18 10:49 ` Chris Vine
2014-03-18 15:22 ` Mark H Weaver
2014-03-18 19:32 ` Chris Vine
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=20140104171655.3df648d5@bother.homenet \
--to=chris@cvine.freeserve.co.uk \
--cc=godek.maciek@gmail.com \
--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).