Skip to content

Commit 4c76681

Browse files
hekotaJaddyen
authored andcommitted
[HLSL][NFC] Add resource globals created for metadata to test baseline (llvm#140620)
Adds checks for resource globals that were created for DXIL metadata. The names of the globals and the names of the types will be changing soon. Adding these to the baseline will make it easier to see what is changing.
1 parent 327836d commit 4c76681

File tree

2 files changed

+21
-0
lines changed

2 files changed

+21
-0
lines changed

llvm/test/CodeGen/DirectX/Metadata/srv_metadata.ll

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,15 @@ define void @test() #0 {
8484

8585
attributes #0 = { noinline nounwind "hlsl.shader"="compute" }
8686

87+
; CHECK: @0 = external constant %TypedBuffer
88+
; CHECK: @1 = external constant %TypedBuffer.0
89+
; CHECK: @2 = external constant %TypedBuffer.1
90+
; CHECK: @3 = external constant %TypedBuffer.2
91+
; CHECK: @4 = external constant %ByteAddressBuffer
92+
; CHECK: @5 = external constant %StructuredBuffer
93+
; CHECK: @6 = external constant %TypedBuffer.3
94+
; CHECK: @7 = external constant %TypedBuffer.4
95+
8796
; CHECK: !dx.resources = !{[[ResList:[!][0-9]+]]}
8897

8998
; CHECK: [[ResList]] = !{[[SRVList:[!][0-9]+]], null, null, null}

llvm/test/CodeGen/DirectX/Metadata/uav_metadata.ll

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,18 @@ define void @test() #0 {
108108

109109
attributes #0 = { noinline nounwind "hlsl.shader"="compute" }
110110

111+
; CHECK: @0 = external constant %RWTypedBuffer
112+
; CHECK: @1 = external constant %RWTypedBuffer.0
113+
; CHECK: @2 = external constant %RWTypedBuffer.1
114+
; CHECK: @3 = external constant %RWTypedBuffer.2
115+
; CHECK: @4 = external constant %RWByteAddressBuffer
116+
; CHECK: @5 = external constant %RWStructuredBuffer
117+
; CHECK: @6 = external constant %RasterizerOrderedTypedBuffer
118+
; CHECK: @7 = external constant %RasterizerOrderedStructuredBuffer
119+
; CHECK: @8 = external constant %RasterizerOrderedByteAddressBuffer
120+
; CHECK: @9 = external constant %RWTypedBuffer.3
121+
; CHECK: @10 = external constant %RWTypedBuffer.4
122+
111123
; CHECK: !dx.resources = !{[[ResList:[!][0-9]+]]}
112124

113125
; CHECK: [[ResList]] = !{null, [[UAVList:[!][0-9]+]], null, null}

0 commit comments

Comments
 (0)