z-logo
open-access-imgOpen Access
Analysis of WebAssembly as a Strategy to Improve JavaScript Performance on IoT Environments
Author(s) -
Fernando Luis Oliveira,
Júlio C. B. Mattos
Publication year - 2020
Language(s) - English
Resource type - Conference proceedings
DOI - 10.5753/sbesc_estendido.2020.13102
Subject(s) - javascript , computer science , unobtrusive javascript , benchmark (surveying) , context (archaeology) , rich internet application , operating system , embedded system , programming language , paleontology , geodesy , biology , geography
JavaScript language (JS) has been widely used in recent years applied to browsers-context. Yet JS is being applied to other backgrounds such as server-side programming, mobile applications, games, robotics, and the Internet of Things (IoT). JavaScript is suitable for programming IoT devices due to eventdriven oriented architecture. However, it is an interpreted language, so it has a lower performance than a compiled language. This paper assesses the use of WebAssembly as a strategy to improve the performance of JavaScript applications in the IoT environment. The experiments were performed on a Raspberry Pi using the Ostrich Benchmark Suite. We run the algorithms in JavaScript, WebAssembly, and C language while collecting data about device resource consumption. Our results showed that JavaScript performance could be improved by 39.81% in terms of execution time, a tiny gain in memory usage, and reduced battery consumption by 39.86% when using WebAssembly.

The content you want is available to Zendy users.

Already have an account? Click here to sign in.
Having issues? You can contact us here