diff options
| author | joaosaffran <joao.saffran@microsoft.com> | 2025-06-19 20:29:48 +0000 |
|---|---|---|
| committer | joaosaffran <joao.saffran@microsoft.com> | 2025-06-19 20:29:48 +0000 |
| commit | 746c54a7279bef591571ea8838382c5f35e669cf (patch) | |
| tree | bdc787e91acb7384cad3a8167b1d69f6a2b70573 | |
| parent | e577503fe99407c1dab9032481ab869b1b0a2ae5 (diff) | |
fix testsusers/joaosaffran/144957
| -rw-r--r-- | llvm/test/CodeGen/DirectX/ContainerData/RootSignature-RootDescriptor-Invalid-Flags.ll | 2 | ||||
| -rw-r--r-- | llvm/test/CodeGen/DirectX/ContainerData/RootSignature-RootDescriptor_V1.ll | 34 |
2 files changed, 35 insertions, 1 deletions
diff --git a/llvm/test/CodeGen/DirectX/ContainerData/RootSignature-RootDescriptor-Invalid-Flags.ll b/llvm/test/CodeGen/DirectX/ContainerData/RootSignature-RootDescriptor-Invalid-Flags.ll index 6c90bcb09b64..82171c9627db 100644 --- a/llvm/test/CodeGen/DirectX/ContainerData/RootSignature-RootDescriptor-Invalid-Flags.ll +++ b/llvm/test/CodeGen/DirectX/ContainerData/RootSignature-RootDescriptor-Invalid-Flags.ll @@ -13,6 +13,6 @@ attributes #0 = { "hlsl.numthreads"="1,1,1" "hlsl.shader"="compute" } !dx.rootsignatures = !{!2} ; list of function/root signature pairs -!2 = !{ ptr @main, !3, i32 2 } ; function, root signature +!2 = !{ ptr @main, !3, i32 1 } ; function, root signature !3 = !{ !5 } ; list of root signature elements !5 = !{ !"RootCBV", i32 0, i32 1, i32 2, i32 3 } diff --git a/llvm/test/CodeGen/DirectX/ContainerData/RootSignature-RootDescriptor_V1.ll b/llvm/test/CodeGen/DirectX/ContainerData/RootSignature-RootDescriptor_V1.ll new file mode 100644 index 000000000000..e05c42a22ea4 --- /dev/null +++ b/llvm/test/CodeGen/DirectX/ContainerData/RootSignature-RootDescriptor_V1.ll @@ -0,0 +1,34 @@ +; RUN: opt %s -dxil-embed -dxil-globals -S -o - | FileCheck %s +; RUN: llc %s --filetype=obj -o - | obj2yaml | FileCheck %s --check-prefix=DXC + +target triple = "dxil-unknown-shadermodel6.0-compute" + +; CHECK: @dx.rts0 = private constant [44 x i8] c"{{.*}}", section "RTS0", align 4 + +define void @main() #0 { +entry: + ret void +} +attributes #0 = { "hlsl.numthreads"="1,1,1" "hlsl.shader"="compute" } + + +!dx.rootsignatures = !{!2} ; list of function/root signature pairs +!2 = !{ ptr @main, !3, i32 1 } ; function, root signature +!3 = !{ !5 } ; list of root signature elements +!5 = !{ !"RootCBV", i32 0, i32 1, i32 2, i32 8 } + +; DXC: - Name: RTS0 +; DXC-NEXT: Size: 44 +; DXC-NEXT: RootSignature: +; DXC-NEXT: Version: 1 +; DXC-NEXT: NumRootParameters: 1 +; DXC-NEXT: RootParametersOffset: 24 +; DXC-NEXT: NumStaticSamplers: 0 +; DXC-NEXT: StaticSamplersOffset: 0 +; DXC-NEXT: Parameters: +; DXC-NEXT: - ParameterType: 2 +; DXC-NEXT: ShaderVisibility: 0 +; DXC-NEXT: Descriptor: +; DXC-NEXT: RegisterSpace: 2 +; DXC-NEXT: ShaderRegister: 1 +; DXC-NOT: DATA_STATIC: true |
