Write a Blog >>
Scala 2017
Sun 22 - Mon 23 October 2017 Vancouver, Canada
co-located with SPLASH 2017
Sun 22 Oct 2017 14:00 - 14:30 at Regency C - Compilation Chair(s): Paolo G. Giarrusso

Functional collection combinators are a neat and widely accepted data processing abstraction. However, their generic nature results in high abstraction overheads – Scala collections are known to be notoriously slow for typical tasks. We show that proper optimizations in a JIT compiler can widely eliminate overheads imposed by these abstractions. Using the open-source Graal JIT compiler, we achieve speedups of up to 20x on collection workloads compared to the standard HotSpot C2 compiler. Consequently, a sufficiently aggressive JIT compiler allows the language compiler, such as Scalac, to focus on other concerns.

In this paper, we show how optimizations, such as inlining, polymorphic inlining, and partial escape analysis, are combined in Graal to produce collections code that is optimal with respect to manually written code, or close to optimal. We argue why some of these optimizations are more effectively done by a JIT compiler. We then identify specific use-cases that most current JIT compilers do not optimize well, warranting special treatment from the language compiler.

Sun 22 Oct

scala-2017-papers
13:30 - 15:00: Scala 2017 - Compilation at Regency C
Chair(s): Paolo G. GiarrussoUniversity of Tübingen, Germany
scala-2017-papers13:30 - 14:00
Talk
DOI
scala-2017-papers14:00 - 14:30
Talk
Aleksandar ProkopecOracle Labs, David LeopoldsederJohannes Kepler University Linz, Gilles DuboscqOracle Labs, Thomas WuerthingerOracle Labs
DOI
scala-2017-papers14:30 - 15:00
Talk
Franck CassezMacquarie University, Australia, Anthony SloaneMacquarie University
DOI