unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
From: Chris Vine <chris@cvine.freeserve.co.uk>
To: guile-user@gnu.org
Subject: Re: Potluck - thread safe event loop with await semantics
Date: Tue, 23 Feb 2016 01:30:34 +0000	[thread overview]
Message-ID: <20160223013034.5b1badbb@dell.homenet> (raw)
In-Reply-To: <20160223003121.4ae217f1@dell.homenet>

On Tue, 23 Feb 2016 00:31:21 +0000
Chris Vine <chris@cvine.freeserve.co.uk> wrote:
> On Mon, 22 Feb 2016 1
> When I tested guile-gnome a few years ago I could reliably get
> g-idle-add to crash when calling it from a worker thread.  If that is
> no longer the case I am pleased to hear it.  However, the little test
> program at the end[1], which prints to the screen every 1/10th of a
> second, will also segfault for me if I run it in a terminal for
> somewhere between 1 and 5 minutes.  It seems to crash more readily if
> it is in a terminal not on the current virtual desktop, but will in
> the end crash even when it is.

To complete the picture, since testing guile-gnome I have run the same
program on my alternative event loop[1], and it has been running for 55
minutes without problems.  So it does not seem to be a guile threading
issue.  There definitely seems to be something wrong with guile-gnome
itself as regards thread safety.

Chris

[1]  The equivalent program was:

---------------------------
#!/usr/bin/env guile
!#

(use-modules (event-loop) (ice-9 threads))

(define main-loop (make-event-loop))

(call-with-new-thread
 (lambda ()
   (let loop ()
     (event-post! main-loop (lambda () (display "running ") #f))
     (usleep 100000)
     (loop))))

(event-loop-block! main-loop #t)
(display "Starting main loop\n")
(event-loop-run! main-loop)
---------------------------



  reply	other threads:[~2016-02-23  1:30 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-16 21:45 Potluck - thread safe event loop with await semantics Chris Vine
2016-02-22 12:01 ` Ludovic Courtès
2016-02-22 16:36   ` Marko Rauhamaa
2016-02-22 17:40   ` Chris Vine
2016-02-22 17:53     ` Thompson, David
2016-02-22 18:12       ` Chris Vine
2016-02-22 19:54         ` Christopher Allan Webber
2016-02-22 20:28     ` David Pirotte
2016-02-23  0:31       ` Chris Vine
2016-02-23  1:30         ` Chris Vine [this message]
2016-02-23 19:55           ` David Pirotte
2016-02-23  6:25         ` David Pirotte
2016-02-23 12:09           ` Chris Vine
2016-02-23 16:49             ` Chris Vine
2016-02-25 23:22             ` David Pirotte
2016-02-23  4:58     ` Chris Vine
2016-03-01 20:39     ` Amirouche Boubekki

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=20160223013034.5b1badbb@dell.homenet \
    --to=chris@cvine.freeserve.co.uk \
    --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).