Unboxed compilation of floating point arithmetic in a dynamically typed language environment

  • Authors:
  • Tobias Lindahl;Konstantinos Sagonas

  • Affiliations:
  • Computing Science, Dept. of Information Technology, Uppsala University, Sweden;Computing Science, Dept. of Information Technology, Uppsala University, Sweden

  • Venue:
  • IFL'02 Proceedings of the 14th international conference on Implementation of functional languages
  • Year:
  • 2002

Quantified Score

Hi-index 0.00

Visualization

Abstract

In the context of the dynamically typed concurrent functional programming language ERLANG, we describe a simple static analysis for identifying variables containing floating point numbers, how this information is used by the BEAM compiler, and a scheme for efficient (just-in-time) compilation of floating point bytecode instructions to native code. The attractiveness of the scheme lies in its implementation simplicity. It has been fully incorporated in Erlang/OTP R9, and improves the performance of ERLANG programs manipulating floats considerably. We also show that by using this scheme, Erlang/OTP, despite being an implementation of a dynamically typed language, achieves performance which is competitive with that of state-of-the-art implementations of strongly typed strict functional languages on floating point intensive programs.