unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
From: Nala Ginrut <nalaginrut@gmail.com>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: guile-devel@gnu.org
Subject: Re: Comments on ‘wip-nio’
Date: Thu, 22 Mar 2012 10:40:34 +0800	[thread overview]
Message-ID: <CAPjoZocZdro9CZ8S4NUFftRWebdJfQzkuQCsDPDovQN7dY7yww@mail.gmail.com> (raw)
In-Reply-To: <87wr6d4m07.fsf@gnu.org>

[-- Attachment #1: Type: text/plain, Size: 2184 bytes --]

On Thu, Mar 22, 2012 at 6:39 AM, Ludovic Courtès <ludo@gnu.org> wrote:

> Hello,
>
> I had a quick look at ‘wip-nio’, and here are initial comments.
>
>  • epoll is Linux-specific.  Any idea how a more multi-platform API
>    could be provided?  I guess libevent could be used, but we don’t
>    want to add one more dependency in 2.0.  How much is (ice-9 nio)
>    dependent on epoll vs. poll, for instance?
>
>
Maybe add a module named "(ice-9 linux)"? And we may add more
Linux-specific things.
Also "(ice-9 bsd)" which provides "kqueue" or other interesting things.
If users try to use BSD-specific modules under Linux, we may throw an
exception. And functions like
"under-bsd?" or "under-linux?" maybe helpful.
Anyway, libevent for Guile is also a good idea. But I don't think libevent
should integrate into Guile. We can write
a standalone guile-libevent.

 • ‘nio’ doesn’t seem very descriptive to me; ‘nbio’ maybe?
>

In my server project, I named it "aio" since it's asynchronous.


>
>  • I agree that it’s an important problem to address, and I like the
>    use of coroutines, and I like that it actually solves the problem
>    for some applications like the web server.
>
>    However, I think the approach has shortcomings: (1) it doesn’t
>    accept other sources of events (timers, mouse clicks, etc.), and
>    (2) it doesn’t allow you to do something while waiting (of course,
>    other threads/waiters get scheduled, but the caller is just
>    waiting, so you can’t for instance update your progress bar while
>    waiting for your bytevector to arrive.)
>
>    Functional reactive programming à la FrTime [0], and synchronous
>    reactive programming à la HipHop [1] seem to be much more generic
>    and expressive.  It would be great if Guile would come with such a
>    framework eventually.  It’s probably more work, though, so it
>    probably makes sense to have an alternative mechanism in the
>    meantime.
>
> WDYT?
>
> Thanks,
> Ludo’.
>
> [0] http://www.cs.brown.edu/~greg/
> [1] http://www-sop.inria.fr/members/Gerard.Berry/Papers/plastic2.pdf
>
>
>
>

[-- Attachment #2: Type: text/html, Size: 3100 bytes --]

  reply	other threads:[~2012-03-22  2:40 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-21 22:39 Comments on ‘wip-nio’ Ludovic Courtès
2012-03-22  2:40 ` Nala Ginrut [this message]
2012-03-22 20:40   ` Ludovic Courtès
2012-03-22 21:36     ` Neil Jerram
2012-03-23  1:17       ` Nala Ginrut
2012-03-23  1:47         ` Nala Ginrut
2012-03-23 10:01           ` Andy Wingo
2012-03-23 10:05       ` Andy Wingo
2012-03-25 20:17         ` Neil Jerram
2012-03-25 23:23           ` Andy Wingo
2012-03-25 10:46   ` Andreas Rottmann
2012-03-23  9:58 ` Andy Wingo
2012-03-27 15:50   ` Ludovic Courtès

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=CAPjoZocZdro9CZ8S4NUFftRWebdJfQzkuQCsDPDovQN7dY7yww@mail.gmail.com \
    --to=nalaginrut@gmail.com \
    --cc=guile-devel@gnu.org \
    --cc=ludo@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).