Native code compilation of Erlang's bit syntax

  • Authors:
  • Per Gustafsson;Konstantinos Sagonas

  • Affiliations:
  • Uppsala University, Sweden;Uppsala University, Sweden

  • Venue:
  • Proceedings of the 2002 ACM SIGPLAN workshop on Erlang
  • Year:
  • 2002

Quantified Score

Hi-index 0.00

Visualization

Abstract

Erlang's bit syntax caters for flexible pattern matching on bit streams (objects known as binaries). Binaries are nowadays heavily used in typical Erlang applications such as protocol programming, which in turn has created a need for efficient support of the basic operations on binaries.To this effect, we describe a scheme for efficient native code compilation of Erlang's bit syntax. The scheme relies on partial translation for avoiding code explosion, and improves the performance of programs manipulating binaries by translating frequently occurring instances of BEAM instructions into native code via an intermediate translation to instructions of a register transfer language. Our performance evaluation shows that in a HiPE-enabled Erlang/OTP system, the obtained speedups are often significant.