[llvm] [SPIRV] Modification of zero-length-array.ll (PR #152078)

Aadesh Premkumar via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 4 21:58:21 PDT 2025


https://github.com/aadeshps-mcw created https://github.com/llvm/llvm-project/pull/152078

--Modify the test zero-length-array.ll with target triple spirv-unknown-vulkan-compute.

>From d13ba79708b573786855e622015638c8351a5fc3 Mon Sep 17 00:00:00 2001
From: Aadesh PremKumar <aadesh.premkumar at multicorewareinc.com>
Date: Tue, 5 Aug 2025 10:25:54 +0530
Subject: [PATCH] --Modify the test zero-length-array.ll with target triple
 spirv-unknown-vulkan-compute

---
 llvm/test/CodeGen/SPIRV/zero-length-array.ll | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/llvm/test/CodeGen/SPIRV/zero-length-array.ll b/llvm/test/CodeGen/SPIRV/zero-length-array.ll
index 668bf2018dec7..cd29851684af1 100644
--- a/llvm/test/CodeGen/SPIRV/zero-length-array.ll
+++ b/llvm/test/CodeGen/SPIRV/zero-length-array.ll
@@ -1,9 +1,10 @@
-; RUN: llc -verify-machineinstrs -O0 -mtriple=spirv64-unknown-unknown %s -o - | FileCheck %s
-; RUN: %if spirv-tools %{ llc -O0 -mtriple=spirv64-unknown-unknown %s -o - -filetype=obj | spirv-val %}
+; RUN: llc -verify-machineinstrs -O0 -mtriple=spirv-unknown-vulkan-compute %s -o - | FileCheck %s
+; RUN: %if spirv-tools %{ llc -O0 -mtriple=spirv-unknown-vulkan-compute %s -o - -filetype=obj | spirv-val %}
 
+; CHECK: %[[#void:]] = OpTypeVoid
 ; CHECK: %[[#type:]] = OpTypeInt 32 0
-; CHECK: %[[#ext:]] = OpTypeRuntimeArray %[[#type]]
-; CHECK: %[[#]] = OpTypePointer Function %[[#ext]]
+; CHECK: %[[#ext:]] = OpConstant %[[#type]] 0
+; CHECK: %[[#]] = OpFunction %[[#void]]
 
 define spir_func void @_Z3foov() {
 entry:



More information about the llvm-commits mailing list