7ca82ac4d0
This CL modifies the way adapter creating devices, adds `shader-f16` feature, and deprecates the `dawn-shader-float16` feature which is no longer used. Details: 1. Parse the toggles chained with device descriptor in `adapter::CreateDeviceInternal`, which are then used to validate features requirement within `CreateDeviceInternal` and passed to device constructor as initializer. 2. When creating device, validate features requirement in `CreateDeviceInternal` with toggles known, make sure to fail the device creation if a required feature is not supported by adapter or is guarded by certain toggles which were not enabled/disabled. Feature ShaderF16 and ChromiumExperimentalDp4a are validated in this way. Unittest is added to check creating devices with toggles-guarded features required. 3. Add `shader-f16` feature, which allow `using f16;` in WGSL code. End-to-end tests are added to test a trival f16 WGSL shader could be used if and only if the device has `shader-f16` feature. 4. Deprecate the `dawn-shader-float16` feature, which will be completely removed after cleaning up Blink code. Bug: dawn:1510 Change-Id: I6cb2dcbe1ee584fdd6131c62df1ee850b881dbd2 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/100802 Kokoro: Kokoro <noreply+kokoro@google.com> Commit-Queue: Zhaoming Jiang <zhaoming.jiang@intel.com> Reviewed-by: Austin Eng <enga@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> |
||
---|---|---|
.. | ||
native | ||
platform | ||
wire | ||
BUILD.gn | ||
EnumClassBitmasks.h | ||
dawn_proc.h | ||
dawn_thread_dispatch_proc.h | ||
dawn_wsi.h |