Re: Lisp in embedded systems?



Stefan Arentz <stefan.arentz@xxxxxxxxx> writes:

> I'm looking for a new language/environment to do the next version of a
> medium sized C++ application in. I'm interested in using a flavour of
> Lisp because I think it will allow us to overcome some of C++'s issues.
> (Development time, hard to debug, error prone).
>
> However, this has to run on an embedded system. And I'm not sure if that
> will work out with Lisp.

Why not? Have you heard the rumor that Lisp is Big and Slow? It seems
that rumor just won't die.

> The device is small. It just has 2MB flash and 8MB ram. The application
> really just needs the basics ... threads, sockets, simple data structures,
> no storage and some bindings to C methods in a library.

Funny; it used to be that 1 Mb _total_ was considered small. And I
came close, getting lisp inages less than a megabtyte on disk. But
that was not the same as memory footprint, and my smallest memory
footprint was about 1.5 Mb.

Of course, your mileage depends upon your needs. If your device
has graphics, then there's a lot more library space required.

> Performance is not an issue. It just needs to do basic network io
> once in a while and control some hardware features.
>
> Am I crazy to even look at lisp here?

Absolutely. Crazy like a fox.

> Can anyone recommend a public (open source) flavour that would work here?

Why do you need open-source? Why not just free? Try out an Allegro CL
trial version.

> Anyone with real world experience?

I've had experience crunching lisp sizes down, both image size and
memory footprint. But I wouldn't call that real-world experience,
since the "application" involved there was the lisp itself. We
do have customers, some of whom have successfully put Allegro CL
onto small or memory-limited devices; I won't give any names, but
some do participate in this newsgroup - perhaps they would respond.

And finally, several years ago one of the developers at Franz got
an Allegro CL application to serve as a Netscape plugin, to be used
as a webcam server. This was back in the days when Netscape and other
web browsers weren't as bloated as they are today, but back then the
Netscape and the plugin fit along with the kernel and the webcam driver
into a linux box with 8 Mb of RAM, and it didn't page at all while
running. Of course it probably couldn't be done today, because most
programs have grown by hundreds of precent. However, the base of
Allegro CL has not grown by more that some 10s of percent over the
last 8 or so years, before which it was actually shrinking.

--
Duane Rettig duane@xxxxxxxxx Franz Inc. http://www.franz.com/
555 12th St., Suite 1450 http://www.555citycenter.com/
Oakland, Ca. 94607 Phone: (510) 452-2000; Fax: (510) 452-0182
.



Relevant Pages