Fix 8-bit storage nearly always using the
UniformAndStorageBuffer8BitAccess capability. When using the 8-bit storage extension it basically always used the `UniformAndStorageBuffer8BitAccess` capability, even in cases where it wasn't required. For instance if we are targeting Vulkan 1.1 (SPIR-V 1.3 or higher), and we are only using 8-bit types in an SSBO, we only need the `StorageBuffer8BitAccess` capability. I fixed this by enabling storage buffer use in Vulkan 1.1 / SPIR-V 1.3 or higher, and then changing the logic to match. I also added some tests that will output different capabilities when run on Vulkan 1.0 and 1.1, thus they are added twice to the test list (one for each version). Fixes #1539
This commit is contained in:
@@ -36,7 +36,7 @@ spv.subgroupClustered.comp
|
||||
MemberDecorate 24(Buffers) 1 Offset 16
|
||||
MemberDecorate 24(Buffers) 2 Offset 32
|
||||
MemberDecorate 24(Buffers) 3 Offset 64
|
||||
Decorate 24(Buffers) BufferBlock
|
||||
Decorate 24(Buffers) Block
|
||||
Decorate 27(data) DescriptorSet 0
|
||||
Decorate 27(data) Binding 0
|
||||
Decorate 736 BuiltIn WorkgroupSize
|
||||
@@ -57,30 +57,30 @@ spv.subgroupClustered.comp
|
||||
23: TypeVector 22(float64_t) 4
|
||||
24(Buffers): TypeStruct 18(fvec4) 20(ivec4) 21(ivec4) 23(f64vec4)
|
||||
25: TypeArray 24(Buffers) 15
|
||||
26: TypePointer Uniform 25
|
||||
27(data): 26(ptr) Variable Uniform
|
||||
26: TypePointer StorageBuffer 25
|
||||
27(data): 26(ptr) Variable StorageBuffer
|
||||
29: 19(int) Constant 0
|
||||
30: 6(int) Constant 0
|
||||
31: TypePointer Uniform 17(float)
|
||||
31: TypePointer StorageBuffer 17(float)
|
||||
34: 6(int) Constant 1
|
||||
35: 6(int) Constant 3
|
||||
39: 19(int) Constant 1
|
||||
40: TypeVector 17(float) 2
|
||||
41: TypePointer Uniform 18(fvec4)
|
||||
41: TypePointer StorageBuffer 18(fvec4)
|
||||
50: 19(int) Constant 2
|
||||
51: TypeVector 17(float) 3
|
||||
60: 19(int) Constant 3
|
||||
66: TypePointer Uniform 19(int)
|
||||
66: TypePointer StorageBuffer 19(int)
|
||||
72: TypeVector 19(int) 2
|
||||
73: TypePointer Uniform 20(ivec4)
|
||||
73: TypePointer StorageBuffer 20(ivec4)
|
||||
82: TypeVector 19(int) 3
|
||||
96: TypePointer Uniform 6(int)
|
||||
96: TypePointer StorageBuffer 6(int)
|
||||
102: TypeVector 6(int) 2
|
||||
103: TypePointer Uniform 21(ivec4)
|
||||
103: TypePointer StorageBuffer 21(ivec4)
|
||||
112: TypeVector 6(int) 3
|
||||
126: TypePointer Uniform 22(float64_t)
|
||||
126: TypePointer StorageBuffer 22(float64_t)
|
||||
132: TypeVector 22(float64_t) 2
|
||||
133: TypePointer Uniform 23(f64vec4)
|
||||
133: TypePointer StorageBuffer 23(f64vec4)
|
||||
142: TypeVector 22(float64_t) 3
|
||||
522: TypeBool
|
||||
531: 72(ivec2) ConstantComposite 29 29
|
||||
|
||||
Reference in New Issue
Block a user