diff options
| author | ArielG-NV <159081215+ArielG-NV@users.noreply.github.com> | 2024-04-03 14:19:15 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-04-03 11:19:15 -0700 |
| commit | e0de98e9aabbe118f0eeca7821518c8fb4e1f6c4 (patch) | |
| tree | a310629cd025372c6d554705ba7f42251f400ac5 /tests/glsl/ssboStructInsideStructMemoryQualifierError.slang | |
| parent | a697b2c6707ee699cb734a03fa529dd214ac66cc (diff) | |
Refactor memory qualifier decorators to be a bit-flag set, resolves #3841 (#3881)
* Refactor memory qualifier decorators to be a bit-flag set.
replace GloballyCoherent, ReadOnly, WriteOnly, Volatile, and Restrict memory modifiers and decorations with a bit flag set to more efficiently manage memory qualifiers.
added `restrict` modifier to test to ensure the code works when dropping a `restrict` memory qualifier
* Refine tests & add SSBO memory qualifer support
add CHECK's to tests to ensure memory qualifiers emit as intended
added tests and changed code to ensure memory qualifiers work on SSBO objects (SPIR-V & GLSL)
* add memory qualifiers & fixes.
Add to StructuredBuffer & ByteAddressBuffer `ReadOnly`/NonWritable qualifier.
* Memory qualifiers must be decorated on a variable inst. Due to this the qualifier is added after `lowerStructuredBufferType`
Fixed an error where ReadOnly->NonReadable & WriteOnly->NonWritable
* Adjusted tests accordingly
Added back the removed `globallycoherent` memory qualifier emit'ing code in hlsl-emit (was incorrectly removed).
undo hlsl.meta changes
cleanup
Diffstat (limited to 'tests/glsl/ssboStructInsideStructMemoryQualifierError.slang')
| -rw-r--r-- | tests/glsl/ssboStructInsideStructMemoryQualifierError.slang | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/glsl/ssboStructInsideStructMemoryQualifierError.slang b/tests/glsl/ssboStructInsideStructMemoryQualifierError.slang index c5376b4a8..82ae9d725 100644 --- a/tests/glsl/ssboStructInsideStructMemoryQualifierError.slang +++ b/tests/glsl/ssboStructInsideStructMemoryQualifierError.slang @@ -1,12 +1,12 @@ -//TEST:SIMPLE(filecheck=CHECK-GLSL): -stage compute -entry computeMain -allow-glsl -target glsl -//TEST:SIMPLE(filecheck=CHECK-SPV): -stage compute -entry computeMain -allow-glsl -target spirv -emit-spirv-directly +//TEST:SIMPLE(filecheck=CHECK_GLSL): -stage compute -entry computeMain -allow-glsl -target glsl +//TEST:SIMPLE(filecheck=CHECK_SPV): -stage compute -entry computeMain -allow-glsl -target spirv -emit-spirv-directly // This code should error since memory qualifiers are only allowed inside: // Shader storage blocks, variables declared within shader storage blocks // and variables declared as image types. Named structs inside a Interface // block violates these rules -// CHECK-GLSL: error -// CHECK-SPV: error +// CHECK_GLSL: error +// CHECK_SPV: error buffer Block4 { struct StructTmp { |
