[llvm] [NFC][NVPTX] Add a simpler test case for 0b80288e9e0b (PR #73379)
Uday Bondhugula via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 24 23:08:48 PST 2023
https://github.com/bondhugula created https://github.com/llvm/llvm-project/pull/73379
While 0b80288e9e0b allowed more efficient lowering for 16xi8 loads, its
test case was closer to an "integration" one. Add a much simpler unit
test case that exercises it.
>From 6ac0ccaffca059628e8f7b0194a3e6c2951afbb6 Mon Sep 17 00:00:00 2001
From: Uday Bondhugula <uday at polymagelabs.com>
Date: Sat, 25 Nov 2023 12:35:14 +0530
Subject: [PATCH] [NFC][NVPTX] Add a simpler test case for 0b80288e9e0b
While 0b80288e9e0b allowed more efficient lowering for 16xi8 loads, its
test case was closer to an "integration" one. Add a much simpler unit
test case that exercises it.
---
llvm/test/CodeGen/NVPTX/vector-stores.ll | 16 ++++++++++++----
1 file changed, 12 insertions(+), 4 deletions(-)
diff --git a/llvm/test/CodeGen/NVPTX/vector-stores.ll b/llvm/test/CodeGen/NVPTX/vector-stores.ll
index 0254a58d2aebd0d..df14553a7720576 100644
--- a/llvm/test/CodeGen/NVPTX/vector-stores.ll
+++ b/llvm/test/CodeGen/NVPTX/vector-stores.ll
@@ -1,31 +1,39 @@
; RUN: llc < %s -march=nvptx64 -mcpu=sm_20 | FileCheck %s
; RUN: %if ptxas %{ llc < %s -march=nvptx64 -mcpu=sm_20 | %ptxas-verify %}
-; CHECK: .visible .func foo1
+; CHECK-LABEL: .visible .func foo1
; CHECK: st.v2.f32
define void @foo1(<2 x float> %val, ptr %ptr) {
store <2 x float> %val, ptr %ptr
ret void
}
-; CHECK: .visible .func foo2
+; CHECK-LABEL: .visible .func foo2
; CHECK: st.v4.f32
define void @foo2(<4 x float> %val, ptr %ptr) {
store <4 x float> %val, ptr %ptr
ret void
}
-; CHECK: .visible .func foo3
+; CHECK-LABEL: .visible .func foo3
; CHECK: st.v2.u32
define void @foo3(<2 x i32> %val, ptr %ptr) {
store <2 x i32> %val, ptr %ptr
ret void
}
-; CHECK: .visible .func foo4
+; CHECK-LABEL: .visible .func foo4
; CHECK: st.v4.u32
define void @foo4(<4 x i32> %val, ptr %ptr) {
store <4 x i32> %val, ptr %ptr
ret void
}
+; CHECK-LABEL: .visible .func v16i8
+define void @v16i8(ptr %a, ptr %b) {
+; CHECK: ld.v4.u32
+; CHECK: st.v4.u32
+ %v = load <16 x i8>, ptr %a
+ store <16 x i8> %v, ptr %b
+ ret void
+}
More information about the llvm-commits
mailing list