thojanssens1

thojanssens1

JIT in Erlang – what does it mean for Elixir?

JIT is coming to Erlang. Will that then also benefit Elixir apps?

If I understand correctly, JIT allows to improve performance of the application; i.e. execution time?

How do we use JIT in Elixir?

Most Liked

kip

kip

ex_cldr Core Team

With CLDR release 39 out next month I am on my usual bi-annual compatibility and maintenance cycle for the ex_cldr libraries and decided to see if some critical code will benefit from the JIT compiler in OTP 24.

This simple example is formatting a number which is a complex operation given the flexibility of the formatting system. Overall the performance is about twice as fast for this function which is a big win.

With the JIT (OTP 24.0-rc0)

Name                                            ips        average  deviation         median         99th %
:erlang.float_to_binary                   7663.86 K       0.130 μs  ±2026.91%           0 μs           1 μs
Float to_string                            976.30 K        1.02 μs  ±7209.48%           1 μs           2 μs
Number to_string preformatted options      183.40 K        5.45 μs   ±416.76%           4 μs          15 μs
Number to_string                            56.33 K       17.75 μs   ±348.13%          15 μs          65 μs

Without the JIT (OTP 23.2.2)

Name                                            ips        average  deviation         median         99th %
:erlang.float_to_binary                   6213.10 K       0.161 μs  ±1823.26%           0 μs           1 μs
Float to_string                            533.39 K        1.87 μs  ±2067.68%           2 μs           2 μs
Number to_string preformatted options       89.48 K       11.18 μs   ±166.50%          10 μs          22 μs
Number to_string                            23.98 K       41.70 μs    ±64.88%          40 μs          69 μs
20
Post #3
ityonemo

ityonemo

I think you don’t do anything (maybe turn on a vm flag) and it just does its thing. Sit back and enjoy a performance gain. The blog article says Jason gets a big speed bump.

Where Next?

Popular in Discussions Top

PragTob
Hello everyone, I know we had quite some threads (read through lots of them) about background job processing but it remains a hotly deba...
New
andre1sk
A big advantage to Elixir is all the distributed goodness but for many applications running on multiple nodes having integrated Etcd, Zoo...
New
blackode
Elixir Upgrading is so Simple in Ubuntu and It worked for me Ubuntu 16.04 git clone https://github.com/elixir-lang/elixir.git cd elixir...
New
MarioFlach
Hello, I want to share a project I’ve been working on for a while: https://github.com/almightycouch/gitgud Background Some time ago I ...
New
mmmrrr
Just saw that dhh announced https://hotwire.dev/ Is it just me or is this essentially live view? :smiley: Although I like the “iFrame-e...
New
arpan
Hello everyone :wave: Today I am very excited to announce a project that I have been working on for almost 3 months now. The project is...
New
WildYorkies
It seems that the more I read, the more I find Elixir users speaking about all the ways that Elixir is not good for x, y, and z use cases...
New
AlexMcConnell
The reason that Rails is as popular as it is is because it’s very easy for relatively inexperienced developers to get a lot of work done....
588 19568 166
New
New
AstonJ
Seen any cool LiveView demos, sample apps or examples? Please post them here! :003:
New

Other popular topics Top

malloryerik
Hi, this is for people who, like me, have had some friction using .html.heex templates in VSCode. The solution seems to be, in a hyphena...
New
Nvim
Anybody knows a comprehensive comparison of Django and Phoenix, thanks for the help. Where are they similar? Where do they differ the m...
New
JeremM34
Hello, how can I check the Phoenix version ? Thanks !
New
shahryarjb
Hello, I have map which I want to convert it to string like this: the map: %{last_name: "tavakkoli", name: "shahryar"} the string I ne...
New
dokuzbir
I want to highlight html closing tags when i click a html tag. That works in .html files but doesnt work for html.eex templates. How can...
New
stefanluptak
Hello everybody, usually, I use a 29" ultra-wide monitor for VSCode which can easily accomodate explorer (files panel) + file with code ...
New
freewebwithme
Using vs code and installed ElixirLS: support and debugger. And I got an error popped up on start up says Failed to run ‘elixir’ comma...
New
romenigld
I am trying to run a deploy with docker and I successfully runned with this command: docker build -t romenigld/blog-prod . but when I t...
New
klo
Got a question about when to concat vs. prepending items to list then reversing to achieve appending. So i know lists boil down to [1 | ...
New
joaquinalcerro
Hi there, I am working with Ecto-Postgresql and I need to call all of the records from a specific table but the table has 40,000 records...
New

We're in Beta

About us Mission Statement