Skip to content

[Flutter GPU] Storage buffer bindings #188479

Open

Description

@bdero

Part of #188474.

Compute shaders need storage buffers bound from Dart. After #188477, Shader holds the reflected storage buffers, but nothing exposes them.

Changes

  • A storage-buffer slot on Shader, alongside the existing uniform and texture slots, with the same cached index lookup.
  • Storage buffers in binding sets ([Flutter GPU] Reusable binding sets #190400).
  • Bind-time validation, since out-of-bounds storage access is undefined on the GPU:
    • the view is at least the block's size_in_bytes;
    • for a block ending in a runtime-sized array, the remainder is a whole number of elements;
    • the offset meets the device's minimum storage-buffer offset alignment, which gpuContext exposes.
  • HostBuffer storage emplacements use the storage alignment instead of the uniform alignment.

The bind method itself lives on ComputePass (#188480). Storage buffers in vertex and fragment shaders wait for the OpenGL ES tiering in Wave 3 of #188474.

Testing

Slot lookup for storage buffers, including an optimized-out buffer, and rejection of a short view, a partial trailing element and a misaligned offset.

Dependencies

#188477.

Activity

  1. added
    c: new featureNothing broken; request for a new capability
    engineflutter/engine related. See also e: labels.
    e: impellerImpeller rendering backend issues and features requests
    on Jun 24, 2026
  2. moved this to 🤔 Needs Triage in Flutter GPUon Jun 24, 2026
  3. moved this from 🤔 Needs Triage to 💡 Features in Flutter GPUon Jun 24, 2026
  4. self-assigned this
    on Oct 5, 2026
  5. added 2 commits that reference this issue on Oct 11, 2026
    a4a48b9
    8c612a5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

c: new featureNothing broken; request for a new capabilitye: impellerImpeller rendering backend issues and features requestsengineflutter/engine related. See also e: labels.flutter-gputeam-fluttergpuOwned by Flutter GPU team

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions