AutoHIL: LLM-Based ECU Functional Test Generation through Domain Knowledge Augmentation
Sichen Gong, Qicai Chen, Bihuan Chen, Wenzhuo Zhang, Yukun Gao, Xin Peng
Abstract
System functional testing is a critical step before the production release of automotive electronic control units (ECUs), especially for safety-critical functions. It is typically performed on hardware-in-the-loop (HIL) benches, and engineers translate functional requirements in natural language into executable test scripts using bench-specific APIs (or test harness primitives (THPs)). Existing research either focuses on generating abstract test cases that lack execution capability, or relies on bench-specific solutions that cannot be generalized. Consequently, industrial practice remains labor-intensive, and is hindered by three main challenges, i.e., the high learning cost of THPs, the incompleteness of functional requirements due to missing tacit domain knowledge (e.g., power management dependencies or system wake-up sequences), and the limited automation. To address these challenges, we propose AUTOHIL, an LLM-based, domain-knowledge-augmented framework for requirement-driven ECU functional test generation on HIL benches. AUTOHIL automatically constructs a THP knowledge base to understand bench operations, extracts tacit domain knowledge from AUTOSAR ECU source code and configurations to augment requirements, and generates test scripts for the augmented requirements based on the THP knowledge base. We evaluate AUTOHIL on two industrial ECUs, i.e., an Airbag Control Unit (ACU) on an in-house bench and an Active Safety Domain Master (ASDM) on a dSPACE platform. AUTOHIL achieves test script executability of 90.33% on ACU and 81.31% on ASDM. We also manually evaluate the functional equivalence between generated scripts and manual scripts, and AUTOHIL reaches a functional correctness of 89.69% on ACU and 84.00% on ASDM. We discover 39 and 25 new functional defects in ACU and ASDM, which have been patched by technicians from the supplier.
Ask about this paper
Ask your agent about it.
Lune has read the top-tier papers around this one, so every answer names the papers it rests on.
Your agent calls
Lunesearch_papers
Free to start. No credit card required.
Terminal
Install the CLIlune papers get d95e250a-c193-4b58-9337-8c58348e1758Related papers
- Fixed-Point Guided ADS Scenario Generation via Multi-modal LLM Reasoning and Software TestingXudong Zhang, Shihao Zhu, Yan CaiISSTA 2026
- AutoSVA: Democratizing Formal Verification of RTL Module InteractionsMarcelo Orenes-Vera, Aninda Manocha, David Wentzlaff, Margaret MartonosiDAC 2021 · 30 citations
- LeGEND: A Top-Down Approach to Scenario Generation of Autonomous Driving Systems Assisted by Large Language ModelsShuncheng Tang, Zhenya Zhang, Jixiang Zhou, Lei Lei et al.ASE 2024 · 17 citations
- SAFE: Harnessing LLM for Scenario-Driven ADS Testing from Multimodal Crash DataSiwei Luo, Yang Zhang, Yao Deng, Linfeng Liang et al.ICSE 2026
- Uncovering Business Logic Bugs via Semantics-Driven Unit Test Generation (Experience Paper)Chen Yang, Junjie ChenISSTA 2026
