← 研踪 PaperTrailarXiv:2608.05521 · v2
Reasoning from Traces: Divergence-Guided Agentic Repair of WebAssembly Discrepancies
首次提交 2026-08-06 09:52
版本更新 2026-10-28 14:32
雷达观测 2026-10-30 10:22
摘要
WebAssembly (Wasm) promises seamless reuse of C/C++ codebases as portable, efficient, sandboxed binaries for execution on the Web. In practice, however, this promise often falls short: recent studies show that cross-compiling C/C++ source to Wasm and native binaries frequently produces runtime discrepancies due to differences in library implementation and compiler bugs. Since the root causes are platform-level and hidden beneath the source code, even state-of-the-art LLM-based coding agents can struggle to diagnose and repair these discrepancies. In this paper, we present WasmMend, the first system for automatically repairing Native-Wasm functional discrepancies. WasmMend transforms open-ended debugging into a two-stage process. First, a novel differential trace analysis approach localizes the function where Wasm and native executions first diverge. Second, guided by this localization, a multi-agent system coordinates separate agents to interpret platform-specific behavior and synthesizes patch plans. Experiments on discrepancies from real-world C/C++ projects show that, across five backbone models, WasmMend achieves a fix rate of up to 84.8%, with average gains of at least 37.2 percentage points over the evaluated open-source coding agent baselines, while maintaining comparable cost.
观测到的版本
相邻记录可能跳过中间版本;首次发现 v2 及以上也会标为版本更新。
v2 · 2026-10-28 14:32 · 最新观测版本
Reasoning from Traces: Divergence-Guided Agentic Repair of WebAssembly Discrepancies
WebAssembly (Wasm) promises seamless reuse of C/C++ codebases as portable, efficient, sandboxed binaries for execution on the Web. In practice, however, this promise often falls short: recent studies show that cross-compiling C/C++ source to Wasm and native binaries frequently produces runtime discrepancies due to differences in library implementation and compiler bugs. Since the root causes are platform-level and hidden beneath the source code, even state-of-the-art LLM-based coding agents can struggle to diagnose and repair these discrepancies. In this paper, we present WasmMend, the first system for automatically repairing Native-Wasm functional discrepancies. WasmMend transforms open-ended debugging into a two-stage process. First, a novel differential trace analysis approach localizes the function where Wasm and native executions first diverge. Second, guided by this localization, a multi-agent system coordinates separate agents to interpret platform-specific behavior and synthesizes patch plans. Experiments on discrepancies from real-world C/C++ projects show that, across five backbone models, WasmMend achieves a fix rate of up to 84.8%, with average gains of at least 37.2 percentage points over the evaluated open-source coding agent baselines, while maintaining comparable cost.
查看此版本解读 →查看此版本原文 ↗