gpuweb / cts

WebGPU Conformance Test Suite
https://gpuweb.github.io/cts/
BSD 3-Clause "New" or "Revised" License
121 stars 72 forks source link

`webgpu:api,operation,labels:wrappers_do_not_share_labels:*` calls `createRenderPipeline` with no target #3754

Closed jimblandy closed 1 month ago

jimblandy commented 1 month ago

The algorithm validatingGPURenderPipelineDescriptor says:

But webgpu:api,operation,labels:wrappers_do_not_share_labels:* tries to create a render pipeline without any attachments:

    const pipeline = t.device.createRenderPipeline({
      layout: 'auto',
      vertex: {
        module,
        entryPoint: 'main',
      },
    });
kainino0x commented 1 month ago

Thank you for catching this! I am surprised that Dawn passes this test. I thought we had tests for this validation. I'm pretty sure we do for render passes, I guess we missed it for render pipelines. I have filed https://crbug.com/341812551

We'll also of course need to test that, since I guess we're not testing it. (EDIT: ... which Erich already filed. https://github.com/gpuweb/cts/issues/3755)

Kangz commented 1 month ago

This is expect, the WebGPU spec says:

fragment, of type GPUFragmentState Describes the fragment shader entry point of the pipeline and its output colors. If not provided, the § 23.3.8 No Color Output mode is enabled.

ErichDonGubler commented 1 month ago

@Kangz: In that case, a depth-stencil attachment should still be specified, yes, per the spec. text in the OP?

Kangz commented 1 month ago

Ah my bad, yes that's the case.

ErichDonGubler commented 1 month ago

Resolved with https://github.com/gpuweb/cts/pull/3756. I've filed an issue for validating this specific case at https://github.com/gpuweb/cts/issues/3755.