From: Nala Ginrut <nalaginrut@gmail.com>
To: Xin Wang <dram.wang@gmail.com>
Cc: guile-user@gnu.org
Subject: Re: The equivalent of racket's break-thread in guile?
Date: Fri, 31 May 2013 14:55:37 +0800 [thread overview]
Message-ID: <1369983337.2610.64.camel@Renee-desktop.suse> (raw)
In-Reply-To: <CAHjSAjUWhgKUdCaGTGqAA2zPvEN5Z4CVcoyqEDKnCOt8c-REVg@mail.gmail.com>
On Fri, 2013-05-31 at 14:24 +0800, Xin Wang wrote:
>
>
> Thank you for pointing out this.
>
>
> After some more search, I found that pthread has function pthread_kill
> [1], which can be used to send signal to specific thread.
>
>
> No sure if it can be used to implement similar behaviour.
>
>
> [1]
> http://pubs.opengroup.org/onlinepubs/9699919799/functions/pthread_kill.html
At least in Linux, pthread_kill may effect the whole process:
----------------------------cut----------------------------------
Signal dispositions are process-wide: if a signal handler is
installed, the handler will be invoked in the thread thread,
but if the disposition of the signal is "stop", "continue", or
"terminate", this action will affect the whole process.
----------------------------end----------------------------------
The real solution for your purpose is green-thread IMO.
>
>
> > Regards,
> > Xin Wang
>
>
>
>
next prev parent reply other threads:[~2013-05-31 6:55 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-30 23:40 The equivalent of racket's break-thread in guile? Xin Wang
2013-05-31 3:59 ` Nala Ginrut
2013-05-31 6:24 ` Xin Wang
2013-05-31 6:55 ` Nala Ginrut [this message]
2013-05-31 8:44 ` Xin Wang
2013-05-31 10:33 ` Xin Wang
2013-05-31 12:16 ` Chaos Eternal
2013-06-01 23:27 ` Xin Wang
2013-05-31 10:01 ` Ludovic Courtès
2013-06-01 23:49 ` Xin Wang
2013-06-02 0:34 ` Nala Ginrut
2013-06-02 1:11 ` Xin Wang
2013-06-02 13:51 ` Ludovic Courtès
2013-06-03 1:37 ` Xin Wang
2013-06-03 10:12 ` Ludovic Courtès
2013-05-31 11:20 ` Taylan Ulrich B.
2013-05-31 23:28 ` Thien-Thi Nguyen
2013-06-01 6:46 ` Taylan Ulrich B.
2013-06-01 16:08 ` Thien-Thi Nguyen
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=1369983337.2610.64.camel@Renee-desktop.suse \
--to=nalaginrut@gmail.com \
--cc=dram.wang@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).