Java Decompiler Diversity and its Application to Meta-decompilation

05/21/2020
by   Nicolas Harrand, et al.
0

During compilation from Java source code to bytecode, some information is irreversibly lost. In other words, compilation and decompilation of Java code is not symmetric. Consequently, decompilation, which aims at producing source code from bytecode, relies on strategies to reconstruct the information that has been lost. Different Java decompilers use distinct strategies to achieve proper decompilation. In this work, we hypothesize that the diverse ways in which bytecode can be decompiled has a direct impact on the quality of the source code produced by decompilers. In this paper, we assess the strategies of eight Java decompilers with respect to three quality indicators: syntactic correctness, syntactic distortion and semantic equivalence modulo inputs. Our results show that no single modern decompiler is able to correctly handle the variety of bytecode structures coming from real-world programs. The highest ranking decompiler in this study produces syntactically correct, and semantically equivalent code output for 84 in our dataset. Our results demonstrate that each decompiler correctly handles a different set of bytecode classes. We propose a new decompiler called Arlecchino that leverages the diversity of existing decompilers. To do so, we merge partial decompilation into a new one based on compilation errors. Arlecchino handles 37.6 decompiler. We publish the sources of this new bytecode decompiler.

READ FULL TEXT

page 6

page 8

page 11

research
08/19/2019

The Strengths and Behavioral Quirks of Java Bytecode Decompilers

During compilation from Java source code to bytecode, some information i...
research
08/01/2020

The test set for the TransCoder system

The TransCoder system translates source code between Java, C++, and Pyth...
research
11/09/2020

Pointing to Subwords for Generating Function Names in Source Code

We tackle the task of automatically generating a function name from sour...
research
08/10/2018

COBOL to Java and Newspapers Still Get Delivered

This paper is an experience report on migrating an American newspaper co...
research
12/18/2022

JEMMA: An Extensible Java Dataset for ML4Code Applications

Machine Learning for Source Code (ML4Code) is an active research field i...
research
06/17/2022

Evaluating the Impact of Source Code Parsers on ML4SE Models

As researchers and practitioners apply Machine Learning to increasingly ...
research
06/09/2022

ESBMC-Jimple: Verifying Kotlin Programs via Jimple Intermediate Representation

In this work, we describe and evaluate the first model checker for verif...

Please sign up or login with your details

Forgot password? Click here to reset