4 ms·
I don't think it's the AST: I think it's the BEAM itself. The intermediate representations used in (and even accepted as input formats by) the compiler are rel
by sigwinch28 6y ago
I don't think it's the AST: I think it's the BEAM itself.
The intermediate representations used in (and even accepted as input formats by) the compiler are relatively unstable, with the exception of the Erlang Abstract Format.
This makes it a great target for other compilers because they don't have to track breaking changes to the intermediate formats, they don't have to worry about generating BEAM bytecode, and they get to take advantage of all optimisations already implemented in erlc (the Erlang compiler).
As an example of recent amazing changes to the BEAM: JIT to x86_64 https://github.com/erlang/otp/pull/2745 https://github.com/erlang/otp/pull/2745