gpuweb / cts

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

shader/execution: Fix abstract non_zero constructor tests #3677

Closed ben-clayton closed 2 months ago

ben-clayton commented 2 months ago

Depending on the platform, we either directly assign the expression evaluation to the output buffer, or go via a const array. The latter caused compilation failures as it would force a concretization of the abstract values in the array, which would become incompatible with the output type.

To force the harness to avoid the array, add a new optional ConstEvaluationMode flag to force the evaluation mode used.

Also replace the growing list of ShaderBuilder parameters with a structure, so that fewer places need to be updated for this sort of change in the future.

Issue: #3657


Requirements for PR author:

Requirements for reviewer sign-off:

When landing this PR, be sure to make any necessary issue status updates.