Treffer: A Low-Footprint Java-to-Native Compilation Scheme Using Formal Methods

Title:
A Low-Footprint Java-to-Native Compilation Scheme Using Formal Methods
Contributors:
System and Networking for Portable Objects Proved to be Safe (POPS), Laboratoire d'Informatique Fondamentale de Lille (LIFL), Université de Lille, Sciences et Technologies-Institut National de Recherche en Informatique et en Automatique (Inria)-Université de Lille, Sciences Humaines et Sociales-Centre National de la Recherche Scientifique (CNRS)-Université de Lille, Sciences et Technologies-Institut National de Recherche en Informatique et en Automatique (Inria)-Université de Lille, Sciences Humaines et Sociales-Centre National de la Recherche Scientifique (CNRS)-Centre Inria de l'Université de Lille, Institut National de Recherche en Informatique et en Automatique (Inria), Université de Lille, Sciences et Technologies-Institut National de Recherche en Informatique et en Automatique (Inria)-Université de Lille, Sciences Humaines et Sociales-Centre National de la Recherche Scientifique (CNRS), Environments for Verification and Security of Software (EVEREST), Centre Inria d'Université Côte d'Azur, Institut National de Recherche en Informatique et en Automatique (Inria)-Institut National de Recherche en Informatique et en Automatique (Inria), GemAlto Research Labs, GEMALTO (GEMALTO), Springer-Verlag
Source:
In Seventh Smart Card Research and Advanced Application IFIP Conference (CARDIS'06) ; https://inria.hal.science/inria-00113758 ; In Seventh Smart Card Research and Advanced Application IFIP Conference (CARDIS'06), Apr 2006, Tarragona, Spain
Publisher Information:
CCSD
Publication Year:
2006
Collection:
HAL Université Côte d'Azur
Document Type:
Konferenz conference object
Language:
English
Rights:
info:eu-repo/semantics/OpenAccess
Accession Number:
edsbas.A3436FF
Database:
BASE

Weitere Informationen

Ahead-of-Time and Just-in-Time compilation are common ways to improve runtime performances of restrained systems like Java Card by turning critical Java methods into native code. However, native code is much bigger than Java bytecode, which severely limits or even forbids these practices for devices with memory constraints. In this paper, we describe and evaluate a method for reducing natively-compiled code by suppressing runtime exception check sites, which are emitted when compiling bytecodes that may potentially throw runtime exceptions. This is made possible by completing the Java program with JML annotations, and using a theorem prover in order to formally prove that the compiled methods never throw runtime exceptions. Runtime exception check sites can then safely be removed from the generated native code, as it is proved they will never be entered. We have experimented our approach on several card-range and embedded Java applications, and were able to remove almost all the exception check sites. Results show memory footprints for native code that are up to 70% smaller than the non-optimized version, and sometimes as low than 115% the size of the Java bytecode when compiled for ARM thumb.