The BEAM Book – A Description of the Erlang RTS and the Virtual Machine BEAM
github.com
github.com
https://github.com/cloudozer/ling
An impressively done book on BEAM instruction sets:
https://github.com/cloudozer/ling/tree/master/doc
There is even a handy dandy online instruction set completion search:
Then they cancelled it.
It was then picked up by Pragmatic Programmers, but they wound up cancelling it too.
In any case, Erik told me a couple of weeks ago at Erlang & Elixir Factory that he'd be looking to get it out himself online by -- or around, I forget -- summertime, so it's nice to see he did this now, even if it means I lose the betting pool (I kid).
At any rate I'm glad to see it's going to have a life independently. This looks great.
You've given me a bit of reading material for my train-ride for the next few days, so thank you!
It got so many things right, it was ahead of its time. Is already stable and is serving critical pieces of infrastructure around the world for many years.
It is also worth pointing out that the BEAM was designed with one purpose and that is to run Erlang. Other languages can be implemented on it, but they sort of have to adapt to the Erlang way. The downside there is that the BEAM official specification is its ... implementation. And reasons for implementation were written down. You can catch Joe Armstrong or Robert Virding at one of the events like Erlang Factory and they'll happily tell you why things works the way they do.
Things I like about this VM:
* Process isolation : sounds like magic but it's true you can have millions of processes _and_ all having isolated heaps.
* Dynamic tracing : connect to a node and start tracing any function
* Hot code loading : don't feel like stopping a critical production server to add an extra log statement or upgrade it, don't have to. Can just load the code.
* Like you mentioned, GC. It will never "stop the world". When process ran and exited, the whole block can be reclaimed quickly and efficiently.
Anyway using BEAM with Erlang, Elixir, LFE or other languages, feels a bit like using a secret weapon that very few know about.
That's a very elegant solution to various CPU hogging problems that would otherwise be extremely hard to solve in userland.
This will be a very valuable resource. Thanks so much to Erik!