Tech News
← Back to articles

Erlang ARM32 JIT is born

read original related products more articles

A blog series recounting our adventures in the quest to port the BEAM JIT to the ARM32-bit architecture.

This work is made possible thanks to funding from the Erlang Ecosystem Foundation and the ongoing support of its Embedded Working Group.

The Erlang ARM32 JIT is born! ​

This week we finally achieved our first milestone in developing the ARM32 JIT. We executed our first Erlang function through JITted ARM32 machine code!

shell ~/arm32-jit$ qemu-arm -L /usr/arm-linux-gnueabihf ./otp/RELEASE/erts-15.0/bin/beam.smp -S 1:1 -SDcpu 1:1 -SDio 1 -JDdump true -JMsingle true -- -root /home/arm32-jit/otp/RELEASE -progname erl -home /home ~/arm32-jit$ echo $? 42

The BEAM successfully runs and terminates with error code 42! That 42 comes from an Erlang function, just-in-time compiled by our ARM32 JIT!

Announcement is done! All code is available at https://github.com/stritzinger/otp/tree/arm32-jit

Keep reading for a lot of interesting details!

The first piece of Erlang code ​

erlang - module ( hello ). - export ([ start / 2 ]). start (_BootMod, _BootArgs) -> halt ( 42 , [{ flush , false }]).

... continue reading