Specialization of generic array accesses after inlining (system description)

Ryohei Tokuda, Eijiro Sumii, Akinori Abe

Research output: Contribution to journalConference articlepeer-review

Abstract

We have implemented an optimization that specializes type-generic array accesses after inlining of polymorphic functions in the native-code OCaml compiler. Polymorphic array operations (read and write) in OCaml require runtime type dispatch because of ad hoc memory representations of integer and float arrays. It cannot be removed even after being monomorphized by inlining because the intermediate language is mostly untyped. We therefore extended it with explicit type application like System F (while keeping implicit type abstraction by means of unique identifiers for type variables). Our optimization has achieved up to 21% speed-up of numerical programs.

Original languageEnglish
Pages (from-to)45-53
Number of pages9
JournalElectronic Proceedings in Theoretical Computer Science, EPTCS
Volume241
DOIs
Publication statusPublished - 2017 Feb 7
Event2015 ML Family / OCaml Users and Developers Workshops, ML 2015 - Vancouver, Canada
Duration: 2015 Sept 32015 Sept 4

Fingerprint

Dive into the research topics of 'Specialization of generic array accesses after inlining (system description)'. Together they form a unique fingerprint.

Cite this