Deep learning (DL) compilers such as TVM and ONNX-MLIR lower tensor computation graphs into optimized executables for target backends. Testing these AI compilers has made substantial progress in generating well-formed inputs in the context of fuzzing; however, such generation alone does not catch semantic drifts from algebraic invariants that graph transformations and optimizations are expected to preserve. While tensor algebra has been studied for decades, it has not been transformed into executable property-based tests (PBTs) for DL compilers because doing so requires jointly constructing operators, inputs, and test oracles. The central challenge is no longer generating well-formed inputs for fuzzing DL compilers, but bootstrapping executable PBTs with such inputs and oracles based on tensor algebra. We realize this vision in Propilot, an LLM-driven agentic property-based testing framework for DL compilers with GPT 5.5. First, Propilot represents tensor algebra knowledge as reusable property skeletons, each coupled with operator constraints, shape and value rules, and oracle templates. Second, given a target compiler, Propilot instantiates these skeletons into executable PBTs by generating paired tensor computation graphs, concrete tensor inputs, and expected semantic relations as oracles. Next, to prevent generated tests from degenerating into invalid or uninformative PBTs, Propilot validates each PBT candidate before execution for applicability and safety. Validation feedback, execution results, and coverage signals guide subsequent generation. We evaluate Propilot on TVM with 212 operators and 20 property skeletons, generating 4,579 PBTs. Compared with direct LLM-based PBT generation, Propilot reduces redundancy by 49% and eliminates invalid tests through explicit property skeletons. This effectiveness translates into finding semantic errors and numerical discrepancies.


翻译:深度学习(DL)编译器(如TVM和ONNX-MLIR)将张量计算图降级为面向目标后端的优化可执行文件。测试这些AI编译器在模糊测试中生成良好结构输入方面取得了显著进展;然而,仅靠这种生成无法捕捉到从代数不变量(即图变换和优化应保持的代数关系)中产生的语义漂移。尽管张量代数已研究数十年,但尚未转化为用于DL编译器的可执行基于性质的测试(PBTs),因为这样做需要联合构建算子、输入和测试预言机。核心挑战不再是生成用于模糊测试DL编译器的良好结构输入,而是基于张量代数使用这些输入和预言机引导可执行PBTs。我们通过Propilot实现了这一愿景,这是一款基于GPT 5.5、由LLM驱动的、面向DL编译器的智能体性质测试框架。首先,Propilot将张量代数知识表示为可重用的性质骨架,每个骨架包含算子约束、形状与数值规则以及预言机模板。其次,针对目标编译器,Propilot通过生成配对的张量计算图、具体张量输入以及作为预言机的预期语义关系,将这些骨架实例化为可执行PBTs。接着,为防止生成的测试退化为无效或无信息的PBTs,Propilot在执行前验证每个PBT候选者的适用性和安全性。验证反馈、执行结果和覆盖信号指导后续生成。我们在TVM上使用212个算子和20个性质骨架评估Propilot,生成了4,579个PBTs。与直接基于LLM的PBT生成相比,Propilot通过显式性质骨架将冗余减少了49%,并消除了无效测试。这种有效性转化为发现语义错误和数值差异。

0
下载
关闭预览

相关内容

编译器(Compiler),是一种计算机程序,它会将用某种编程语言写成的源代码(原始语言),转换成另一种编程语言(目标语言)。
【学界】DeepMind论文:深度压缩感知,新框架提升GAN性能
GAN生成式对抗网络
14+阅读 · 2019年5月23日
TensorFlow 2.0新特性之Ragged Tensor
深度学习每日摘要
18+阅读 · 2019年4月5日
放弃幻想,全面拥抱Transformer:NLP三大特征抽取器(CNN/RNN/TF)比较
黑龙江大学自然语言处理实验室
10+阅读 · 2019年1月15日
国家自然科学基金
6+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
4+阅读 · 2015年12月31日
国家自然科学基金
5+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
3+阅读 · 2014年12月31日
国家自然科学基金
11+阅读 · 2012年12月31日
VIP会员
最新内容
学习数据的几何:形状空间分析数学综述
专知会员服务
7+阅读 · 6月17日
定向能反无人机系统最新发展动态
专知会员服务
8+阅读 · 6月17日
从燃煤战舰到算法战争:水面指挥的永恒要求
专知会员服务
6+阅读 · 6月17日
相关VIP内容
相关基金
国家自然科学基金
6+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
4+阅读 · 2015年12月31日
国家自然科学基金
5+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
3+阅读 · 2014年12月31日
国家自然科学基金
11+阅读 · 2012年12月31日
Top
微信扫码咨询专知VIP会员