Ahead-of-time compilation of WebAssembly using Eclipse OMR

Loading...
Thumbnail Image

Date

2020

Journal Title

Journal ISSN

Volume Title

Publisher

University of New Brunswick

Abstract

The variety of available computing machines limits the portability of programs. The primary hindrance is that programs are designed towards an interface espoused by a machine. However, other systems can run programs designed for a different interface using a virtual machine. An approach for enhancing program portability is to design programs for a virtual machine with a simplified interface. For example, programs written in the C language can be compiled to theWebAssembly code format. WebAssembly was chosen for this research due to its simple syntax, static structure, recent interest from the research community and existing implementation with Eclipse OMR. The development of language virtual machines often includes the implementation of an interpreter and a compiler. While interpreters primarily provide a sound implementation described by a language specification, compilers have the additional requirement of generating optimized machine code. This task can be facilitated using the Eclipse OMR toolkit for language runtime construction. The relocation infrastructure and shared code cache are two features for aheadof- time (AOT) compilation in Eclipse OMR and are currently in development. The research in the thesis shows an implementation of these two Eclipse OMR AOT compilation features in a language runtime. The WebAssembly AOT compiler, called Wabtaot, that is presented in this thesis leverages Eclipse OMR relocation infrastructure and shared code cache features. The comparison of Wabtaot with WebAssembly runtimes implemented using other compiler technologies demonstrates that the implementation of a language runtime using Eclipse OMR AOT compiler framework is viable and its performance is competitive. Relative to Wasmjit-OMR, a Web- Assembly compiler implemented using Eclipse OMR just-in-time compiler features, Wabtaot significantly reduces execution time for repeated execution ofWebAssembly modules.

Description

Keywords

Citation