Skip to content

Commit

Permalink
address comments.
Browse files Browse the repository at this point in the history
  • Loading branch information
csyonghe authored Nov 21, 2024
1 parent 8d64ce3 commit de6a7c3
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions docs/user-guide/a2-01-spirv-target-specific.md
Original file line number Diff line number Diff line change
Expand Up @@ -162,8 +162,8 @@ Push Constants
---------------------

By default, a `uniform` parameter defined in the parameter list of an entrypoint function is translated to a push constant in SPIRV, if the type of the parameter is ordinary data type (no resources/textures).
All `uniform` parameter defined in global scope are grouped together and placed in a default constant buffer. You can make a global uniform parameter laid out as a push constant by using the `[vk::push_constant]` attribute
on the uniform parameter. All push constants follow the std430 layout by-default.
All `uniform` parameters defined in global scope are grouped together and placed in a default constant buffer. You can make a global uniform parameter laid out as a push constant by using the `[vk::push_constant]` attribute
on the uniform parameter. All push constants follow the std430 layout by default.

Specialization Constants
------------------------
Expand Down
2 changes: 1 addition & 1 deletion tests/spirv/push-constant-layout.slang
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
struct Transform
{
float4 Tint;
float2x2 ScaleRot; // << why u no std430???
float2x2 ScaleRot;
float2 Translation;
};

Expand Down
2 changes: 1 addition & 1 deletion tests/spirv/spec-constant-space.slang
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Test that use of specialiation constants does not cause space 0 to be reserved.
// Test that use of specialization constants does not cause space 0 to be reserved.

//TEST:SIMPLE(filecheck=CHECK): -target spirv

Expand Down

0 comments on commit de6a7c3

Please sign in to comment.