Automated Conformance Testing for JavaScript Engines via Deep Compiler Fuzzing

04/15/2021
by   Guixin Ye, et al.
0

JavaScript (JS) is a popular, platform-independent programming language. To ensure the interoperability of JS programs across different platforms, the implementation of a JS engine should conform to the ECMAScript standard. However, doing so is challenging as there are many subtle definitions of API behaviors, and the definitions keep evolving. We present COMFORT, a new compiler fuzzing framework for detecting JS engine bugs and behaviors that deviate from the ECMAScript standard. COMFORT leverages the recent advance in deep learning-based language models to automatically generate JS test code. As a departure from prior fuzzers, COMFORT utilizes the well-structured ECMAScript specifications to automatically generate test data along with the test programs to expose bugs that could be overlooked by the developers or manually written test cases. COMFORT then applies differential testing methodologies on the generated test cases to expose standard conformance bugs. We apply COMFORT to ten mainstream JS engines. In 200 hours of automated concurrent testing runs, we discover bugs in all tested JS engines. We had identified 158 unique JS engine bugs, of which 129 have been verified, and 115 have already been fixed by the developers. Furthermore, 21 of the Comfort-generated test cases have been added to Test262, the official ECMAScript conformance test suite.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
12/07/2020

Exposing Bugs in JavaScript Engines through Test Transplantation and Differential Testing

Context. JavaScript is a popular programming language today with several...
research
08/22/2021

Bugs4Q: A Benchmark of Real Bugs for Quantum Programs

Realistic benchmarks of reproducible bugs and fixes are vital to good ex...
research
08/31/2023

Effective Test Generation Using Pre-trained Large Language Models and Mutation Testing

One of the critical phases in software development is software testing. ...
research
02/14/2022

Practical Testing of a C99 Compiler Using Output Comparison

A simple technique is presented for testing a C99 compiler, by compariso...
research
02/15/2021

JEST: N+1-version Differential Testing of Both JavaScript Engines and Specification

Modern programming follows the continuous integration (CI) and continuou...
research
09/09/2022

Compiler Testing using Template Java Programs

We present JAttack, a framework that enables template-based testing for ...
research
12/20/2021

FuSeBMC v.4: Smart Seed Generation for Hybrid Fuzzing

FuSeBMC is a test generator for finding security vulnerabilities in C pr...

Please sign up or login with your details

Forgot password? Click here to reset