Sitelet https://github.com/gpuweb/gpuweb/issues/2794
Skip to content

Consider making binding_array a reserved word #2794

Description

@jimblandy

Naga has an experimental implementation of binding arrays, where you write globals like this:

@group(42) @binding(1729)
var a: binding_array<texture2d<f32>>;

and then there are new variants of (wgpu's analogues of) GPUBindGroupLayoutEntry and GPUBindGroupEntry that let you supply an array of textures as a's value.

Is it reasonable to ask WGSL to reserve binding_array on this basis? If so, then we have a graceful way to prevent people from using wgpu's binding arrays in WebGPU: they simply cannot write bind group layouts that permit them in the first place, so any shader that uses binding arrays cannot be used in any pipeline. (Naga does have feature bits, but we haven't generally used them for things that are part of the shader's interface anyway.)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    wgslWebGPU Shading Language Issueswgsl resolvedResolved - waiting for a change to the WGSL specification

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions