arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2406.18627cs.SEcs.LG
收藏

AssertionBench:评估大型语言模型生成断言能力的基准

AssertionBench: A Benchmark to Evaluate Large-Language Models for Assertion Generation

University of Illinois Chicago(伊利诺伊大学芝加哥分校);Microsoft(微软公司)

Vaishnavi Pulavarthi, Deeksha Nandal, Soham Dan, Debjit Pal

AI总结:

本文提出AssertionBench基准,包含100个Verilog设计和形式验证断言,用于定量评估LLMs生成硬件断言的能力,实验显示LLMs相对表现及上下文示例的益处,并指出改进空间。

摘要:

断言(assertions)在过去十多年中一直是硬件设计基于仿真和形式验证的事实标准附属物。硬件验证的质量,即检测和诊断角落情况设计缺陷的能力,关键依赖于断言的质量。已有大量研究利用数据驱动统计分析和静态分析的结合,从硬件设计源代码和设计执行轨迹数据中生成高质量断言。尽管付出了这些协同努力,所有先前的研究都难以扩展到工业规模的大型设计,生成了过多低质量的断言,常常无法捕捉微妙且非平凡的设计功能,并且没有为生成的断言提供易于理解的解释,以理解断言对不同下游验证任务的适用性。最近,随着大型语言模型(LLMs)的出现,利用提示工程生成断言的广泛努力已经展开。然而,几乎没有努力定量地建立各种LLMs在断言生成方面的有效性和适用性。在本文中,我们提出了AssertionBench,一个新颖的基准,用于定量评估LLMs在断言生成方面的有效性。AssertionBench包含从OpenCores精选的100个Verilog硬件设计,以及每个设计由GoldMine和HARM生成的形式验证断言。我们使用AssertionBench比较最先进的LLMs,以评估它们在为硬件设计推断功能正确断言方面的有效性。我们的实验展示了LLMs之间的相对表现,使用更多上下文示例在生成更高比例功能正确断言方面的益处,以及基于LLM的断言生成器还有很大的改进空间。

英文摘要:

Assertions have been the de facto collateral for simulation-based and formal verification of hardware designs for over a decade. The quality of hardware verification, \ie, detection and diagnosis of corner-case design bugs, is critically dependent on the quality of the assertions. There has been a considerable amount of research leveraging a blend of data-driven statistical analysis and static analysis to generate high-quality assertions from hardware design source code and design execution trace data. Despite such concerted effort, all prior research struggles to scale to industrial-scale large designs, generates too many low-quality assertions, often fails to capture subtle and non-trivial design functionality, and does not produce any easy-to-comprehend explanations of the generated assertions to understand assertions' suitability to different downstream validation tasks. Recently, with the advent of Large-Language Models (LLMs), there has been a widespread effort to leverage prompt engineering to generate assertions. However, there is little effort to quantitatively establish the effectiveness and suitability of various LLMs for assertion generation. In this paper, we present AssertionBench, a novel benchmark to evaluate LLMs' effectiveness for assertion generation quantitatively. AssertioBench contains 100 curated Verilog hardware designs from OpenCores and formally verified assertions for each design generated from GoldMine and HARM. We use AssertionBench to compare state-of-the-art LLMs to assess their effectiveness in inferring functionally correct assertions for hardware designs. Our experiments demonstrate how LLMs perform relative to each other, the benefits of using more in-context exemplars in generating a higher fraction of functionally correct assertions, and the significant room for improvement for LLM-based assertion generators.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑