XO: The Next Lisp Machine?

I have ordered a Quanta XO-1 (One Laptop Per Child) on the Give One, Get One deal, where you pay $400 plus shipping and you get an XO and donate one to the project ($200 tax deduction). This is just so cool that I have to have one. And I need a lightweight box that can do email and browsing that I can carry around easily. There are other good options but the XO is so novel and interesting! It’s just 3+ lb and runs on 2-3 watts with an amazing lithium ferro-phosphate battery, and physically extremely durable, waterproof, and dirtproof, and a great (but small, 7.5 inch) screen. No disk nor CD/DVD, but you can add them externally. And if the OLPC project is a big success, this may be the platform of the next generation of hackers. They are aiming to bring the price down to $100.

http://wiki.laptop.org/go/Hardware_specification

After watching a talk given at Google by Ivan Krstic, I got more and more excited hearing about the hardware and the software. A lot (14, apparently) of hackers, at least some of whom are famous superhackers (e.g. Jim Gettys), were involved in putting together the software. They have thought of and taken care of a huge number of issues. Perhaps I’ll end up contributing open source code to the project someday, although at the moment I’m too busy for that to be feasible.

The Give One Get One deal is only available for another 7 days. It may be hard to get them after that since they are going to be sold only to schools and other educational institutions and governments and in the third world. So if you want one, don’t hesitate:

http://www.laptopgiving.org/en/index.php www.xogiving.org

The only thing I’m worried about is that David Pogue in the New York Times says that the XO’s keyboard is too small for an adult to touchtype on. I asked around, and Luke Gorrie (of SLIME fame) says that it’s frustrating at first but then he learned to touchtype on it at high speed. (I was going to walk over to the Media Lab and try one but I have no time in the next seven days and I’m just too convinced now.) And so many people seem to get along fine on much smaller keyboards, such as those on the Blackberry or smart phones (not touchtyping, obviously, but good enough for email when I’m on the road). So I’ll chance it. Other drawbacks: 2 minutes to boot (hey, Lisp machines booted slowly), and switching between apps is “poky”. (But the apps are fast.)

In a previous post, I mentioned capability architectures. The XO’s “Bitfrost” is not a capability system, but it does deal with the issue of mutually-suspicious protection domains. Given how many XO-1′s there will be, if the project succeeds, it will be an obvious target for malware, and I think Bitfrost will be a big help there. Bitfrost works by dividing up protection domains at a coarse level, whereas I’m more interested in very-fine-level schemes. See:

http://en.wikipedia.org/wiki/Bitfrost

Great technical info in the video of the talk at Google by Ivan Krstic, who is the architect of Bitfrost but talks about all aspects of the system:

General info:

http://en.wikipedia.org/wiki/OLPC_XO-1

Main web site, but it seems to be down at the moment:

laptop.org

David Pogue’s review in The New York Times, both written and video. Pogue does lots of product reviews and I have a lot of confidence in his evaluations (and I love his books).

http://www.nytimes.com/2007/10/04/technology/circuits/04pogue.html?_r=1&oref=slogin

http://video.on.nytimes.com/?fr_story=6ffd976ed367bacae4171dd4999d36431c84b0f5

There’s plenty more if you Google for “OLPC”.

The XO does everything in Python. You can see all the code, with a single keystroke (that shows the code of what’s running) and even modify the code. In the video, the speaker (Ivan Krstic’) is asked “Why not just use Lisp or Smalltalk?”, and the questioner cites Lisp machines! See, our influence is still there! He replies that doing everything in Python “comes close to the general Lisp machine idea” (of course he, too, knows what a Lisp machine is!). Answer: he protests that it’s a lot like a Lisp machine except that the language doesn’t go all the way down to the metal (it’s based on Linux). Hey are also shipping Squeak (a modern Smalltalk). They used Python because of the “size and momentum” of the community, and because he feels that Lisp has a steeper learning curve than Python does for kids. I won’t object to those reasons.

Hey, Python, Lisp, what’s the difference? :) So, strange as it is to say, maybe this is the new Lisp machine!

Tags: , , , ,

16 Responses to “XO: The Next Lisp Machine?”

  1. Laptop Reviews » XO: The Next Lisp Machine? Says:

    [...] dlweinreb wrote an interesting post today on XO: The Next Lisp Machine?Here’s a quick excerptMain web site, but it seems to be down at the moment:. laptop.org. David Pogue’s review in The New York Times, both written and video. Pogue does lots of product reviews and I have a lot of confidence in his evaluations (and I love his … [...]

  2. dispatches from TJICistan » Blog Archive » TJIC again rails against the “$100″ laptop Says:

    [...] liking Dan Weinreb’s blog a lot… but then he goes an inexplicably waxes enthusiastic about the One Laptop Per Child [...]

  3. Wayan @ OLPC News Says:

    You’re not the only one excited about the XO! I can’t wait to be the first kid (at heart) on my block to own one!

  4. dlweinreb Says:

    Travis: Yup, it costs, I think, $188, not $100. So when was the first time that you saw a technological device come out at some price and stay at that price forever, whereas how many times have you seen the price come down with time?

    As for running water and sewage: first, do you really think that there is a pool of money that, had it not gone towards these computers, would have automatically been spent on water and sewage? Fund raising doesn’t work that way. Second, one way people get out of poverty is to become better-educated. It’s the old “give a man a fish and you feed him for one day, but teach a man to fish and he’s fed every day”. I have often heard of schools constructed in third-world countries, which are found abandoned soon afterwards. OLPC is a new approach. It’s worth a try to see what happens. Meanwhile despite my feelings about Microsoft, I’m all for the B&M Gates Foundation’s fight against malaria and against extreme poverty.

    Regarding Negroponte versus Intel, it does appear that Intel is trash-talking the OLPC project (“The OLPC represents a limited version of the modern PC, reliant on old hardware that limits its functionality.” Huh?) Certainly, Intel and Microsoft have the right to compete, but I do not care for FUD tactics, nor the ad hominem attacks on Negroponte, and I can sympathize if Negroponte is angry about it. Obviously they’d hate OLPC because it uses AMD and Linux, their respective betes noirs. Is it so surprising that Negroponte talks back? Intel’s marketing campaign is entitled “The shortcomings of the One Laptop per Child approach”, and they refer to it as a “gadget” in the press. Insulting your competition may be common practice but you can’t expect the OLPC people to like it.

    Yeah, Nicholas Negroponte is self-aggrandizing sometimes, and has been ever since back when I was an undergrad and he ran the Architecture Machine Group. But that was a good lab that hired great people and did neat things, even when they ended up rolling their eyes about the “latest thing Nicholas said”. In my way of thinking, that does not damn the OLPC project, which deserves to be judged on its merits.

    And this isn’t exactly competition between two companies vying for the same market; one of them is a non-profit, which is a very different situation as far as I’m concerned.

    Anyway, it seems that the battle is over:

    http://wiki.laptop.org/go/Intel

    http://www.news.com/OLPC-and-Intel-bury-the-hatchet-for-the-children/2100-1005_3-6196629.html

    “Negroponte’s One Laptop Per Child project is bringing Intel on board as a partner and a possible future supplier, the two entities announced Friday morning. Intel will become the 11th member of the OLPC’s board, joining other companies such as Google, eBay, Nortel and Intel’s bitter rival Advanced Micro Devices.” So that should put an end to that.

    Anyway, I wasn’t trying to comment on the OLPC program and its world-wide implications, since I don’t think I know much about that. I was mainly speculating on its utility for myself, and exploring the analogies with the Lisp machine. I had also been looking at the Eee PC, which looks like a fine product that I’d happily use for email and web browsing, but the XO is so novel that I could learn new things from it too, and I’m fond of lots of things like the durable hardware packaging and other things I mentioned.

  5. dlowe Says:

    Regarding the criticism of the OLPC charity as misplaced money, I submit that like most social projects, it’s an experiment. We don’t know what’s going to happen. The worst case I’m afraid of is that the kids with laptops will simply have them stolen by adults.

    Once I’ve gotten mine, I’m hoping to start a hypercard-like project for the XO with a Scheme language instead of Hypertalk. Hopefully there will be enough community interest to get it off the ground.

  6. dlweinreb Says:

    dlowe: They’ve apparently given some thought to the theft problem. See http://wiki.laptop.org/go/The_Theft_Problem. One point they make is that if an adult has one, it’ll be pretty clear that it was stolen; but I don’t know whether or not that would be a strong deterrent in some of the cultures of the world. The main theft-prevention feature is that they must get a wireless crypto-token from the school server. The tokens are transmitted every day and expire after a month. In situations without appropriate networking, the tokens can come in via the USB ports. Apparently such a scheme is already being used by something called the EduVision eSlate in Kenya.

    I hope it’ll be easy to get a Scheme (and a Common Lisp) running. After all, it’s just another Linux/x86 port. Most Common Lisp implementations already run on Linux/x86 (I don’t know the story with Scheme but presumably it’s similar). I wonder how easy/hard it would be to bring up a good Scheme learning environment like DrScheme. You need the X Window System but apparently it already has that.

    Travis: By the way, regarding the price of the XO: Jim Gettys says in his blog that “we have always said ‘$100 in late 2008-2009′, which seems to get lost in the press. So that’s in line with the point I made in my earlier comment: the price will come down, as prices always do.

  7. tsobota Says:

    The first country that is taking this idea seriously and implementing it is Uruguay. My old friend and ex-boss Miguel Brechner, with whom I used to sell and install DEC machines years back, is now in a government-funded technology group and he is installing some 100.000 XOs to start with. I really wish him all the luck possible and will be following this project closely. I understand that other South American countries are also interested.

    Ex-MIT’s Negroponte is naturally very happy about this project, since, as he said, everybody was very interested about these machines … but nobody was signing checks. He was reticent initially, since he hoped to start with bigger countries.

    I don’t think that the kids receiving these computers will care about the differences between Python and Lisp, at least not initially :-)

  8. Ivan Krstić Says:

    Hi Dan,

    glad to hear you enjoyed the Google talk! As you imply you’re within walking distance to the Media Lab, it’d be a pleasure to have you visit us at the OLPC offices sometime. One of the _explicit_ reasons I joined OLPC was to try and recreate some of the magic of Lisp machines — it’d be fantastic to talk about this with you. I’m out of town for a couple of weeks, but drop me an e-mail if you’d like to grab lunch when I’m back.

    Cheers,
    Ivan.

  9. rascunho » Blog Archive » links for 2007-11-24 Says:

    [...] XO: The Next Lisp Machine? « Dan Weinreb’s Weblog “Why not just use Lisp or Smalltalk?”, and the questioner cites Lisp machines! See, our influence is still there! He replies that doing everything in Python “comes close to the general Lisp machine idea” (tags: dlweinreb.wordpress.com 2007 mes10 dia24 Lisp OLPC programming) [...]

  10. Luke Gorrie Says:

    Booting into Openfirmware’s Forth prompt reminds me vividly of programming on the Amiga in ASMOne. The hardware is there for you like a canvas to do whatever you want. Any obscure use of the hardware is fair game because all the other machines will be identical. But you don’t necessarily get very much done.. :-)

    Dan, what do you think of Squeak as a LispM successor?

  11. Stas Sushkov Journal - XO: Lisp Machine Says:

    [...] Dan Weinreb scrie un articol interesant despre laptopurile XO. Ce legatura ar putea fi intre Lisp şi XO?! [...]

  12. dlweinreb Says:

    Hi, Luke! I wish I knew more about Squeak. Many people mentioned it at the OOPSLA-2007, but I was rushing around so much that I didn’t have a chance to talk to anyone about it. Looking at the web site, it seems to have a great deal in common with classic Smalltalk-80, including the basic browser. There’s a classical Inspector, and a cool-looking variant called the Explorer. There’s a pretty classical debugger, better at source-code debugging than Lisp as usual, a file browser, a facility for undoing code changes (nice!), and meta-. (finding source code) of course. There’s a refactoring tool and a unit test framework. It’s all cleaner than Lisp; everything is an object, which leads to a lot more uniformity in the libraries, a nice clean meta-object protocol as part of the language definition. Lisp is more of a multi-paradigm language. On the other hand, Smalltalk is sometimes too simple for me, e.g. only the very simplest iteration facility, and you can’t use macros to add one (although you could add one in other ways). I’m one of those people who liked “loop” a lot.

    I can’t tell anything about the performance of the implementation; I know that L Peter Deutsch invented JIT compilers for Smalltalk originally (in 1984) but I don’t know if this has one. Apparently compared to Smalltalk-80 it’s public domain and written in itself, has blocks as true closures, block-local variables, it’s based on a VM that targets dynamic languages. Ah, it can generate C and claims to be as fast as commercial Smalltalks. It has better facilities for graphics and sound and networking. It’s ported to all major platforms.

    The original OOPSLA-1997 paper talks about the implementation, as least as it was at that time. The implementation has a clever scheme to minimize memory overhead per object. Pointers are direct (no object table to indirect through). The GC is incremental and compacting though not generational. Aha, there’s no JIT compiler, and the benchmarks seem to show that it’s more than a factor of 5 slower than ParcPlace Smalltalk. They were focusing on keeping the implementation simple and easy to port. Of course, someone could do a JIT compiler someday, as could the kind of optimizations used in the Self compiler. This paper is from some time ago and so there may have been improvements since.

    There are apparently two interesting Web frameworks (at least) called Seaside and Aida. In Common Lisp, there is UnCommon Web, and coming soon, we hope, Lisp on Lines.

    It certainly looks like it could be the basis of a LispM successor. The LispM was Lisp all the way down through the operating system, but there are few realistic venues for that kind of thing these days. My best prognostication at this point is that we won’t see anything like this until the pendulum swings back to having interest in innovative operating systems, and someone does a good one that uses an object-granularity capability architecture for security.

    The LispM had all of its applications written in Lisp, and they had some extensibility; I don’t know whether you can write new commands for the Squeak tools. I doubt that their editor is anything like as powerful as Zmacs (the LispM Emacs, one of my own major contributions). I’m not sure what its story is on threads and synchronization. Is there a profiler? Does it play well with source control systems like Subversion, given that it’s not oriented toward code source files? (That’s not particularly a LispM thing, but it’s important these days.) There isn’t a built-in object-oriented database system a la Statice (also one of my own contributions, which may be why I thought of it). I don’t see a foreign function call interface (also not a LispM thing of course), sometimes very useful (high-performance crypto libraries, fast access to relational database systems, etc). Some people might be put off by its use of its own widgets rather than those of the underlying operating system (a contentious issue in the Java world). And, of course, no Lisp macros. Only a 32-bit address space, which limits the degree to which you can build your whole world in it. (I found a 2004 blog posting saying that they’re working on a 64-bit version.) No multiple inheritance or multimethods or method combination, none of which is all that essential but when you need them, they’re useful.

    Python, as a language, also has a lot in common with Lisp and Smalltalk. A major advantage over both, from a practical point of view, is its “conventional” lexical syntax. That means no macros in the Lisp sense. Smalltalk has an unconventional syntax as well as no macros. Python’s popularity results in more libraries, although for some reason it seems to be weak in the IDE area; I don’t know why.

    As far as being LispM-like, I think one of the most important things about Squeak is that the sources are available, so that you can learn about, debug, and even modify what you are given. By having a wide range of applications in Lisp with sources available, the advantage of available sources went a lot farther. We’re seeing this with the Python code in the XO, which is supposed to have a key on the keyboard that immediately takes you to the source code of whatever you’re using/doing. I think this is one of the things that was so attractive about LispM’s. There’s a nice paper about one person’s experience with LispM’s at http://www.gia.ist.utl.pt/~aml/Links/LispOS.txt that stresses this. This is the main reason I drew the parallel between Lisp machines and the XO.

  13. Paul Donnelly Says:

    Dan, you seem to have a pretty accurate idea about Squeak.

    I’ve played with it a bit, and I was impressed by its development environment. I don’t think it plays well with SVN, although it would presumably be possible to code something based on its facility for saving your code to a text file (filing out). This didn’t seem to be working at all for me though! I may have an unstable version or something. Squeak does have its own repository system called Monticello that I believe provides similar facilities to other source control systems.

    It’s got a graphical debugger that you can edit your program through, which is a nice touch. Another thing that struck me is that writing code in Squeak is tightly bound to the GUI. While I believe that it’s possible to write all your code in Sqeak’s Notepad-esque “Workspace”, a programmer would normally use the system browser to create new objects and add methods to them. It also has a built-in testing framework, a method browser that lets you search by name or by desired effect (!), and some other nifty stuff too, iirc.

    The text editor itself isn’t powerful, which is kind of a shame. I would have liked to see simple macros (in the vi sense, not the Lisp sense) at least, as well as search-and-replace. Presumably lacking these isn’t a huge impediment to the Smalltalk programmer, but that makes it largely useless for anything else.

    I do think they’ve crafted a development system far superior to many. There’s a slew of things that other IDEs do that it doesn’t, but it’s mostly things that aren’t hugely useful to a Squeak programmer. They’ve really managed to put the “Integrated” in IDE.

  14. Web 2.0 Announcer Says:

    XO: The Next Lisp Machine? « Dan Weinreb?s Weblog

    [...][...]

  15. dlweinreb Says:

    There is a review of the XO at http://www.freedom-to-tinker.com/?p=1206. It was written by SG, a twelve-year-old who writes as well as anyone I’ve ever read (which is amazing). The comments on the posting are also interesting.

    For SG’s earlier review of the Beta 2, scroll down in http://www.freedom-to-tinker.com/?cat=18.

    For a treat, see http://lukego.livejournal.com/, Luke Gorrie’s report of his trip around the world with an XO and a unicycle. (Thanks to Vadim Nasardinov for pointing me at this.) Learn about hacking the XO way down at the Forth level!

    The deadline for the “Get one, give one” deal has been extended to the
    end of the year.

    My old friend Brian Silverman, whom I have not seen in years, has co-authored a paper that helps explain the kind of educational philosophy behind the OLPC project, althhough it is not specifically about OLPC. See http://llk.media.mit.edu/papers/IDC-2005.pdf.

  16. Grant Rettke Says:

    The XO’s keyboard reminds me of a Psion 5 Series handheld computer. Once you get adjusted you barely notice, but for the fact that the spacebar only activates when you hit it dead center.