4 ms·
> Unfortunately, BEAM VM is very slow compared to multiple other languages including Go. for cpu bound tasks? sure. but we are talking in the context of networ
by cultofmetatron 2y ago
> Unfortunately, BEAM VM is very slow compared to multiple other languages including Go.
for cpu bound tasks? sure. but we are talking in the context of networking. elixir is going to absolutely smoke go for applications requiring a lot of simultaneous connections. We can already see it in actionable vs phoenix channels. channels supports a magnitude order more simultaneous websocket connections per machine.
ps: libraries like rustler exist. you can take the cpu intensive stuff and offload it to a module written in rust when you really need to squeeze some perf out.
- johnisgood 2y agoAnd for CPU-bound tasks one could use NIFs (usually better) or Ports if absolutely necessary. https://stackoverflow.com/questions/42035912/running-c-code-in-elixir-erlang-ports-or-nifs https://stackoverflow.com/questions/42035912/running-c-code-...
- dataviz1000 2y agoElixir lacks the fine grain control for optimizing I/O which Go provides. Moreover, a bit torrent client requires CPU intensive hash verification, encryption/decryption, and data compression/decompression which will greatly slow down Elixir. You can build a connector to Rust or instead of using slow abstraction layers you can build the thing in Rust if you have the skills. Rather then tell me, you are going to have to build a bit torrent client in Elixir and show me. Otherwise, after my years experience working with an Elixir team, I don't believe you.
- deleted 2y ago[deleted]