Get Started. It's Free
or sign up with your email address
What is SBCL? by Mind Map: What is SBCL?

1. How does it work?

1.1. Compiler

1.1.1. Source -> IR1

1.1.2. IR1 optimizations

1.1.3. IR1 -> IR2

1.1.4. IR2 optimizations (few -- we could do a lot more here, but the gains are generally smaller than working on IR1, so...)

1.1.5. IR2 -> machine code

1.2. Runtime

1.2.1. signal handling

1.2.2. GC

1.2.3. threads

1.3. Worked examples

1.3.1. Adding a new VOP


1.3.3. Adding a new DEFTRANSFORM

2. SBCL is a high performance native compiler for ANSI Common Lisp.

2.1. What is SBCL?

2.1.1. One implementation among many.

2.1.2. ...but the most popular open source implementation!

2.1.3. Open source: public domain / MIT and BSD licenses.

2.1.4. CMU heritage

2.1.5. Current developers

2.1.6. Multiplatform, but best on Linux. OS X ok except for threads. Runs on Windows too, and I know people use it for production there... but Windows is still a second-class citizen. Solaris, *BSD, etc also supported.

2.1.7. Competitive with C and C++ Usually within a small percentage factor, sometimes even better. Benchmark game is bad. What counts is the code you are able to produce. Admittedly newbies need some time to learn what is expensive and what not.

2.1.8. Examples Arithmetic Generic version. Fixnum version. Single-float version. Object instantiation Slot access. Agressive inlining and PE.

2.1.9. Users -- both private and corporate

2.2. What is Common Lisp?

2.2.1. ANSI Standard came out just before Java Does that make it old or not-so-old? CLTl1 & 2 older

2.2.2. Not just Scheme with funny spellings Lisp-2 (or -n) Humans are very good at this sort of contex-sensitivity, it turns out. Even though you can make a silly example like (defun listlist (list) (list list)) in practise being able to name local variables without worrying about shadowing global function names is a boon -- no need for contractions like lst. If you ask me, it's Lisp-4: variables, functions, tags, and blocks. Silly people may also count classes, throw tags, etc -- but they are not lexically scoped entities, so I don't think they count. Operators are either named or LAMBDA-expressions. You never have (((foo))) -- but instead (funcall (funcall (foo))). I think this is a good thing. Hygiene? Nope. I think hygiene is good, and implicit phasing in particular appears to solve actual problems -- but lack of hygiene isn't an issue. Seriously. Lack of implicit phasing... let's not go there right now -- but I can talk about that later to those interested. No CALL/CC -- but UNWIND-PROTECT, and a number of libraries implement CALL/CC via a code-walker. Large standard library. (Think a huge bunch of SRFIs that every single implementation implements.) Native compilation is the typical. Interpreters exist, but everyone qualifies them as exceptions. CLOS and MOP Conditions and restarts Programmable reader The funny names come from older dialects like Interlisp, maclisp, and Zetalisp. Compiler macros

2.2.3. A mudball of strength. Buddha has hairy armpits and laughs!

2.2.4. Libraries: we have a lot of them, and a nice way to install them. Demo Quicklisp. Hunchentoot cl-ppcre cl-javascript cl-opengl