编写SystemVerilog Assertions (SVA) 是验证Register Transfer Level (RTL) 设计中重要但复杂的一步。传统上,专家需要理解设计规范并编写SVA断言,这既耗时又容易出错。然而,随着transformer模型的最新进展,Large Language Models (LLMs) 辅助的设计验证断言生成近期正受到关注。受此启发,我们提出了一种新颖的基于LLM的框架LAAG-RV,用于从设计的自然语言规范生成SVA。我们的框架在生成的SVA中提供了一次性Verilog循环用于信号同步,以提高生成断言的质量。在我们的实验中,我们基于OpenAI GPT-4创建了一个自定义LLM。此外,我们开发了测试用例来验证LLM生成的断言。初步观察显示,一些生成的断言存在问题,并未通过所有测试用例。然而,通过在模拟器中使用源自测试用例失败信息的精心制作的手动提示迭代地提示LLM,该框架能够生成正确的SVA。我们在OpenTitan设计上的结果表明,LLM显著简化了生成断言的过程,使其更高效且不易出错。
英文摘要:
Writing SystemVerilog Assertions (SVA) is an important but complex step in verifying Register Transfer Level (RTL) designs. Conventionally, experts need to understand the design specifications and write the SVA assertions, which is time-consuming and error-prone. However, with the recent advancement of transformer models, the Large Language Models (LLMs) assisted assertion generation for design verification is gaining interest in recent times. Motivated by this, we proposed a novel LLM-based framework, LAAG-RV, to generate SVA from the natural language specifications of the design. Our framework provides a one-time Verilog loop for signal synchronization in the generated SVA to improve the generated assertion quality. For our experiments, we created a custom LLM based on OpenAI GPT-4. Furthermore, we developed test cases to validate the LLM-generated assertions. Initial observations show that some generated assertions contain issues and did not pass all the test cases. However, by iteratively prompting the LLMs using carefully crafted manual prompts derived from test case failures in a simulator, the framework can generate correct SVAs. Our results on OpenTitan designs demonstrate that LLMs significantly simplify the process of generating assertions, making it efficient and less error-prone.
From Indiscriminate to Targeted: Functionally Critical Signal-Driven Assertion Generation using LLMs for Efficient RTL Verification
State Key Lab of Processors, Institute of Computing Technology, CAS(处理器国家重点实验室,中国科学院计算技术研究所);University of Chinese Academy of Sciences(中国科学院大学);Beijing University of Posts and Telecommunications(北京邮电大学);Beijing Normal University(北京师范大学);Tencent(腾讯);The Chinese University of Hong Kong(香港中文大学)
AssertGen: Enhancement of LLM-aided Assertion Generation through Cross-Layer Signal Bridging
State Key Lab of Processors, Institute of Computing Technology, CAS(处理器重点实验室,计算技术研究所,中国科学院);University of Chinese Academy of Sciences(中国科学院大学);School of Integrated Circuits, Nanjing University(南京大学集成电路学院);School of Information and Physical Sciences, University of Newcastle(纽卡斯尔大学信息与物理科学学院)
AssertFix: Empowering Automated Assertion Fix via Large Language Models
State Key Lab of Processors, Institute of Computing Technology, CAS(处理器国家重点实验室,中国科学院计算技术研究所);University of Chinese Academy of Sciences(中国科学院大学);School of Information and Physical Sciences, University of Newcastle(纽卡斯尔大学信息与物理科学学院)
针对 LLM 生成的错误 SVA 仍需人工修复的问题,本文提出 AssertFix 框架,自动定位相关 RTL、诊断根因、分类错误并应用专用策略修复断言,在 Opencore 上提升修复率与验证覆盖率。
DeepAssert: An LLM-Aided Verification Framework with Fine-Grained Assertion Generation for Modules with Extracted Module Specifications
State Key Lab of Processors, Institute of Computing Technology, CAS(处理器重点实验室,计算技术研究所,中国科学院);University of Chinese Academy of Sciences(中国科学院大学);Beijing Normal University(北京师范大学)
Veri-Sure: Multi-Agent RTL Code Generation with Temporal Tracing, Slicing and Formal Verification
School of Physics and Astronomy, The University of Edinburgh, Edinburgh, UK(物理与天文学院,爱丁堡大学,爱丁堡,英国);State Key Laboratory of Analog and Mixed-Signal VLSI, University of Macau, Macau(模拟与混合信号VLSI国家重点实验室,澳门大学,澳门);School of Science and Engineering, The Chinese University of Hong Kong, Shenzhen, Shenzhen, China(科学与工程学院,香港中文大学(深圳))
AutoINV: Automated Invariant Generation Framework for Formal Verification on High-Level Synthesis Designs
The Hong Kong University of Science and Technology(香港科技大学);Indian Institute of Technology Goa(印度理工学院果阿分校);The Hong Kong University of Science and Technology (Guangzhou)(香港科技大学(广州))
ChatSVA: Bridging SVA Generation for Hardware Verification via Task-Specific LLMs
National ASIC Center, School of Integrated Circuits, Southeast University, China(国家集成电路中心,东南大学集成电路学院,中国);National Center of Technology Innovation for Electronic Design Automation, China(电子设计自动化技术创新国家中心,中国);Department of Computer Science, City University of Hong Kong, Hong Kong, China(计算机科学系,香港城市大学,香港,中国)