Skip to content

[HLSL] Add support for unbounded resource arrays at global scope #145427

Open
@hekota

Description

@hekota

Add support for unbounded resource array declaration at global scope.

For example:

RWBuffer<float> D[] : register(u5);
RWBuffer<float> E[][4] : register(u0, space1);
RWBuffer<float> Out;

[numthreads(4,1,1)]
void main() {
  Out[0] = D[100][0] + E[1000][4][0];
}

Note that local declarations of unbounded arrays will not be supported by HLSL in Clang. See microsoft/hlsl-specs#141.

Metadata

Metadata

Assignees

No one assigned

    Labels

    HLSLHLSL Language Support

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions