Automatic Recovery of Fine-grained Compiler Artifacts at the Binary Level
Yufei Du, Ryan Court, Kevin Z. Snow, Fabian Monrose
Abstract
Identifying a binary's compiler configuration enables developers and analysts to locate potential security issues caused by optimization side-effects, identify binary clones, and build compatible binary patches. Existing work focuses on identifying compiler family, version and optimization level of a binary using semantic features and deep learning techniques. Unfortunately, in practice, binaries are an amalgamation of objects and functions that can be compiled at different optimization levels with a variety of individual, fine-grained, optimizations that may be applied depending on the structure of the code. Hence, rather than recovering high-level artifacts, i.e., compiler family, version, and optimization level, we explore the recovery of individual, fine-grained, optimization passes for each function in a binary. To do so, we develop an approach using specially crafted features alongside intuitive and understandable machine learning models. Our evaluation on 15 popular open-source repositories shows that our approach compares favorable with the state-of-theart deep learning approach in compiler family, compiler version and optimization level identification. For finegrained optimization passes, our evaluation on 149,814 functions from 552 binaries in four popular open-source repositories shows that our approach achieves an average F-1 score of 92.1% for all optimization passes and an average F-1 score of 89.8% for optimization passes that could have negative impacts on security. Moreover, our approach includes experimental support for dynamic feature extraction via binary emulation, and our results shows that such features offer promising potential in improving the accuracy of optimization pass identification.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 06c6a190-e32c-4960-883b-4a057307eb2fCited by top-tier papers2
- Improving Security Tasks Using Compiler Provenance Information Recovered At the Binary-LevelYufei Du, Omar Alrawi, Kevin Z. Snow, Manos Antonakakis et al.CCS 2023 · 8 citations
- Enhancing Function Name Prediction using Votes-Based Name Tokenization and Multi-task LearningXiaoling Zhang, Zhengzi Xu, Shouguo Yang, Zhi Li et al.FSE 2024 · 5 citations
Builds on3
- Automating Patching of Vulnerable Open-Source Software Versions in Application BinariesRuian Duan, Ashish Bijlani, Yang Ji, Omar Alrawi et al.NDSS 2019 · 63 citations
- Dead Store Elimination (Still) Considered HarmfulZhaomo Yang, Brian Johannesmeyer, Anders Trier Olesen, Sorin Lerner et al.USENIX Security 2017 · 37 citations
- Not so fast: understanding and mitigating negative impacts of compiler optimizations on code reuse gadget setsMichael D. Brown, Matthew Pruett, Robert Bigelow, Girish Mururu et al.OOPSLA 2021 · 11 citations
Related papers
- Improving Binary Code Similarity Transformer Models by Semantics-Driven Instruction DeemphasisXiangzhe Xu, Shiwei Feng, Yapeng Ye, Guangyu Shen et al.ISSTA 2023 · 25 citations
- DeepBinDiff: Learning Program-Wide Code Representations for Binary DiffingYue Duan, Xuezixiang Li, Jinghan Wang, Heng YinNDSS 2020
- When Coding Style Survives Compilation: De-anonymizing Programmers from Executable BinariesAylin Caliskan, Fabian Yamaguchi, Edwin Dauber, Richard E. Harang et al.NDSS 2018 · 125 citations
- A Deep Dive into Function Inlining and its Security Implications for ML-based Binary AnalysisOmar Abusabha, Jiyong Uhm, Tamer Abuhmed, Hyungjoon KooNDSS 2026 · 3 citations
- Revisiting Optimization-Resilience Claims in Binary Diffing Tools: Insights from LLVM Peephole Optimization AnalysisXiaolei Ren, Mengfei Ren, Yu Lei, Jiang MingFSE 2025
