[racket] Efficiency of tight loops in Racket

From: Eli Barzilay (eli at barzilay.org)
Date: Fri Jan 14 09:52:09 EST 2011

20 minutes ago, David Nolen wrote:
> On Fri, Jan 14, 2011 at 9:21 AM, Eli Barzilay <eli at barzilay.org> wrote:
> > 9 hours ago, David Nolen wrote:
> > >
> > > With a good FFI it seems like someone could write a great Racket DSL
> > > for evented network programming a la Node.js minus all the JS
> > > callback cruft.
> >
> > I know very little about it, but it looks like it covers stuff that
> > racket includes as built in functionality.
> Does Racket use libev/libio?

Not AFAICT, but -- IIUC -- these things fill two roles: make things
efficient, and provide a better interface.  The first is not as
important in racket since threads (the one you get with `thread') are
"green" so they're much lighter than OS threads; and the racket
interface is definitely high level enough to make a foreign interface
to these things redundant.

So my guess is that these libraries could have been useful for Matthew
in saving a lot of code that he had to fight with, but that's already

(I also think that there's an issue when there's a very large number
of connection that libev is supposed to handle, but so far I don't
remember anyone raising that point on the list.)

          ((lambda (x) (x x)) (lambda (x) (x x)))          Eli Barzilay:
                    http://barzilay.org/                   Maze is Life!

Posted on the users mailing list.