Lune

ASE2022顶会

Compiler Testing using Template Java Programs

Zhiqiang Zang, Nathan Wiatrek, Milos Gligoric, August Shi

摘要

We present JAttack, a framework that enables template-based testing for compilers. Using JAttack, a developer writes a template program that describes a set of programs to be generated and given as test inputs to a compiler. Such a framework enables developers to incorporate their domain knowledge on testing compilers, giving a basic program structure that allows for exploring complex programs that can trigger sophisticated compiler optimizations. A developer writes a template program in the host language (Java) that contains holes to be filled by JAttack. Each hole, written using a domain-specific language, constructs a node within an extended abstract syntax tree (eAST). An eAST node defines the search space for the hole, i.e., a set of expressions and values. JAttack generates programs by executing templates and filling each hole by randomly choosing expressions and values (available within the search space defined by the hole). Additionally, we introduce several optimizations to reduce JAttack's generation cost. While JAttack could be used to test various compiler features, we demonstrate its capabilities in helping test just-in-time (JIT) Java compilers, whose optimizations occur at runtime after a sufficient number of executions. Using JAttack, we have found six critical bugs that were confirmed by Oracle developers. Four of them were previously unknown, including two unknown CVEs (Common Vulnerabilities and Exposures). JAttack shows the power of combining developers' domain knowledge (via templates) with random testing to detect bugs in JIT compilers.

问 Lune

几分钟读透这篇 Paper,不用再花一下午。

Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。

已有 8 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。

可以从这些问题问起

Lune 可以查阅

全文 · 引用它的顶会 Paper · 相关的 Paper

获取答案

免费开始,无需绑卡

脉络

  • The Mutators Reloaded: Fuzzing Compilers with Large Language Model Generated Mutation Operators 引用了 Random testing for C and C++ compilers with YARPGen
  • Finding Compiler Bugs through Cross-Language Code Generator and Differential Testing 引用了 The Mutators Reloaded: Fuzzing Compilers with Large Language Model Generated Mutation Operators
  • Finding Compiler Bugs through Cross-Language Code Generator and Differential Testing 引用了 Java JIT Testing with Template Extraction
  • Finding Compiler Bugs through Cross-Language Code Generator and Differential Testing 引用了 Random testing for C and C++ compilers with YARPGen
  • Java JIT Testing with Template Extraction 引用了 A Generative and Mutational Approach for Synthesizing Bug-Exposing Test Cases to Guide Compiler Fuzzing
  • Java JIT Testing with Template Extraction 引用了 Random testing for C and C++ compilers with YARPGen
  • A Generative and Mutational Approach for Synthesizing Bug-Exposing Test Cases to Guide Compiler Fuzzing 引用了 Fuzzing JavaScript Engines with Aspect-preserving Mutation
它引用的引用它的从左到右按年份排列,引用越多,位置越高。

引用它的顶会 Paper8

  1. Learning Deep Semantics for Test CompletionPengyu Nie, Rahul Banerjee, Junyi Jessy Li, Raymond J. Mooney 等ICSE 2023 · 45 次引用
  2. The Mutators Reloaded: Fuzzing Compilers with Large Language Model Generated Mutation OperatorsXianfei Ou, Cong Li, Yanyan Jiang, Chang XuASPLOS 2024 · 25 次引用
  3. A Generative and Mutational Approach for Synthesizing Bug-Exposing Test Cases to Guide Compiler FuzzingGuixin Ye, Tianmin Hu, Zhanyong Tang, Zhenye Fan 等FSE 2023 · 14 次引用
  4. Java JIT Testing with Template ExtractionZhiqiang Zang, Fu-Yao Yu, Aditya Thimmaiah, August Shi 等FSE 2024 · 8 次引用
  5. Finding Compiler Bugs through Cross-Language Code Generator and Differential TestingQiong Feng, Xiaotian Ma, Ziyuan Feng, Marat Akhin 等OOPSLA 2025 · 2 次引用

它引用的 Paper18

  1. T-Fuzz: Fuzzing by Program TransformationHui Peng, Yan Shoshitaishvili, Mathias PayerS&P 2018 · 326 次引用
  2. Random testing for C and C++ compilers with YARPGenVsevolod Livinskii, Dmitry Babokin, John RegehrOOPSLA 2020 · 140 次引用
  3. ProFuzzer: On-the-fly Input Type Probing for Better Zero-Day Vulnerability DiscoveryWei You, Xueqiang Wang, Shiqing Ma, Jianjun Huang 等S&P 2019 · 130 次引用
  4. Fuzzing JavaScript Engines with Aspect-preserving MutationSoyeon Park, Wen Xu, Insu Yun, Daehee Jang 等S&P 2020 · 126 次引用
  5. Constraint-guided Directed Greybox FuzzingGwangmu Lee, Woochul Shim, Byoungyoung LeeUSENIX Security 2021 · 99 次引用

相关 Paper

  1. FuzzJIT: Oracle-Enhanced Fuzzing for JavaScript Engine JIT CompilerJunjie Wang, Zhiyi Zhang, Shuang Liu, Xiaoning Du 等USENIX Security 2023
  2. Understanding and Finding JIT Compiler Performance BugsZijian Yi, Cheng Ding, August Shi, Milos GligoricOOPSLA 2026
  3. Fuzzing Java Optimizing Compilers with Complex Inter-Class Structures Guided by Heterogeneous Program GraphsShiyu Qiu, Ming Wen, Zifan Xie, Hai JinICSE 2026
  4. JIT-Picking: Differential Fuzzing of JavaScript EnginesLukas Bernhard, Tobias Scharnowski, Moritz Schloegel, Tim Blazytko 等CCS 2022 · 42 次引用
  5. Detecting JVM JIT Compiler Bugs via Exploring Two-Dimensional Input SpacesHaoxiang Jia, Ming Wen, Zifan Xie, Xiaochen Guo 等ICSE 2023 · 21 次引用
黄昏的海面,两侧是细线勾勒的悬崖