Erlang/OTP R16B Brings Improved Parallelism
Erlang is a general purpose functional programming language with an emphasis on supporting concurrency and real-time distributed systems. Last week saw the release of Erlang R16B, bringing several improvements that bring increased parallelization to various areas of the language's virtual machine.
Erlang is used in several different projects, including distributed databases, communication systems, web servers, and high-frequency trading platforms on Wall Street. Prominent projects or companies using Erlang include GitHub, high-frequency trading, and multiplayer gaming servers (i.e.: Call of Duty).
This new release of Erlang has an extensive list of changes in its release notes, and there are several items to highlight among the improvements. The first is that Erlang virtual machine has improved its internal handling of processes. This allows for parallel reads and writes, which benefits performance by reducing contention during the spawning and terminating of processes.
Port handling has been greatly improved to allow for parallel reads and writes in this area. This is combined with Erlang's new ability to dynamically allocate ports and the raise of the default port limit to 65,536 from 1023. Programmer's should note that one result of the new system is that signals are now truly asynchronously delivered. Previously signals may have had a specific delivery order, but that order can no longer be assumed or relied on. As a result, "...this may cause Erlang programs that have made false assumptions about signal delivery order to fail even though they previously succeeded."
The Erlang Run-Time System (ERTS) has been improved to support loading code in a non-blocking manner. Previously a single thread model was used to load Erlang modules, which halted the VM during the loading process. In this release Erlang supports non-blocking operations so that the code can be loaded without stopping code execution. This should improve the performance of the VM when running on an SMP system during the loading of new modules.
The new release supports Windows with precompiled binaries for both 32 and 64 bit platforms. Other platforms are supported via their appropriate package managers. The source code can be browsed on GitHub. (R16B Source archives are also ready for download.)
Keith Adams Dec 06, 2013