用大模型优化加法器设计,更小面积、更大规模。
PrefixAgent: An LLM-Powered Design Framework for Efficient Prefix Adder Optimization
- 分两步重构问题:先搭骨架再局部优化,缩小搜索空间。
- 在多数配置下面积优于基线,位宽越大优势越明显。
- 适合芯片设计自动化研究者,尤其关注高效电路生成。
前缀加法器是基础算术电路,但其设计空间随位宽呈指数增长,带来显著优化挑战。以往方法在性能、泛化性和可扩展性方面存在局限。为此,我们提出 PrefixAgent,一个基于大语言模型的高效前缀加法器优化框架。首先,将问题分解为骨干结构合成与结构精炼两个子任务,有效降低搜索空间。大模型通过函数调用调用工具,结合推理与EDA反馈,迭代构建骨干并优化局部结构。其次,这一新视角使我们能系统收集大规模高质量监督数据。利用e-graphs的重写与等式饱和能力,全面探索前缀加法器解空间。e-graphs的可解释性还支持提取细粒度重写轨迹,作为可解释且高效的训练数据。PrefixAgent在此数据集上微调后,显著提升优化能力与推理泛化性。实验表明,PrefixAgent在几乎所有配置下生成的加法器面积均小于基线方法,且在更大位宽时优势更加显著,并在商用EDA流程中保持有效性。
原文摘要 · Abstract (English)
Prefix adders are fundamental arithmetic circuits, but their design space grows exponentially with bit-width, posing significant optimization challenges. Previous works face limitations in performance, generalization, and scalability. To address these challenges, we propose PrefixAgent, an LLM-powered framework that enables efficient prefix adder optimization. Firstly, we reformulate the problem into two subtasks, namely backbone synthesis and structure refinement, which effectively reduce the search space. The LLM performs these two phases of optimization by invoking tools through function calls, enabling it to iteratively construct the backbone and refine local structures based on reasoning and EDA feedback. Secondly, this new design perspective allows us to systematically collect large-scale, high-quality supervision data. We leverage the rewriting and equality saturation capabilities of e-graphs to comprehensively explore the prefix adder solution space. In addition, the explainability of e-graphs enables us to extract fine-grained rewrite trajectories, which serve as interpretable and effective training data. PrefixAgent is then fine-tuned on this dataset, significantly enhancing its optimization ability and reasoning generalization. Experimental results show that PrefixAgent synthesizes prefix adders with smaller areas than baseline methods in nearly all configurations, with the advantage growing at larger bit-widths, and it remains effective under a commercial EDA flow.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。