REFORGE: LLM-Assisted RTL Bug Repair with Structured Context and Verification Feedback
Tanvir Hossain, Sudipta Paria, Aidan Gleason Myers, Swarup Bhunia, Tamzidul Hoque
Abstract
Large language models (LLMs) can write and repair RTL, but successful compilation or testbench execution does not establish defect removal, behavioral preservation, security, or implementation feasibility. Existing LLM-based RTL repair methods often report a single repair rate without retaining separate evidence for these properties, limiting reproducible comparison and integration into hardware design flows. We present REFORGE, which, to our knowledge, is the first LLM-assisted RTL repair framework that maintains and accumulates structured repair evidence across iterations, allowing it to generate fixes that satisfy multiple objectives simultaneously, including functionality, behavioral equivalence, security, and cost efficiency. REFORGE profiles buggy RTL, identifies structural and security-relevant features, localizes failing behavior, and uses verification-guided diagnosis to generate complete RTL repair variants. Each variant undergoes syntax checking, simulation, formal analysis, off-trigger preservation, security re-scan, and synthesis-based power, performance, and area analysis. We implement REFORGE as a backend-independent repair-and-verification flow and evaluate it in 288 runs across three LLM backends and three benchmark suites. On CirFix, the proposed context and diagnosis increase runs delivering a checked repair from 32/63 to 51/63, while every configuration repairs the Hack@DAC OpenTitan defect. Evidence records also show that a testbench-only criterion reports 3.9 times more repairs than the full set of applicable checks, security-clean outputs may lack functional verification, and different RTL repairs can implement equivalent hardware. These results show that LLM-generated RTL repairs require explicit multi-stage verification evidence rather than a single pass/fail outcome.
Create a lesson
Metadata
- Categories
- cs.AI, cs.SE
- Comments
- Accepted at DATE 2027 (Design, Automation and Test in Europe); initial author version
Related papers
PowerFix: Physics-Guided Iterative Repair for LLM-Assisted Power Converter Design
Shared title terminologycs.AICan Wang, Shi Qiu, Fanfan Lin
Procedure Inference as Memory: Learning Recruiter Decision Procedures from OKF-Structured Episodes in Multi-Session Hiring Assistants
Shared title terminologycs.AIPraveen Kumar Bodigutla, Yizhi Zhang, Sai Vivek Kanaparthy et al.
Knowledge-Base Gradient Descent: Self-Structuring Learning through Question Answering
Shared title terminologycs.AIMasahiro Kato
What Is a Theory Worth to an LLM Solver? Measuring, Inducing, and Merging Theories in Context
Shared title terminologycs.AIJun Gao, Shuchao Bi
HoMe: Toward Practical Harness Optimization of Memory Systems for AI Assistants
Shared title terminologycs.AIYifei Xu, Li Yu, Zhaoyang Liu et al.
EgoUseBench: Benchmarking Computer-Use Agents under Evolving First-Person Contexts
Shared title terminologycs.AIYurun Chen, Biao Yi, Qihang Yu et al.