Binary decompilation is fundamental to security tasks such as vulnerability discovery, malware inspection, and executable-only program understanding. Recent LLM-based decompilation methods have shown promising results, but most still follow a single-turn generation paradigm: given assembly code or decompiler-produced pseudo-code, the model generates one output and stops. Consequently, the generated code may appear readable or even compile successfully, yet still deviate from the behavior of the original binary and mislead downstream analysis. This paper presents AutoDecompiler, a decompilation-specialized LLM trained with reinforcement learning for feedback-driven multi-turn binary decompilation. Instead of treating decompilation as one-shot code generation, AutoDecompiler formulates it as an iterative refinement process, where the model revises generated code based on compilation, execution, and input/output testing feedback. To enable this process, we design decompilation-specific rewards that capture code validity, recompilability, execution consistency, and semantic fidelity. We further construct stage-aware diagnostic feedback from compiler errors, execution failures, and failed test cases, and introduce progress-aware trajectory rewarding and turn-aware advantage reweighting to encourage beneficial revisions while suppressing regressions. We train the AutoDecompiler family and evaluate it across different input settings, model scales, and benchmarks. Experimental results show that AutoDecompiler consistently outperforms its single-turn counterparts under the same model size and input setting, achieving clear improvements in behavioral re-executability. These results demonstrate that learning to exploit program feedback with reinforcement learning is an effective direction for improving the functional correctness of LLM-based binary decompilation.


翻译:二元反编译是安全领域的基础任务,例如漏洞发现、恶意软件检测及仅可执行程序理解。近期基于大语言模型的反编译方法已展现出初步成效,但大多仍遵循单轮生成范式:给定汇编代码或反编译器生成的伪代码,模型仅生成一次输出即终止。因此,生成的代码虽可能具备可读性甚至编译成功,却仍可能偏离原始二进制程序的行为,从而误导下游分析。本文提出AutoDecompiler——一种专门针对反编译任务的大语言模型,通过强化学习训练实现反馈驱动的多轮二元反编译。AutoDecompiler将反编译视为迭代精炼过程而非一次性代码生成:模型基于编译、执行及输入/输出测试的反馈持续修订生成的代码。为实现该过程,我们设计了反编译专属奖励机制,涵盖代码有效性、可重编译性、执行一致性及语义保真度。此外,我们根据编译器错误、执行失败及测试用例失败构建了分阶段诊断性反馈,并引入进度感知轨迹奖励与回合感知优势重加权机制,以激励有益改进同时抑制性能退化。我们训练了AutoDecompiler系列模型,并在不同输入设置、模型规模及基准测试中进行了评估。实验结果表明,在相同模型规模与输入设置下,AutoDecompiler始终优于其单轮对应版本,在行为可重执行性方面取得显著提升。这些结果证明,利用强化学习学习利用程序反馈是提升基于大语言模型的二元反编译功能正确性的有效方向。

0
下载
关闭预览

相关内容

代码(Code)是专知网的一个重要知识资料文档板块,旨在整理收录论文源代码、复现代码,经典工程代码等,便于用户查阅下载使用。
LLMS4ALL:大语言模型在各学科科研与应用中的综述
专知会员服务
37+阅读 · 2025年10月4日
多模态大型语言模型:综述
专知会员服务
47+阅读 · 2025年6月14日
利用多个大型语言模型:关于LLM集成的调研
专知会员服务
35+阅读 · 2025年2月27日
ICLR 2025(投稿) | 多模态大语言模型相关论文整理
专知会员服务
28+阅读 · 2024年10月29日
一文速览大语言模型提示最新进展
专知会员服务
82+阅读 · 2023年12月24日
RecInterpreter:架起大语言模型与传统推荐模型的桥梁
专知会员服务
54+阅读 · 2023年11月9日
LLM in Medical Domain: 大语言模型在医学领域的应用
专知会员服务
103+阅读 · 2023年6月17日
多模态预训练模型简述
专知会员服务
115+阅读 · 2021年4月27日
绝对干货!NLP预训练模型:从transformer到albert
新智元
14+阅读 · 2019年11月10日
NLP通用模型诞生?一个模型搞定十大自然语言常见任务
人工智能头条
10+阅读 · 2018年6月29日
国家自然科学基金
0+阅读 · 2017年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
4+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
4+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
VIP会员
最新内容
从采集到决策:美军视角下的战术情报范式重构
专知会员服务
4+阅读 · 今天2:42
《履带式无人地面战车技术发展现状》
专知会员服务
2+阅读 · 今天1:46
《无人机脆弱性利用:网络空间力量的新域》
专知会员服务
2+阅读 · 8月1日
美空军如何将人工智能从战场部署至后方机关
专知会员服务
11+阅读 · 7月31日
《史诗怒火行动:多域前瞻评估》49页报告
专知会员服务
8+阅读 · 7月31日
《英国防部:未来空战系统数字化战略》33页
专知会员服务
5+阅读 · 7月31日
《面向自主飞行网络的智能体人工智能架构》
专知会员服务
8+阅读 · 7月31日
相关VIP内容
LLMS4ALL:大语言模型在各学科科研与应用中的综述
专知会员服务
37+阅读 · 2025年10月4日
多模态大型语言模型:综述
专知会员服务
47+阅读 · 2025年6月14日
利用多个大型语言模型:关于LLM集成的调研
专知会员服务
35+阅读 · 2025年2月27日
ICLR 2025(投稿) | 多模态大语言模型相关论文整理
专知会员服务
28+阅读 · 2024年10月29日
一文速览大语言模型提示最新进展
专知会员服务
82+阅读 · 2023年12月24日
RecInterpreter:架起大语言模型与传统推荐模型的桥梁
专知会员服务
54+阅读 · 2023年11月9日
LLM in Medical Domain: 大语言模型在医学领域的应用
专知会员服务
103+阅读 · 2023年6月17日
多模态预训练模型简述
专知会员服务
115+阅读 · 2021年4月27日
相关基金
国家自然科学基金
0+阅读 · 2017年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
4+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
4+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员