Skip to content

Properly document support for shared memory (aka groupshared) (was: implement too) #695

@hrydgard

Description

@hrydgard

EDIT: Answer in #695 (comment) , but docs still need improvement.

Shared memory within a group (as annotated with groupshared in HLSL) doesn't seem to be documented at least, and I can't figure out how to use it.

Basically, this in HLSL:

groupshared float4 buffer[window_size];

where threads in a whole group can share data with each other (with careful use of group barriers).

The documentation for the barriers should also be linked from the documentation for this. Also, barriers need better documentation with examples. For example https://embarkstudios.github.io/rust-gpu/api/spirv_std/arch/fn.memory_barrier.html# , it really could use a copy-pastable line. It's not super clear what to pass into the two generics arguments.

So if support isn't there, it needs to be implemented, or if it is, it needs to be documented .

Metadata

Metadata

Assignees

No one assigned

    Labels

    t: enhancementA new feature or improvement to an existing one.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions