Reproduce “SK2Decompile: LLM-based Two-Phase Binary Decompilation from Skeleton to Skin” on OpenResearch

Turn your favorite coding agents into research agents that review literature, develop hypotheses, and run experiments.

Universal app for Apple silicon and Intel. Requires macOS 11 or later.

About this paper

Hanzhuo Tan, Weihao Li, Xiaolong Tian, Siyi Wang, Jiaming Liu, Jing Li, Yuqun Zhang

SK2 Decompile, developed by a research team including Hanzhuo Tan and Yuqun Zhang, introduces a two-phase Large Language Model-based binary decompiler that overcomes the traditional trade-off between functional correctness and code readability. It achieves approximately 70% re-executability on HumanEval and 60% on MBPP, while also significantly improving structural and semantic readability compared to existing LLM-based decompilers.

Key insights

  • Decomposing the complex decompilation task into separate structural recovery and identifier naming phases enables LLMs to achieve significantly higher functional correctness and readability.
  • An intermediate representation designed as 'obfuscated source code' effectively preserves program structure while abstracting identifier specifics, serving as an optimal information bottleneck for multi-phase translation.
  • Phase-specific reinforcement learning rewards, such as compiler feedback for structural integrity and semantic similarity for identifier quality, are crucial for fine-tuning LLMs to meet distinct, high-level objectives in code generation.

Summary by alphaXiv.

Tip: change arxiv.org to autoarxiv.org in any arXiv abstract link to open the paper here.