An Exploration of SBCL Internals (2020)

v9v | 132 points

I wish other Common Lisp implementations, particularly Clozure CL, documented their internals as well as SBCL does. Apple Silicon support has been a long-standing feature request, but nobody can really work on it besides rme himeself due to the sheer amount of "institutional knowledge" (and time!) it takes to understand CCL's compiler backend then add support for a brand new architecture. SBCL, on the other hand, was able to provide support fairly quick, possibly due to more maintainers, but I also think a big role that played in it was the fact lots of corners of the implementation are documented and it's fairly easily to get a hold of people actively working on the compiler (doug, stassats, et al)

koito17 | 11 days ago

SBCL 25th anniversary workshop is in Vienna thu-fri next week. See you there!

lukego | 11 days ago

My issue prevent me from investing in Lisp is that Erlang gives me a similar REPL which I believe, though I am not a Lisp developer, is a huge value proposition of Lisp. I utilize REPL-based development using Erlang.

The macro narrative is worse in Erlang; but Lisp isn't perfect either in other ways.

The point is, I net out staying on the BEAM. What I like about Lisp is that I think it's a tool that will serve you for the rest of your career, even if you don't use it for production. That's a pretty cool proposition and maybe one day I'll get there. Emacs is a similar tool.

waynesonfire | 11 days ago

> This describes fairly well what we've seen so far. The "lowtag" is those 4 bytes at the end of Lisp objects; also, we're clearly on a 64-bit architecture here, with N_WORD_BITS being 64, 8 of them reserved for the lowtag. It also details various values for the lowtag, the important one being...

Shouldn't that say bits? As 8 bytes would be the whole thing ayways.

Akronymus | 10 days ago

A lot of people write Lisp interpreters, post it to HN and call it a day, but I think compilation is the far more interesting task for a Lisp implementation.

SBCL is great to poke around in and the decompiler’s great. Also check out ABCL, ECL for what compilation to JVM bytecode and C looks like.

anothername12 | 11 days ago

Any explanation for the name?

7373737373 | 11 days ago

  remember that we're on x86 here, which is a big-endian architecture
While I wish this were true, x86 is little-endian.
amock | 11 days ago

It's a bit sad that this ecosystem has fallen out of favor for mainstream software development.

One could have designed OOP like frontends to this fairly easily, and I'm sure there are existing ones. How did Java and C++ take over?

fooker | 11 days ago

[dead]

SEXMCNIGGA42427 | 11 days ago

[dead]

SEXMCNIGGA37103 | 11 days ago

[dead]

SEXMCNIGGA16216 | 11 days ago

[dead]

SEXMCNIGGA20230 | 11 days ago

[dead]

SEXMCNIGGA27980 | 11 days ago

[dead]

SEXMCNIGGA47989 | 11 days ago

[dead]

SEXMCNIGGA3699 | 11 days ago

[dead]

SEXMCNIGGA47274 | 11 days ago

[dead]

SEXMCNIGGA25276 | 11 days ago

[dead]

SEXMCNIGGA35270 | 11 days ago

[dead]

SEXMCNIGGA10290 | 11 days ago

[dead]

SEXMCNIGGA23446 | 11 days ago

[dead]

SEXMCNIGGA22158 | 11 days ago

[dead]

2genders33843 | 11 days ago

[dead]

SEXMCNIGGA31015 | 11 days ago

[dead]

SEXMCNIGGA16263 | 11 days ago

[dead]

SEXMCNIGGA45476 | 11 days ago

[dead]

SEXMCNIGGA6510 | 11 days ago

[dead]

SEXMCNIGGA21671 | 11 days ago

[dead]

SEXMCNIGGA11537 | 11 days ago

[dead]

2genders41830 | 11 days ago

[dead]

SEXMCNIGGA40935 | 11 days ago

[dead]

SEXMCNIGGA27422 | 11 days ago

[dead]

SEXMCNIGGA36943 | 11 days ago

[dead]

SEXMCNIGGA43640 | 11 days ago

[dead]

SEXMCNIGGA1511 | 11 days ago

[dead]

SEXMCNIGGA8507 | 11 days ago

[dead]

2genders23002 | 11 days ago

[dead]

2genders13821 | 11 days ago

[dead]

2genders30467 | 11 days ago

[dead]

2genders39135 | 11 days ago

[dead]

2genders37293 | 11 days ago

[dead]

2genders43359 | 11 days ago

[dead]

2genders44672 | 11 days ago

[flagged]

SEXXMCNIGGGA257 | 11 days ago

[flagged]

indianmilf28586 | 11 days ago

[flagged]

sexmc32071 | 11 days ago

[flagged]

indianmilf40435 | 11 days ago

[flagged]

indianmilf47345 | 11 days ago

[flagged]

sexmc13032 | 11 days ago

[flagged]

sexmc21013 | 11 days ago

[flagged]

2genders9902 | 11 days ago

[flagged]

2genders14511 | 11 days ago

[flagged]

sexmc29060 | 11 days ago

[flagged]

2genders3881 | 11 days ago

[flagged]

2genders23222 | 11 days ago

[flagged]

2genders47511 | 11 days ago

[flagged]

2genders43296 | 11 days ago

[flagged]

2genders33730 | 11 days ago

[flagged]

2genders14350 | 11 days ago

[flagged]

SEXMCNIGGA4930 | 11 days ago

[flagged]

2genders13015 | 11 days ago

[flagged]

2genders14206 | 11 days ago

[flagged]

SEXMCNIGGA41391 | 11 days ago

[flagged]

2genders37480 | 11 days ago

[flagged]

2genders14350 | 11 days ago

[flagged]

SEXMCNIGGA843 | 11 days ago

[flagged]

SEXMCNIGGA12537 | 11 days ago

[flagged]

SEXMCNIGGA23281 | 11 days ago

[flagged]

SEXMCNIGGA34943 | 11 days ago

[flagged]

SEXMCNIGGA9643 | 11 days ago

[flagged]

SEXMCNIGGA28326 | 11 days ago

[flagged]

SEXMCNIGGA8415 | 11 days ago

[flagged]

SEXMCNIGGA45121 | 11 days ago

[flagged]

SEXMCNIGGA49122 | 11 days ago

[flagged]

SEXMCNIGGA34495 | 11 days ago

[flagged]

SEXMCNIGGA46072 | 11 days ago

[flagged]

SEXMCNIGGA33882 | 11 days ago

[flagged]

SEXMCNIGGA17675 | 11 days ago

[flagged]

SEXMCNIGGA16026 | 11 days ago

[flagged]

SEXMCNIGGA24801 | 11 days ago

[flagged]

2genders5140 | 11 days ago

[flagged]

2genders3467 | 11 days ago

[flagged]

2genders30540 | 11 days ago

[flagged]

2genders43296 | 11 days ago

[flagged]

SEXMCNIGGA28175 | 11 days ago

[flagged]

2genders21574 | 11 days ago

[flagged]

2genders3548 | 11 days ago

[flagged]

SEXMCNIGGA42604 | 11 days ago

[flagged]

SEXMCNIGGA30775 | 11 days ago

[flagged]

SEXMCNIGGA39313 | 11 days ago

[flagged]

SEXMCNIGGA40368 | 11 days ago