What are the main differences between CLISP, ECL, and SBCL?
Asked Answered
M

3

29

I want to do some simulations with ACT-R and I will need a Common Lisp implementation. I have three Common Lisp implementations available: (1) CLISP [1], (2) ECL [1], and (3) SBCL [1]. As you might have gathered from the links I have read a bit about all three of them on Wikipedia. But I would like the opinion of some experienced users. More specifically I would like to know:

(i) What are the main differences between the three implementations (e.g.: What are they best at? Is any of them used only for specific purposes and might therefore not be suited for specific tasks?)?

(ii) Is there an obvious choice either based on the fact that I will be using ACT-R or based on general reasons?


As this could be interpreted as a subjective question I checked What topics can I ask about here and What types of questions should I avoid asking? and if I read correctly it should not qualify as forbidden fruit.

Musso answered 2/8, 2014 at 6:28 Comment(5)
Stackoverflow is best for actual programming problems. Not so good for general tool comparisons. If you want to know which Lisps are best used for ACT-R, probably best to read the ACT-R documentation and/or ask the support for ACT-R. With a little research you can find it out. Wikipedia is not relevant.Blinni
Ok. I based my decision to ask this question on the line "[...] but if your question generally covers... [...] software tools commonly used by programmers; and is a practical, answerable problem that is unique to software development... then you're in the right place to ask your question!" I considered it practical and answerable but you might be right.Musso
@Musso While this is an interesting question, I agree with Rainer that it's probably off topic. It is about programming tools, and thus might make for a good discussion in chat, but it's probably too broad, and if you ask about things like "what they're best at" you're quite easily into the "primarily opinion-based" realm. This might be better on the software recommendation beta site, or comp.lang.lisp, or #lisp, or lispforum.Pistachio
@Musso But, I will mention that I used ACT-R a few years ago, and as I recall, we ran without much trouble under LispWorks and MCL (MCL is now defunct, but ACT-R might work fine with Closure CL).Pistachio
@JoshuaTaylor: such questions may also asked on reddit.com/r/lisp . But ACL-R specific questions are best asked on the ACT-R mailing list: act-r.psy.cmu.edu/mailing-listBlinni
P
28

I wrote a moderately-sized application and ran it in SBCL, CCL, ECL, CLISP, ABCL, and LispWorks. For my application, SBCL is far and away the fastest, and it's got a pretty good debugger. It's a bit strict about some warnings--you may end up coding in a slightly more regimented way, or turn off one or more warnings.

I agree with Sylwester: If possible, write to the standard, and then you can run your code in any implementation. You'll figure out through testing which is best for your project.

Since SBCL compiles so agressively, once in a while the stacktrace in the debugger is less informative than I'd like. This can probably be controlled with parameters, but I just rerun the same code in one of the other implementations. ABCL has an informative stacktrace, for example, as I recall. (It's also very slow, but if you want real Common Lisp and Java interoperability, it's the only option.)

One of the nice things about Common Lisp is how many high-quality implementations there are, most of them free.

For informal use--e.g. to learn Common Lisp, CCL or CLISP may be a better choice than SBCL.

I have never tried compiling to C using ECL. It's possible that it would beat SBCL on speed for some applications. I have no idea.

CLISP and LispWorks will not handle arbitrarily long argument lists (unless that's been fixed in the last couple of years, but I doubt it). This turned out to be a problem with my application, but would not be a problem for most code.

Doesn't ACT-R come out of Carnegie Mellon? What do its authors use? My guess would be CMUCL or SBCL, which is derived from CMUCL. (I only tried CMUCL briefly. Its interpreter is very slow, but I assume that compiled code is very fast. I think that most people choose SBCL over CMUCL, however.)

(It's possible that this question belongs on Programmers.SE.)

Ptosis answered 5/8, 2014 at 4:51 Comment(1)
I've been getting regular upvotes for this answer recently. I'm glad that folks find it useful, and upvotes are always nice, but I'm uncomfortable with the fact that I haven't used Common Lisp for several years, so I don't know whether my remarks are accurate for current versions of these implementations.Ptosis
W
8

In general, SBCL is the default choice among open-source Lisps. It is solid, well-supported, produces fast code, and provides many goodies beyond what the standard mandates (concurrency primitives, profiling, etc.) Another implementation with similar properties is CCL.

CLISP is more suitable if you're not an engineer, or you want to quickly show Lisp to someone non-engineer. It's a pretty basic implementation, but quick to get running and user-friendly. A Lisp-calculator :)

ECL's major selling point is that it's embeddable, i.e. it is rather easy to make it work inside some C application, like a web-server etc. It's a good choice for geeks, who want to explore solutions on the boundary of Lisp and the outside world. If you're not intersted in such use case I wouldn't recommend you to try it, especially since it is not actively supported, at the moment.

Welty answered 2/8, 2014 at 9:56 Comment(4)
Unfortunately most of you write is subjective and open for discussion. None of that is actually helpful, from the perspective of some ACT-R user, whose requirements we don't know. So above adds not much information in addition to the Wikipedia articles the person who asks this question claims to have read.Blinni
@RainerJoswig to some extent you're right, although, there are objective facts listed here, like the availability/lack of support, or concurrency capabilitiesWelty
-1 Basic implementation, lisp-calculator? CLISP is quite mature realization. It's also more portable then SBCL. Last time when I tested SBCL on windows, it failed to setup quicklisp (or maybe even work under SLIME...). While I program under Linux it's OK, but not so many people use Linux. Viaweb was written with CLISP. And personally, I love that it CLISP compiles things to byte-code, sometimes portability is more valuable than speed.Hoke
@mark Well, SBCL should work fine on Windows (thread support was fully merged some time ago). I'm not sure though, as I'm not using it there. Speaking about CLISP, can you run Hunchentoot in multi-threaded mode in it on Windows? That would be a real test of its maturity there. I'd say that now SBCL is at least as much portable. Also, Viaweb was written a decade ago, a lot of things has changed since then...Welty
L
8

Their names, their bugs and their non standard additions (using them will lock you in)

I use CLISP as REPL and testing during dev and usually SBCL for production. ECL i've never used.

I recommend you test your code with more than one implementation.

Licence answered 2/8, 2014 at 13:54 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.