[Ecls-list] Problems with slime

Tobias C. Rittweiler tcr at freebits.de
Sun Feb 7 20:29:19 UTC 2010


Juan Jose Garcia-Ripoll writes:

> Slime gets my computer at 100% activity because it has some strange way of
> waiting for input: this is a loop over streams, inifite, using
> read-char-no-hang without ever waiting. I am sure there are better ways of
> doing this. This is in swank-backend.lisp -- do all implementations have
> this problem?
>
> (defun wait-for-streams (streams timeout)
>   (loop
>    (when (check-slime-interrupts) (return :interrupt))
>    (let ((ready (remove-if-not #'stream-readable-p streams)))
>      (when ready (return ready)))
>    (when timeout (return nil))
>    (sleep 0.1)))

The problem is that not more advanced ways are implemented. Slime can
also me made to use threads, and serve-event, but ECL's backend does not
support that.

I tried to do both in past, but encountered non-obvious problems. I'll
polish up, and commit the work in progress.

  -T.





More information about the ecl-devel mailing list