diff --git a/components/script/dom/domexception.rs b/components/script/dom/domexception.rs index 2267148626f..f65e0137e6a 100644 --- a/components/script/dom/domexception.rs +++ b/components/script/dom/domexception.rs @@ -132,11 +132,11 @@ impl DOMException { ) } - fn new_inherited(message_: DOMString, name_: DOMString) -> DOMException { + pub fn new_inherited(message: DOMString, name: DOMString) -> DOMException { DOMException { reflector_: Reflector::new(), - message: message_, - name: name_, + message, + name, } } diff --git a/components/script/dom/gpucomputepipeline.rs b/components/script/dom/gpucomputepipeline.rs index 0433d22e5e7..392f111ffa1 100644 --- a/components/script/dom/gpucomputepipeline.rs +++ b/components/script/dom/gpucomputepipeline.rs @@ -2,14 +2,12 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at https://mozilla.org/MPL/2.0/. */ -use std::string::String; - use dom_struct::dom_struct; use webgpu::{WebGPU, WebGPUBindGroupLayout, WebGPUComputePipeline, WebGPURequest}; use crate::dom::bindings::cell::DomRefCell; use crate::dom::bindings::codegen::Bindings::WebGPUBinding::GPUComputePipelineMethods; -use crate::dom::bindings::error::{Error, Fallible}; +use crate::dom::bindings::error::Fallible; use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::{Dom, DomRoot}; use crate::dom::bindings::str::USVString; @@ -26,43 +24,34 @@ pub struct GPUComputePipeline { label: DomRefCell, #[no_trace] compute_pipeline: WebGPUComputePipeline, - #[no_trace] - bind_group_layouts: Vec, device: Dom, } impl GPUComputePipeline { fn new_inherited( - channel: WebGPU, compute_pipeline: WebGPUComputePipeline, label: USVString, - bgls: Vec, device: &GPUDevice, ) -> Self { Self { reflector_: Reflector::new(), - channel, + channel: device.channel(), label: DomRefCell::new(label), compute_pipeline, - bind_group_layouts: bgls, device: Dom::from_ref(device), } } pub fn new( global: &GlobalScope, - channel: WebGPU, compute_pipeline: WebGPUComputePipeline, label: USVString, - bgls: Vec, device: &GPUDevice, ) -> DomRoot { reflect_dom_object( Box::new(GPUComputePipeline::new_inherited( - channel, compute_pipeline, label, - bgls, device, )), global, @@ -89,13 +78,28 @@ impl GPUComputePipelineMethods for GPUComputePipeline { /// fn GetBindGroupLayout(&self, index: u32) -> Fallible> { - if index > self.bind_group_layouts.len() as u32 { - return Err(Error::Range(String::from("Index out of bounds"))); + let id = self + .global() + .wgpu_id_hub() + .create_bind_group_layout_id(self.compute_pipeline.0.backend()); + + if let Err(e) = self + .channel + .0 + .send(WebGPURequest::ComputeGetBindGroupLayout { + device_id: self.device.id().0, + pipeline_id: self.compute_pipeline.0, + index, + id, + }) + { + warn!("Failed to send WebGPURequest::ComputeGetBindGroupLayout {e:?}"); } + Ok(GPUBindGroupLayout::new( &self.global(), self.channel.clone(), - self.bind_group_layouts[index as usize], + WebGPUBindGroupLayout(id), USVString::default(), )) } diff --git a/components/script/dom/gpudevice.rs b/components/script/dom/gpudevice.rs index 0c90b9e9e15..88842f505ef 100644 --- a/components/script/dom/gpudevice.rs +++ b/components/script/dom/gpudevice.rs @@ -14,15 +14,21 @@ use std::sync::{Arc, Mutex}; use dom_struct::dom_struct; use js::jsapi::{Heap, JSObject}; use webgpu::wgc::id::{BindGroupLayoutId, PipelineLayoutId}; +use webgpu::wgc::pipeline::RenderPipelineDescriptor; use webgpu::wgc::{ binding_model as wgpu_bind, command as wgpu_com, pipeline as wgpu_pipe, resource as wgpu_res, }; -use webgpu::{self, wgt, PopError, WebGPU, WebGPURequest, WebGPUResponse}; +use webgpu::{ + self, wgt, PopError, WebGPU, WebGPUComputePipeline, WebGPURenderPipeline, WebGPURequest, + WebGPUResponse, +}; +use super::bindings::codegen::Bindings::WebGPUBinding::GPUPipelineErrorReason; use super::bindings::codegen::UnionTypes::GPUPipelineLayoutOrGPUAutoLayoutMode; use super::bindings::error::Fallible; use super::gpu::AsyncWGPUListener; use super::gpudevicelostinfo::GPUDeviceLostInfo; +use super::gpupipelineerror::GPUPipelineError; use super::gpusupportedlimits::GPUSupportedLimits; use super::types::GPUError; use crate::dom::bindings::cell::DomRefCell; @@ -214,6 +220,118 @@ impl GPUDevice { } } + fn parse_render_pipeline( + &self, + descriptor: &GPURenderPipelineDescriptor, + ) -> ( + Option<(PipelineLayoutId, Vec)>, + RenderPipelineDescriptor<'static>, + ) { + let (layout, implicit_ids, _) = self.get_pipeline_layout_data(&descriptor.parent.layout); + + let desc = wgpu_pipe::RenderPipelineDescriptor { + label: convert_label(&descriptor.parent.parent), + layout, + cache: None, + vertex: wgpu_pipe::VertexState { + stage: wgpu_pipe::ProgrammableStageDescriptor { + module: descriptor.vertex.parent.module.id().0, + entry_point: Some(Cow::Owned(descriptor.vertex.parent.entryPoint.to_string())), + constants: Cow::Owned(HashMap::new()), + zero_initialize_workgroup_memory: true, + }, + buffers: Cow::Owned( + descriptor + .vertex + .buffers + .iter() + .map(|buffer| wgpu_pipe::VertexBufferLayout { + array_stride: buffer.arrayStride, + step_mode: match buffer.stepMode { + GPUVertexStepMode::Vertex => wgt::VertexStepMode::Vertex, + GPUVertexStepMode::Instance => wgt::VertexStepMode::Instance, + }, + attributes: Cow::Owned( + buffer + .attributes + .iter() + .map(|att| wgt::VertexAttribute { + format: convert_vertex_format(att.format), + offset: att.offset, + shader_location: att.shaderLocation, + }) + .collect::>(), + ), + }) + .collect::>(), + ), + }, + fragment: descriptor + .fragment + .as_ref() + .map(|stage| wgpu_pipe::FragmentState { + stage: wgpu_pipe::ProgrammableStageDescriptor { + module: stage.parent.module.id().0, + entry_point: Some(Cow::Owned(stage.parent.entryPoint.to_string())), + constants: Cow::Owned(HashMap::new()), + zero_initialize_workgroup_memory: true, + }, + targets: Cow::Owned( + stage + .targets + .iter() + .map(|state| { + Some(wgt::ColorTargetState { + format: convert_texture_format(state.format), + write_mask: wgt::ColorWrites::from_bits_retain(state.writeMask), + blend: state.blend.as_ref().map(|blend| wgt::BlendState { + color: convert_blend_component(&blend.color), + alpha: convert_blend_component(&blend.alpha), + }), + }) + }) + .collect::>(), + ), + }), + primitive: convert_primitive_state(&descriptor.primitive), + depth_stencil: descriptor.depthStencil.as_ref().map(|dss_desc| { + wgt::DepthStencilState { + format: convert_texture_format(dss_desc.format), + depth_write_enabled: dss_desc.depthWriteEnabled, + depth_compare: convert_compare_function(dss_desc.depthCompare), + stencil: wgt::StencilState { + front: wgt::StencilFaceState { + compare: convert_compare_function(dss_desc.stencilFront.compare), + fail_op: convert_stencil_op(dss_desc.stencilFront.failOp), + depth_fail_op: convert_stencil_op(dss_desc.stencilFront.depthFailOp), + pass_op: convert_stencil_op(dss_desc.stencilFront.passOp), + }, + back: wgt::StencilFaceState { + compare: convert_compare_function(dss_desc.stencilBack.compare), + fail_op: convert_stencil_op(dss_desc.stencilBack.failOp), + depth_fail_op: convert_stencil_op(dss_desc.stencilBack.depthFailOp), + pass_op: convert_stencil_op(dss_desc.stencilBack.passOp), + }, + read_mask: dss_desc.stencilReadMask, + write_mask: dss_desc.stencilWriteMask, + }, + bias: wgt::DepthBiasState { + constant: dss_desc.depthBias, + slope_scale: *dss_desc.depthBiasSlopeScale, + clamp: *dss_desc.depthBiasClamp, + }, + } + }), + multisample: wgt::MultisampleState { + count: descriptor.multisample.count, + mask: descriptor.multisample.mask as u64, + alpha_to_coverage_enabled: descriptor.multisample.alphaToCoverageEnabled, + }, + multiview: None, + }; + (implicit_ids, desc) + } + /// pub fn lose(&self, reason: GPUDeviceLostReason, msg: String) { let lost_promise = &(*self.lost_promise.borrow()); @@ -564,7 +682,7 @@ impl GPUDeviceMethods for GPUDevice { .wgpu_id_hub() .create_compute_pipeline_id(self.device.0.backend()); - let (layout, implicit_ids, bgls) = self.get_pipeline_layout_data(&descriptor.parent.layout); + let (layout, implicit_ids, _) = self.get_pipeline_layout_data(&descriptor.parent.layout); let desc = wgpu_pipe::ComputePipelineDescriptor { label: convert_label(&descriptor.parent.parent), @@ -585,16 +703,15 @@ impl GPUDeviceMethods for GPUDevice { compute_pipeline_id, descriptor: desc, implicit_ids, + async_sender: None, }) .expect("Failed to create WebGPU ComputePipeline"); let compute_pipeline = webgpu::WebGPUComputePipeline(compute_pipeline_id); GPUComputePipeline::new( &self.global(), - self.channel.clone(), compute_pipeline, descriptor.parent.parent.label.clone().unwrap_or_default(), - bgls, self, ) } @@ -606,7 +723,36 @@ impl GPUDeviceMethods for GPUDevice { comp: InRealm, ) -> Rc { let promise = Promise::new_in_current_realm(comp); - promise.resolve_native(&self.CreateComputePipeline(descriptor)); + let sender = response_async(&promise, self); + let compute_pipeline_id = self + .global() + .wgpu_id_hub() + .create_compute_pipeline_id(self.device.0.backend()); + + let (layout, implicit_ids, _) = self.get_pipeline_layout_data(&descriptor.parent.layout); + + let desc = wgpu_pipe::ComputePipelineDescriptor { + label: convert_label(&descriptor.parent.parent), + layout, + stage: wgpu_pipe::ProgrammableStageDescriptor { + module: descriptor.compute.module.id().0, + entry_point: Some(Cow::Owned(descriptor.compute.entryPoint.to_string())), + constants: Cow::Owned(HashMap::new()), + zero_initialize_workgroup_memory: true, + }, + cache: None, + }; + + self.channel + .0 + .send(WebGPURequest::CreateComputePipeline { + device_id: self.device.0, + compute_pipeline_id, + descriptor: desc, + implicit_ids, + async_sender: Some(sender), + }) + .expect("Failed to create WebGPU ComputePipeline"); promise } @@ -747,129 +893,7 @@ impl GPUDeviceMethods for GPUDevice { &self, descriptor: &GPURenderPipelineDescriptor, ) -> DomRoot { - let mut valid = true; - - let (layout, implicit_ids, bgls) = self.get_pipeline_layout_data(&descriptor.parent.layout); - - let desc = if valid { - Some(wgpu_pipe::RenderPipelineDescriptor { - label: convert_label(&descriptor.parent.parent), - layout, - cache: None, - vertex: wgpu_pipe::VertexState { - stage: wgpu_pipe::ProgrammableStageDescriptor { - module: descriptor.vertex.parent.module.id().0, - entry_point: Some(Cow::Owned( - descriptor.vertex.parent.entryPoint.to_string(), - )), - constants: Cow::Owned(HashMap::new()), - zero_initialize_workgroup_memory: true, - }, - buffers: Cow::Owned( - descriptor - .vertex - .buffers - .iter() - .map(|buffer| wgpu_pipe::VertexBufferLayout { - array_stride: buffer.arrayStride, - step_mode: match buffer.stepMode { - GPUVertexStepMode::Vertex => wgt::VertexStepMode::Vertex, - GPUVertexStepMode::Instance => wgt::VertexStepMode::Instance, - }, - attributes: Cow::Owned( - buffer - .attributes - .iter() - .map(|att| wgt::VertexAttribute { - format: convert_vertex_format(att.format), - offset: att.offset, - shader_location: att.shaderLocation, - }) - .collect::>(), - ), - }) - .collect::>(), - ), - }, - fragment: descriptor - .fragment - .as_ref() - .map(|stage| wgpu_pipe::FragmentState { - stage: wgpu_pipe::ProgrammableStageDescriptor { - module: stage.parent.module.id().0, - entry_point: Some(Cow::Owned(stage.parent.entryPoint.to_string())), - constants: Cow::Owned(HashMap::new()), - zero_initialize_workgroup_memory: true, - }, - targets: Cow::Owned( - stage - .targets - .iter() - .map(|state| { - Some(wgt::ColorTargetState { - format: convert_texture_format(state.format), - write_mask: match wgt::ColorWrites::from_bits( - state.writeMask, - ) { - Some(mask) => mask, - None => { - valid = false; - wgt::ColorWrites::empty() - }, - }, - blend: state.blend.as_ref().map(|blend| wgt::BlendState { - color: convert_blend_component(&blend.color), - alpha: convert_blend_component(&blend.alpha), - }), - }) - }) - .collect::>(), - ), - }), - primitive: convert_primitive_state(&descriptor.primitive), - depth_stencil: descriptor.depthStencil.as_ref().map(|dss_desc| { - wgt::DepthStencilState { - format: convert_texture_format(dss_desc.format), - depth_write_enabled: dss_desc.depthWriteEnabled, - depth_compare: convert_compare_function(dss_desc.depthCompare), - stencil: wgt::StencilState { - front: wgt::StencilFaceState { - compare: convert_compare_function(dss_desc.stencilFront.compare), - fail_op: convert_stencil_op(dss_desc.stencilFront.failOp), - depth_fail_op: convert_stencil_op( - dss_desc.stencilFront.depthFailOp, - ), - pass_op: convert_stencil_op(dss_desc.stencilFront.passOp), - }, - back: wgt::StencilFaceState { - compare: convert_compare_function(dss_desc.stencilBack.compare), - fail_op: convert_stencil_op(dss_desc.stencilBack.failOp), - depth_fail_op: convert_stencil_op(dss_desc.stencilBack.depthFailOp), - pass_op: convert_stencil_op(dss_desc.stencilBack.passOp), - }, - read_mask: dss_desc.stencilReadMask, - write_mask: dss_desc.stencilWriteMask, - }, - bias: wgt::DepthBiasState { - constant: dss_desc.depthBias, - slope_scale: *dss_desc.depthBiasSlopeScale, - clamp: *dss_desc.depthBiasClamp, - }, - } - }), - multisample: wgt::MultisampleState { - count: descriptor.multisample.count, - mask: descriptor.multisample.mask as u64, - alpha_to_coverage_enabled: descriptor.multisample.alphaToCoverageEnabled, - }, - multiview: None, - }) - } else { - self.dispatch_error(webgpu::Error::Validation(String::from( - "Invalid GPUColorWriteFlags", - ))); - None - }; + let (implicit_ids, desc) = self.parse_render_pipeline(&descriptor); let render_pipeline_id = self .global() @@ -883,6 +907,7 @@ impl GPUDeviceMethods for GPUDevice { render_pipeline_id, descriptor: desc, implicit_ids, + async_sender: None, }) .expect("Failed to create WebGPU render pipeline"); @@ -892,7 +917,6 @@ impl GPUDeviceMethods for GPUDevice { &self.global(), render_pipeline, descriptor.parent.parent.label.clone().unwrap_or_default(), - bgls, self, ) } @@ -904,7 +928,26 @@ impl GPUDeviceMethods for GPUDevice { comp: InRealm, ) -> Rc { let promise = Promise::new_in_current_realm(comp); - promise.resolve_native(&self.CreateRenderPipeline(descriptor)); + let (implicit_ids, desc) = self.parse_render_pipeline(&descriptor); + + let sender = response_async(&promise, self); + + let render_pipeline_id = self + .global() + .wgpu_id_hub() + .create_render_pipeline_id(self.device.0.backend()); + + self.channel + .0 + .send(WebGPURequest::CreateRenderPipeline { + device_id: self.device.0, + render_pipeline_id, + descriptor: desc, + implicit_ids, + async_sender: Some(sender), + }) + .expect("Failed to create WebGPU render pipeline"); + promise } @@ -1010,6 +1053,48 @@ impl AsyncWGPUListener for GPUDevice { promise.resolve_native(&error); }, }, + WebGPUResponse::ComputePipeline(result) => match result { + Ok(pipeline) => promise.resolve_native(&GPUComputePipeline::new( + &self.global(), + WebGPUComputePipeline(pipeline.id), + pipeline.label.into(), + self, + )), + Err(webgpu::Error::Validation(msg)) => { + promise.reject_native(&GPUPipelineError::new( + &self.global(), + msg.into(), + GPUPipelineErrorReason::Validation, + )) + }, + Err(webgpu::Error::OutOfMemory(msg) | webgpu::Error::Internal(msg)) => promise + .reject_native(&GPUPipelineError::new( + &self.global(), + msg.into(), + GPUPipelineErrorReason::Internal, + )), + }, + WebGPUResponse::RenderPipeline(result) => match result { + Ok(pipeline) => promise.resolve_native(&GPURenderPipeline::new( + &self.global(), + WebGPURenderPipeline(pipeline.id), + pipeline.label.into(), + self, + )), + Err(webgpu::Error::Validation(msg)) => { + promise.reject_native(&GPUPipelineError::new( + &self.global(), + msg.into(), + GPUPipelineErrorReason::Validation, + )) + }, + Err(webgpu::Error::OutOfMemory(msg) | webgpu::Error::Internal(msg)) => promise + .reject_native(&GPUPipelineError::new( + &self.global(), + msg.into(), + GPUPipelineErrorReason::Internal, + )), + }, _ => unreachable!("Wrong response received on AsyncWGPUListener for GPUDevice"), } } diff --git a/components/script/dom/gpupipelineerror.rs b/components/script/dom/gpupipelineerror.rs new file mode 100644 index 00000000000..e532e30a4b5 --- /dev/null +++ b/components/script/dom/gpupipelineerror.rs @@ -0,0 +1,70 @@ +/* This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at https://mozilla.org/MPL/2.0/. */ + +use dom_struct::dom_struct; +use js::rust::HandleObject; + +use super::bindings::codegen::Bindings::WebGPUBinding::{ + GPUPipelineErrorInit, GPUPipelineErrorMethods, GPUPipelineErrorReason, +}; +use crate::dom::bindings::reflector::reflect_dom_object_with_proto; +use crate::dom::bindings::root::DomRoot; +use crate::dom::bindings::str::DOMString; +use crate::dom::domexception::DOMException; +use crate::dom::globalscope::GlobalScope; + +/// +#[dom_struct] +pub struct GPUPipelineError { + exception: DOMException, + reason: GPUPipelineErrorReason, +} + +impl GPUPipelineError { + fn new_inherited(message: DOMString, reason: GPUPipelineErrorReason) -> Self { + Self { + exception: DOMException::new_inherited(message, "GPUPipelineError".into()), + reason, + } + } + + pub fn new_with_proto( + global: &GlobalScope, + proto: Option, + message: DOMString, + reason: GPUPipelineErrorReason, + ) -> DomRoot { + reflect_dom_object_with_proto( + Box::new(Self::new_inherited(message, reason)), + global, + proto, + ) + } + + pub fn new( + global: &GlobalScope, + message: DOMString, + reason: GPUPipelineErrorReason, + ) -> DomRoot { + Self::new_with_proto(global, None, message, reason) + } + + /// + #[allow(non_snake_case)] + pub fn Constructor( + global: &GlobalScope, + proto: Option, + message: DOMString, + options: &GPUPipelineErrorInit, + ) -> DomRoot { + Self::new_with_proto(global, proto, message, options.reason) + } +} + +impl GPUPipelineErrorMethods for GPUPipelineError { + /// + fn Reason(&self) -> GPUPipelineErrorReason { + self.reason + } +} diff --git a/components/script/dom/gpurenderpipeline.rs b/components/script/dom/gpurenderpipeline.rs index cf2dc885ce4..9b4e64198ab 100644 --- a/components/script/dom/gpurenderpipeline.rs +++ b/components/script/dom/gpurenderpipeline.rs @@ -2,14 +2,12 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at https://mozilla.org/MPL/2.0/. */ -use std::string::String; - use dom_struct::dom_struct; use webgpu::{WebGPU, WebGPUBindGroupLayout, WebGPURenderPipeline, WebGPURequest}; use crate::dom::bindings::cell::DomRefCell; use crate::dom::bindings::codegen::Bindings::WebGPUBinding::GPURenderPipelineMethods; -use crate::dom::bindings::error::{Error, Fallible}; +use crate::dom::bindings::error::Fallible; use crate::dom::bindings::reflector::{reflect_dom_object, DomObject, Reflector}; use crate::dom::bindings::root::{Dom, DomRoot}; use crate::dom::bindings::str::USVString; @@ -26,8 +24,6 @@ pub struct GPURenderPipeline { label: DomRefCell, #[no_trace] render_pipeline: WebGPURenderPipeline, - #[no_trace] - bind_group_layouts: Vec, device: Dom, } @@ -35,7 +31,6 @@ impl GPURenderPipeline { fn new_inherited( render_pipeline: WebGPURenderPipeline, label: USVString, - bgls: Vec, device: &GPUDevice, ) -> Self { Self { @@ -43,7 +38,6 @@ impl GPURenderPipeline { channel: device.channel(), label: DomRefCell::new(label), render_pipeline, - bind_group_layouts: bgls, device: Dom::from_ref(device), } } @@ -52,14 +46,12 @@ impl GPURenderPipeline { global: &GlobalScope, render_pipeline: WebGPURenderPipeline, label: USVString, - bgls: Vec, device: &GPUDevice, ) -> DomRoot { reflect_dom_object( Box::new(GPURenderPipeline::new_inherited( render_pipeline, label, - bgls, device, )), global, @@ -86,13 +78,28 @@ impl GPURenderPipelineMethods for GPURenderPipeline { /// fn GetBindGroupLayout(&self, index: u32) -> Fallible> { - if index > self.bind_group_layouts.len() as u32 { - return Err(Error::Range(String::from("Index out of bounds"))); + let id = self + .global() + .wgpu_id_hub() + .create_bind_group_layout_id(self.render_pipeline.0.backend()); + + if let Err(e) = self + .channel + .0 + .send(WebGPURequest::RenderGetBindGroupLayout { + device_id: self.device.id().0, + pipeline_id: self.render_pipeline.0, + index, + id, + }) + { + warn!("Failed to send WebGPURequest::RenderGetBindGroupLayout {e:?}"); } + Ok(GPUBindGroupLayout::new( &self.global(), self.channel.clone(), - self.bind_group_layouts[index as usize], + WebGPUBindGroupLayout(id), USVString::default(), )) } diff --git a/components/script/dom/mod.rs b/components/script/dom/mod.rs index 8c1d40ea8af..083c16608ef 100644 --- a/components/script/dom/mod.rs +++ b/components/script/dom/mod.rs @@ -346,6 +346,7 @@ pub mod gpuerror; pub mod gpuinternalerror; pub mod gpumapmode; pub mod gpuoutofmemoryerror; +pub mod gpupipelineerror; pub mod gpupipelinelayout; pub mod gpuqueryset; pub mod gpuqueue; diff --git a/components/script/dom/webidls/WebGPU.webidl b/components/script/dom/webidls/WebGPU.webidl index e1ec5da3226..e03d48c8211 100644 --- a/components/script/dom/webidls/WebGPU.webidl +++ b/components/script/dom/webidls/WebGPU.webidl @@ -518,6 +518,21 @@ interface GPUCompilationInfo { readonly attribute any messages; }; +[Exposed=(Window, Worker), Pref="dom.webgpu.enabled"] +interface GPUPipelineError : DOMException { + constructor(optional DOMString message = "", GPUPipelineErrorInit options); + readonly attribute GPUPipelineErrorReason reason; +}; + +dictionary GPUPipelineErrorInit { + required GPUPipelineErrorReason reason; +}; + +enum GPUPipelineErrorReason { + "validation", + "internal", +}; + enum GPUAutoLayoutMode { "auto" }; diff --git a/components/webgpu/ipc_messages/recv.rs b/components/webgpu/ipc_messages/recv.rs index 2efbf62758c..b38856c851b 100644 --- a/components/webgpu/ipc_messages/recv.rs +++ b/components/webgpu/ipc_messages/recv.rs @@ -103,6 +103,8 @@ pub enum WebGPURequest { compute_pipeline_id: id::ComputePipelineId, descriptor: ComputePipelineDescriptor<'static>, implicit_ids: Option<(id::PipelineLayoutId, Vec)>, + /// present only on ASYNC versions + async_sender: Option>, }, CreateContext(IpcSender), CreatePipelineLayout { @@ -113,8 +115,10 @@ pub enum WebGPURequest { CreateRenderPipeline { device_id: id::DeviceId, render_pipeline_id: id::RenderPipelineId, - descriptor: Option>, + descriptor: RenderPipelineDescriptor<'static>, implicit_ids: Option<(id::PipelineLayoutId, Vec)>, + /// present only on ASYNC versions + async_sender: Option>, }, CreateSampler { device_id: id::DeviceId, @@ -301,4 +305,16 @@ pub enum WebGPURequest { device_id: id::DeviceId, sender: IpcSender, }, + ComputeGetBindGroupLayout { + device_id: id::DeviceId, + pipeline_id: id::ComputePipelineId, + index: u32, + id: id::BindGroupLayoutId, + }, + RenderGetBindGroupLayout { + device_id: id::DeviceId, + pipeline_id: id::RenderPipelineId, + index: u32, + id: id::BindGroupLayoutId, + }, } diff --git a/components/webgpu/ipc_messages/to_dom.rs b/components/webgpu/ipc_messages/to_dom.rs index ef64675e82a..b38e21c3038 100644 --- a/components/webgpu/ipc_messages/to_dom.rs +++ b/components/webgpu/ipc_messages/to_dom.rs @@ -6,6 +6,7 @@ use ipc_channel::ipc::IpcSharedMemory; use serde::{Deserialize, Serialize}; +use wgc::id; use wgc::pipeline::CreateShaderModuleError; use wgpu_core::instance::{RequestAdapterError, RequestDeviceError}; use wgpu_core::resource::BufferAccessError; @@ -65,6 +66,12 @@ pub struct Adapter { pub channel: WebGPU, } +#[derive(Debug, Deserialize, Serialize)] +pub struct Pipeline { + pub id: T, + pub label: String, +} + #[derive(Debug, Deserialize, Serialize)] #[allow(clippy::large_enum_variant)] pub enum WebGPUResponse { @@ -82,4 +89,6 @@ pub enum WebGPUResponse { SubmittedWorkDone, PoppedErrorScope(Result, PopError>), CompilationInfo(Option), + RenderPipeline(Result, Error>), + ComputePipeline(Result, Error>), } diff --git a/components/webgpu/wgpu_thread.rs b/components/webgpu/wgpu_thread.rs index 6d7acaa739c..f213b8570f3 100644 --- a/components/webgpu/wgpu_thread.rs +++ b/components/webgpu/wgpu_thread.rs @@ -29,6 +29,8 @@ use wgc::pipeline::ShaderModuleDescriptor; use wgc::resource::{BufferMapCallback, BufferMapOperation}; use wgc::{gfx_select, id}; use wgpu_core::command::RenderPassDescriptor; +use wgpu_core::device::DeviceError; +use wgpu_core::pipeline::{CreateComputePipelineError, CreateRenderPipelineError}; use wgpu_core::resource::BufferAccessResult; use wgpu_types::MemoryHints; use wgt::InstanceDescriptor; @@ -38,8 +40,8 @@ use crate::gpu_error::ErrorScope; use crate::poll_thread::Poller; use crate::render_commands::apply_render_command; use crate::{ - Adapter, ComputePassId, Error, PopError, PresentationData, RenderPassId, WebGPU, WebGPUAdapter, - WebGPUDevice, WebGPUMsg, WebGPUQueue, WebGPURequest, WebGPUResponse, + Adapter, ComputePassId, Error, Pipeline, PopError, PresentationData, RenderPassId, WebGPU, + WebGPUAdapter, WebGPUDevice, WebGPUMsg, WebGPUQueue, WebGPURequest, WebGPUResponse, }; pub const PRESENTATION_BUFFER_COUNT: usize = 10; @@ -378,6 +380,7 @@ impl WGPU { compute_pipeline_id, descriptor, implicit_ids, + async_sender: sender, } => { let global = &self.global; let bgls = implicit_ids @@ -399,7 +402,24 @@ impl WGPU { implicit ) ); - self.maybe_dispatch_wgpu_error(device_id, error); + if let Some(sender) = sender { + let res = match error { + // if device is lost we must return pipeline and not raise any error + Some(CreateComputePipelineError::Device( + DeviceError::Lost | DeviceError::Invalid(_), + )) | + None => Ok(Pipeline { + id: compute_pipeline_id, + label: descriptor.label.unwrap_or_default().to_string(), + }), + Some(e) => Err(Error::from_error(e)), + }; + if let Err(e) = sender.send(WebGPUResponse::ComputePipeline(res)) { + warn!("Failed sending WebGPUResponse::ComputePipeline {e:?}"); + } + } else { + self.maybe_dispatch_wgpu_error(device_id, error); + } }, WebGPURequest::CreateContext(sender) => { let id = self @@ -426,6 +446,7 @@ impl WGPU { render_pipeline_id, descriptor, implicit_ids, + async_sender: sender, } => { let global = &self.global; let bgls = implicit_ids @@ -440,14 +461,30 @@ impl WGPU { root_id: *layout, group_ids: bgls.as_slice(), }); - if let Some(desc) = descriptor { - let (_, error) = gfx_select!(render_pipeline_id => - global.device_create_render_pipeline( - device_id, - &desc, - Some(render_pipeline_id), - implicit) - ); + let (_, error) = gfx_select!(render_pipeline_id => + global.device_create_render_pipeline( + device_id, + &descriptor, + Some(render_pipeline_id), + implicit) + ); + + if let Some(sender) = sender { + let res = match error { + // if device is lost we must return pipeline and not raise any error + Some(CreateRenderPipelineError::Device( + DeviceError::Lost | DeviceError::Invalid(_), + )) | + None => Ok(Pipeline { + id: render_pipeline_id, + label: descriptor.label.unwrap_or_default().to_string(), + }), + Some(e) => Err(Error::from_error(e)), + }; + if let Err(e) = sender.send(WebGPUResponse::RenderPipeline(res)) { + warn!("Failed sending WebGPUResponse::RenderPipeline {e:?}"); + } + } else { self.maybe_dispatch_wgpu_error(device_id, error); } }, @@ -1407,6 +1444,28 @@ impl WGPU { } } }, + WebGPURequest::ComputeGetBindGroupLayout { + device_id, + pipeline_id, + index, + id, + } => { + let global = &self.global; + let (_, error) = gfx_select!(pipeline_id => + global.compute_pipeline_get_bind_group_layout(pipeline_id, index, Some(id))); + self.maybe_dispatch_wgpu_error(device_id, error); + }, + WebGPURequest::RenderGetBindGroupLayout { + device_id, + pipeline_id, + index, + id, + } => { + let global = &self.global; + let (_, error) = gfx_select!(pipeline_id => + global.render_pipeline_get_bind_group_layout(pipeline_id, index, Some(id))); + self.maybe_dispatch_wgpu_error(device_id, error); + }, } } } diff --git a/tests/wpt/webgpu/meta/webgpu/cts.https.html.ini b/tests/wpt/webgpu/meta/webgpu/cts.https.html.ini index 3a4bcc96925..d858b0cc539 100644 --- a/tests/wpt/webgpu/meta/webgpu/cts.https.html.ini +++ b/tests/wpt/webgpu/meta/webgpu/cts.https.html.ini @@ -13589,44 +13589,24 @@ [:limitTest="atDefault";testValueName="overLimit";async=false;sampleCount=4;interleaveFormat="rgba8unorm"] [:limitTest="atDefault";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="r8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atDefault";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rg16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atDefault";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rg8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atDefault";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rgba16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atDefault";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rgba8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atDefault";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="r8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atDefault";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rg16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atDefault";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rg8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atDefault";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rgba16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atDefault";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rgba8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="atLimit";async=false;sampleCount=1;interleaveFormat="r8unorm"] @@ -13709,44 +13689,24 @@ [:limitTest="atMaximum";testValueName="overLimit";async=false;sampleCount=4;interleaveFormat="rgba8unorm"] [:limitTest="atMaximum";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="r8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rg16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rg8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rgba16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rgba8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="r8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rg16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rg8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rgba16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rgba8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="atLimit";async=false;sampleCount=1;interleaveFormat="r8unorm"] @@ -13829,44 +13789,24 @@ [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=false;sampleCount=4;interleaveFormat="rgba8unorm"] [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="r8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rg16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rg8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rgba16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rgba8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="r8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rg16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rg8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rgba16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rgba8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="overMaximum";testValueName="atLimit";async=false;sampleCount=1;interleaveFormat="r8unorm"] expected: @@ -14109,44 +14049,24 @@ [:limitTest="underDefault";testValueName="overLimit";async=false;sampleCount=4;interleaveFormat="rgba8unorm"] [:limitTest="underDefault";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="r8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="underDefault";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rg16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="underDefault";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rg8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="underDefault";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rgba16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="underDefault";testValueName="overLimit";async=true;sampleCount=1;interleaveFormat="rgba8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="underDefault";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="r8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="underDefault";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rg16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="underDefault";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rg8unorm"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="underDefault";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rgba16float"] - expected: - if os == "linux" and not debug: FAIL [:limitTest="underDefault";testValueName="overLimit";async=true;sampleCount=4;interleaveFormat="rgba8unorm"] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,capability_checks,limits,maxColorAttachments:beginRenderPass,at_over:*] @@ -14241,8 +14161,6 @@ [:limitTest="atDefault";testValueName="overLimit";async=false] [:limitTest="atDefault";testValueName="overLimit";async=true] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="atLimit";async=false] @@ -14251,8 +14169,6 @@ [:limitTest="atMaximum";testValueName="overLimit";async=false] [:limitTest="atMaximum";testValueName="overLimit";async=true] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="atLimit";async=false] @@ -14261,8 +14177,6 @@ [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=false] [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true] - expected: - if os == "linux" and not debug: FAIL [:limitTest="overMaximum";testValueName="atLimit";async=false] expected: @@ -14287,8 +14201,6 @@ [:limitTest="underDefault";testValueName="overLimit";async=false] [:limitTest="underDefault";testValueName="overLimit";async=true] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,capability_checks,limits,maxColorAttachments:validate,kMaxColorAttachmentsToTest:*] @@ -14617,12 +14529,8 @@ if os == "linux" and not debug: FAIL [:limitTest="atDefault";testValueName="overLimit";async=true;pointList=false;frontFacing=false;sampleIndex=false;sampleMaskIn=false;sampleMaskOut=false] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atDefault";testValueName="overLimit";async=true;pointList=false;frontFacing=false;sampleIndex=false;sampleMaskIn=false;sampleMaskOut=true] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atDefault";testValueName="overLimit";async=true;pointList=false;frontFacing=false;sampleIndex=false;sampleMaskIn=true;sampleMaskOut=false] expected: @@ -14997,12 +14905,8 @@ if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="overLimit";async=true;pointList=false;frontFacing=false;sampleIndex=false;sampleMaskIn=false;sampleMaskOut=false] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="overLimit";async=true;pointList=false;frontFacing=false;sampleIndex=false;sampleMaskIn=false;sampleMaskOut=true] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="overLimit";async=true;pointList=false;frontFacing=false;sampleIndex=false;sampleMaskIn=true;sampleMaskOut=false] expected: @@ -15377,12 +15281,8 @@ if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true;pointList=false;frontFacing=false;sampleIndex=false;sampleMaskIn=false;sampleMaskOut=false] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true;pointList=false;frontFacing=false;sampleIndex=false;sampleMaskIn=false;sampleMaskOut=true] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true;pointList=false;frontFacing=false;sampleIndex=false;sampleMaskIn=true;sampleMaskOut=false] expected: @@ -16285,8 +16185,6 @@ [:limitTest="atDefault";testValueName="overLimit";async=false] [:limitTest="atDefault";testValueName="overLimit";async=true] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="atLimit";async=false] expected: @@ -16299,8 +16197,6 @@ [:limitTest="atMaximum";testValueName="overLimit";async=false] [:limitTest="atMaximum";testValueName="overLimit";async=true] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="atLimit";async=false] expected: @@ -16313,8 +16209,6 @@ [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=false] [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true] - expected: - if os == "linux" and not debug: FAIL [:limitTest="overMaximum";testValueName="atLimit";async=false] expected: @@ -16343,8 +16237,6 @@ [:limitTest="underDefault";testValueName="overLimit";async=false] [:limitTest="underDefault";testValueName="overLimit";async=true] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,capability_checks,limits,maxSampledTexturesPerShaderStage:createBindGroupLayout,at_over:*] @@ -18776,8 +18668,6 @@ [:limitTest="atDefault";testValueName="overLimit";async=false] [:limitTest="atDefault";testValueName="overLimit";async=true] - expected: - if os == "linux" and not debug: FAIL [:limitTest="atMaximum";testValueName="atLimit";async=false] expected: @@ -18790,8 +18680,6 @@ [:limitTest="atMaximum";testValueName="overLimit";async=false] [:limitTest="atMaximum";testValueName="overLimit";async=true] - expected: - if os == "linux" and not debug: FAIL [:limitTest="betweenDefaultAndMaximum";testValueName="atLimit";async=false] expected: @@ -18804,8 +18692,6 @@ [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=false] [:limitTest="betweenDefaultAndMaximum";testValueName="overLimit";async=true] - expected: - if os == "linux" and not debug: FAIL [:limitTest="overMaximum";testValueName="atLimit";async=false] @@ -18826,8 +18712,6 @@ [:limitTest="underDefault";testValueName="overLimit";async=false] [:limitTest="underDefault";testValueName="overLimit";async=true] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,capability_checks,limits,maxVertexBufferArrayStride:createRenderPipeline,at_over:*] @@ -19024,20 +18908,14 @@ [:isAsync=true;size=[1,1,64\]] [:isAsync=true;size=[1,1,65\]] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;size=[1,256,1\]] [:isAsync=true;size=[1,257,1\]] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;size=[256,1,1\]] [:isAsync=true;size=[257,1,1\]] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;size=[64\]] @@ -19058,20 +18936,14 @@ [:isAsync=true;size=[1,8,32\]] [:isAsync=true;size=[1,8,33\]] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;size=[128,1,2\]] [:isAsync=true;size=[129,1,2\]] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;size=[2,128,1\]] [:isAsync=true;size=[2,129,1\]] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,compute_pipeline:limits,workgroup_storage_size:*] @@ -19196,12 +19068,8 @@ if os == "linux" and not debug: FAIL [:isAsync=true;constants={"c0":0,"c2":0,"c8":0}] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;constants={}] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,compute_pipeline:overrides,value,type_error:*] @@ -19462,8 +19330,6 @@ [cts.https.html?q=webgpu:api,validation,compute_pipeline:pipeline_layout,device_mismatch:*] [:] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,compute_pipeline:resource_compatibility:*] @@ -19774,26 +19640,18 @@ [:isAsync=true;shaderModuleStage="compute"] [:isAsync=true;shaderModuleStage="fragment"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;shaderModuleStage="vertex"] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,compute_pipeline:shader_module,device_mismatch:*] [:] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,compute_pipeline:shader_module,invalid:*] [:isAsync=false] [:isAsync=true] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,createBindGroup:bind_group_layout,device_mismatch:*] @@ -33433,17 +33291,39 @@ [cts.https.html?q=webgpu:api,validation,getBindGroupLayout:index_range,auto_layout:*] - expected: - if os == "linux" and not debug: CRASH + [:index=0] + expected: + if os == "linux" and not debug: FAIL + + [:index=1] + + [:index=2] + + [:index=3] + + [:index=4] + + [:index=5] [cts.https.html?q=webgpu:api,validation,getBindGroupLayout:index_range,explicit_layout:*] - expected: - if os == "linux" and not debug: CRASH + [:index=0] + + [:index=1] + + [:index=2] + + [:index=3] + + [:index=4] + + [:index=5] [cts.https.html?q=webgpu:api,validation,getBindGroupLayout:unique_js_object,auto_layout:*] [:] + expected: + if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,getBindGroupLayout:unique_js_object,explicit_layout:*] @@ -50668,60 +50548,32 @@ [:isAsync=true;format="astc-8x8-unorm-srgb"] [:isAsync=true;format="bc1-rgba-unorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc1-rgba-unorm-srgb"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc2-rgba-unorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc2-rgba-unorm-srgb"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc3-rgba-unorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc3-rgba-unorm-srgb"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc4-r-snorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc4-r-unorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc5-rg-snorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc5-rg-unorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc6h-rgb-float"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc6h-rgb-ufloat"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc7-rgba-unorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc7-rgba-unorm-srgb"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bgra8unorm"] expected: @@ -50794,8 +50646,6 @@ if os == "linux" and not debug: FAIL [:isAsync=true;format="r8snorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="r8uint"] expected: @@ -50838,8 +50688,6 @@ if os == "linux" and not debug: FAIL [:isAsync=true;format="rg8snorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rg8uint"] expected: @@ -50890,8 +50738,6 @@ if os == "linux" and not debug: FAIL [:isAsync=true;format="rgba8snorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rgba8uint"] expected: @@ -51312,64 +51158,36 @@ [:isAsync=true;format="depth24plus";face="back";compare="always"] [:isAsync=true;format="depth24plus";face="back";compare="equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";face="back";compare="greater"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";face="back";compare="greater-equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";face="back";compare="less"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";face="back";compare="less-equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";face="back";compare="never"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";face="back";compare="not-equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";face="front";compare="_undef_"] [:isAsync=true;format="depth24plus";face="front";compare="always"] [:isAsync=true;format="depth24plus";face="front";compare="equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";face="front";compare="greater"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";face="front";compare="greater-equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";face="front";compare="less"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";face="front";compare="less-equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";face="front";compare="never"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";face="front";compare="not-equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus-stencil8";face="back";compare="_undef_"] @@ -51412,64 +51230,36 @@ [:isAsync=true;format="depth32float";face="back";compare="always"] [:isAsync=true;format="depth32float";face="back";compare="equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";face="back";compare="greater"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";face="back";compare="greater-equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";face="back";compare="less"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";face="back";compare="less-equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";face="back";compare="never"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";face="back";compare="not-equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";face="front";compare="_undef_"] [:isAsync=true;format="depth32float";face="front";compare="always"] [:isAsync=true;format="depth32float";face="front";compare="equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";face="front";compare="greater"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";face="front";compare="greater-equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";face="front";compare="less"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";face="front";compare="less-equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";face="front";compare="never"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";face="front";compare="not-equal"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float-stencil8";face="back";compare="_undef_"] expected: @@ -52808,194 +52598,110 @@ [:isAsync=true;format="depth24plus";faceAndOpType="backDepthFailOp";op="_undef_"] [:isAsync=true;format="depth24plus";faceAndOpType="backDepthFailOp";op="decrement-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backDepthFailOp";op="decrement-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backDepthFailOp";op="increment-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backDepthFailOp";op="increment-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backDepthFailOp";op="invert"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backDepthFailOp";op="keep"] [:isAsync=true;format="depth24plus";faceAndOpType="backDepthFailOp";op="replace"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backDepthFailOp";op="zero"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backFailOp";op="_undef_"] [:isAsync=true;format="depth24plus";faceAndOpType="backFailOp";op="decrement-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backFailOp";op="decrement-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backFailOp";op="increment-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backFailOp";op="increment-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backFailOp";op="invert"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backFailOp";op="keep"] [:isAsync=true;format="depth24plus";faceAndOpType="backFailOp";op="replace"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backFailOp";op="zero"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backPassOp";op="_undef_"] [:isAsync=true;format="depth24plus";faceAndOpType="backPassOp";op="decrement-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backPassOp";op="decrement-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backPassOp";op="increment-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backPassOp";op="increment-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backPassOp";op="invert"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backPassOp";op="keep"] [:isAsync=true;format="depth24plus";faceAndOpType="backPassOp";op="replace"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="backPassOp";op="zero"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontDepthFailOp";op="_undef_"] [:isAsync=true;format="depth24plus";faceAndOpType="frontDepthFailOp";op="decrement-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontDepthFailOp";op="decrement-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontDepthFailOp";op="increment-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontDepthFailOp";op="increment-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontDepthFailOp";op="invert"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontDepthFailOp";op="keep"] [:isAsync=true;format="depth24plus";faceAndOpType="frontDepthFailOp";op="replace"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontDepthFailOp";op="zero"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontFailOp";op="_undef_"] [:isAsync=true;format="depth24plus";faceAndOpType="frontFailOp";op="decrement-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontFailOp";op="decrement-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontFailOp";op="increment-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontFailOp";op="increment-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontFailOp";op="invert"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontFailOp";op="keep"] [:isAsync=true;format="depth24plus";faceAndOpType="frontFailOp";op="replace"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontFailOp";op="zero"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontPassOp";op="_undef_"] [:isAsync=true;format="depth24plus";faceAndOpType="frontPassOp";op="decrement-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontPassOp";op="decrement-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontPassOp";op="increment-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontPassOp";op="increment-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontPassOp";op="invert"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontPassOp";op="keep"] [:isAsync=true;format="depth24plus";faceAndOpType="frontPassOp";op="replace"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus";faceAndOpType="frontPassOp";op="zero"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth24plus-stencil8";faceAndOpType="backDepthFailOp";op="_undef_"] @@ -53108,194 +52814,110 @@ [:isAsync=true;format="depth32float";faceAndOpType="backDepthFailOp";op="_undef_"] [:isAsync=true;format="depth32float";faceAndOpType="backDepthFailOp";op="decrement-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backDepthFailOp";op="decrement-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backDepthFailOp";op="increment-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backDepthFailOp";op="increment-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backDepthFailOp";op="invert"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backDepthFailOp";op="keep"] [:isAsync=true;format="depth32float";faceAndOpType="backDepthFailOp";op="replace"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backDepthFailOp";op="zero"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backFailOp";op="_undef_"] [:isAsync=true;format="depth32float";faceAndOpType="backFailOp";op="decrement-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backFailOp";op="decrement-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backFailOp";op="increment-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backFailOp";op="increment-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backFailOp";op="invert"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backFailOp";op="keep"] [:isAsync=true;format="depth32float";faceAndOpType="backFailOp";op="replace"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backFailOp";op="zero"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backPassOp";op="_undef_"] [:isAsync=true;format="depth32float";faceAndOpType="backPassOp";op="decrement-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backPassOp";op="decrement-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backPassOp";op="increment-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backPassOp";op="increment-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backPassOp";op="invert"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backPassOp";op="keep"] [:isAsync=true;format="depth32float";faceAndOpType="backPassOp";op="replace"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="backPassOp";op="zero"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontDepthFailOp";op="_undef_"] [:isAsync=true;format="depth32float";faceAndOpType="frontDepthFailOp";op="decrement-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontDepthFailOp";op="decrement-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontDepthFailOp";op="increment-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontDepthFailOp";op="increment-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontDepthFailOp";op="invert"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontDepthFailOp";op="keep"] [:isAsync=true;format="depth32float";faceAndOpType="frontDepthFailOp";op="replace"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontDepthFailOp";op="zero"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontFailOp";op="_undef_"] [:isAsync=true;format="depth32float";faceAndOpType="frontFailOp";op="decrement-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontFailOp";op="decrement-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontFailOp";op="increment-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontFailOp";op="increment-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontFailOp";op="invert"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontFailOp";op="keep"] [:isAsync=true;format="depth32float";faceAndOpType="frontFailOp";op="replace"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontFailOp";op="zero"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontPassOp";op="_undef_"] [:isAsync=true;format="depth32float";faceAndOpType="frontPassOp";op="decrement-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontPassOp";op="decrement-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontPassOp";op="increment-clamp"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontPassOp";op="increment-wrap"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontPassOp";op="invert"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontPassOp";op="keep"] [:isAsync=true;format="depth32float";faceAndOpType="frontPassOp";op="replace"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float";faceAndOpType="frontPassOp";op="zero"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="depth32float-stencil8";faceAndOpType="backDepthFailOp";op="_undef_"] expected: @@ -53734,18 +53356,12 @@ [:isAsync=false] [:isAsync=true] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,fragment_state:limits,maxColorAttachmentBytesPerSample,aligned:*] [:format="bgra8unorm"] - expected: - if os == "linux" and not debug: FAIL [:format="bgra8unorm-srgb"] - expected: - if os == "linux" and not debug: FAIL [:format="r16float"] @@ -53772,16 +53388,10 @@ [:format="rg16uint"] [:format="rg32float"] - expected: - if os == "linux" and not debug: FAIL [:format="rg32sint"] - expected: - if os == "linux" and not debug: FAIL [:format="rg32uint"] - expected: - if os == "linux" and not debug: FAIL [:format="rg8sint"] @@ -53794,52 +53404,32 @@ if os == "linux" and not debug: FAIL [:format="rgb10a2unorm"] - expected: - if os == "linux" and not debug: FAIL [:format="rgba16float"] - expected: - if os == "linux" and not debug: FAIL [:format="rgba16sint"] - expected: - if os == "linux" and not debug: FAIL [:format="rgba16uint"] - expected: - if os == "linux" and not debug: FAIL [:format="rgba32float"] - expected: - if os == "linux" and not debug: FAIL [:format="rgba32sint"] - expected: - if os == "linux" and not debug: FAIL [:format="rgba32uint"] - expected: - if os == "linux" and not debug: FAIL [:format="rgba8sint"] [:format="rgba8uint"] [:format="rgba8unorm"] - expected: - if os == "linux" and not debug: FAIL [:format="rgba8unorm-srgb"] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,fragment_state:limits,maxColorAttachmentBytesPerSample,unaligned:*] [:formats=["r32float","rgba8unorm","rgba32float","r8unorm","r8unorm"\]] [:formats=["r8unorm","r32float","rgba8unorm","rgba32float","r8unorm"\]] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,fragment_state:limits,maxColorAttachments:*] @@ -53850,8 +53440,6 @@ [:isAsync=true;targetsLengthVariant={"mult":1,"add":0}] [:isAsync=true;targetsLengthVariant={"mult":1,"add":1}] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,fragment_state:pipeline_output_targets,blend:*] @@ -53898,16 +53486,10 @@ [:isAsync=false;format="rgba8unorm";componentCount=4] [:isAsync=true;format="bgra8unorm";componentCount=1] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bgra8unorm";componentCount=2] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bgra8unorm";componentCount=3] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bgra8unorm";componentCount=4] @@ -53926,8 +53508,6 @@ [:isAsync=true;format="r8unorm";componentCount=4] [:isAsync=true;format="rg8unorm";componentCount=1] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rg8unorm";componentCount=2] expected: @@ -53940,16 +53520,10 @@ [:isAsync=true;format="rg8unorm";componentCount=4] [:isAsync=true;format="rgba8unorm";componentCount=1] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rgba8unorm";componentCount=2] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rgba8unorm";componentCount=3] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rgba8unorm";componentCount=4] @@ -54308,64 +53882,36 @@ [:isAsync=true;format="r16float"] [:isAsync=true;format="r16sint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="r16uint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="r32float"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="r32sint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="r32uint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="r8sint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="r8uint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="r8unorm"] [:isAsync=true;format="rg16float"] [:isAsync=true;format="rg16sint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rg16uint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rg32float"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rg32sint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rg32uint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rg8sint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rg8uint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rg8unorm"] @@ -54378,32 +53924,18 @@ [:isAsync=true;format="rgba16float"] [:isAsync=true;format="rgba16sint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rgba16uint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rgba32float"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rgba32sint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rgba32uint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rgba8sint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rgba8uint"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rgba8unorm"] @@ -54422,20 +53954,14 @@ [:format="depth24plus";isAsync=false] [:format="depth24plus";isAsync=true] - expected: - if os == "linux" and not debug: FAIL [:format="depth24plus-stencil8";isAsync=false] [:format="depth24plus-stencil8";isAsync=true] - expected: - if os == "linux" and not debug: FAIL [:format="depth32float";isAsync=false] [:format="depth32float";isAsync=true] - expected: - if os == "linux" and not debug: FAIL [:format="depth32float-stencil8";isAsync=false] expected: @@ -54448,8 +53974,6 @@ [:format="rgba8unorm";isAsync=false] [:format="rgba8unorm";isAsync=true] - expected: - if os == "linux" and not debug: FAIL [:format="stencil8";isAsync=false] expected: @@ -54720,60 +54244,32 @@ [:isAsync=true;format="astc-8x8-unorm-srgb"] [:isAsync=true;format="bc1-rgba-unorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc1-rgba-unorm-srgb"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc2-rgba-unorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc2-rgba-unorm-srgb"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc3-rgba-unorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc3-rgba-unorm-srgb"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc4-r-snorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc4-r-unorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc5-rg-snorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc5-rg-unorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc6h-rgb-float"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc6h-rgb-ufloat"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc7-rgba-unorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bc7-rgba-unorm-srgb"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="bgra8unorm"] @@ -54834,8 +54330,6 @@ [:isAsync=true;format="r8sint"] [:isAsync=true;format="r8snorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="r8uint"] @@ -54860,8 +54354,6 @@ [:isAsync=true;format="rg8sint"] [:isAsync=true;format="rg8snorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rg8uint"] @@ -54892,8 +54384,6 @@ [:isAsync=true;format="rgba8sint"] [:isAsync=true;format="rgba8snorm"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;format="rgba8uint"] @@ -54912,25 +54402,16 @@ [:isAsync=false;writeMask=15] [:isAsync=false;writeMask=16] - expected: - if os == "linux" and not debug: FAIL [:isAsync=false;writeMask=2147483649] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;writeMask=0] [:isAsync=true;writeMask=15] [:isAsync=true;writeMask=16] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;writeMask=2147483649] - expected: - if os == "linux" and not debug: FAIL - [cts.https.html?q=webgpu:api,validation,render_pipeline,inter_stage:interpolation_sampling:*] [:isAsync=false;output="%40interpolate(flat)";input="%40interpolate(flat)"] @@ -54974,20 +54455,12 @@ if os == "linux" and not debug: FAIL [:isAsync=true;output="%40interpolate(perspective)";input="%40interpolate(perspective,%20sample)"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;output="%40interpolate(perspective,%20center)";input="%40interpolate(perspective,%20centroid)"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;output="%40interpolate(perspective,%20center)";input="%40interpolate(perspective,%20sample)"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;output="%40interpolate(perspective,%20centroid)";input="%40interpolate(perspective)"] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,inter_stage:interpolation_type:*] @@ -55026,8 +54499,6 @@ [:isAsync=true;output="";input=""] [:isAsync=true;output="";input="%40interpolate(linear)"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;output="";input="%40interpolate(perspective)"] expected: @@ -55052,8 +54523,6 @@ if os == "linux" and not debug: FAIL [:isAsync=true;output="%40interpolate(linear)";input="%40interpolate(perspective)"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;output="%40interpolate(linear,%20center)";input="%40interpolate(linear,%20center)"] @@ -55080,22 +54549,16 @@ [:isAsync=true;outputs=["%40location(0)%20__:%20f32"\];inputs=["%40location(0)%20__:%20f32"\]] [:isAsync=true;outputs=["%40location(0)%20__:%20f32"\];inputs=["%40location(1)%20__:%20f32"\]] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;outputs=["%40location(1)%20__:%20f32","%40location(0)%20__:%20f32"\];inputs=["%40location(0)%20__:%20f32","%40location(1)%20__:%20f32"\]] [:isAsync=true;outputs=["%40location(1)%20__:%20f32"\];inputs=["%40location(0)%20__:%20f32"\]] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,inter_stage:location,subset:*] [:isAsync=false] [:isAsync=true] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,inter_stage:location,superset:*] @@ -55174,8 +54637,6 @@ [:isAsync=true;numScalarDelta=0;topology="triangle-list"] [:isAsync=true;numScalarDelta=1;topology="triangle-list"] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,inter_stage:max_shader_variable_location:*] @@ -55294,14 +54755,10 @@ [:isAsync=false] [:isAsync=true] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,misc:pipeline_layout,device_mismatch:*] [:] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,misc:vertex_state_only:*] @@ -55346,8 +54803,6 @@ [:isAsync=false] [:isAsync=true] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,overrides:identifier,fragment:*] @@ -55528,12 +54983,8 @@ if os == "linux" and not debug: FAIL [:isAsync=true;fragmentConstants={"r":1,"g":1}] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;fragmentConstants={}] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,overrides:uninitialized,vertex:*] @@ -55554,16 +55005,12 @@ if os == "linux" and not debug: FAIL [:isAsync=true;vertexConstants={"x":1,"y":1}] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;vertexConstants={"x":1,"z":1}] expected: if os == "linux" and not debug: FAIL [:isAsync=true;vertexConstants={}] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,overrides:value,type_error,fragment:*] @@ -55898,22 +55345,14 @@ [:isAsync=true;topology="_undef_";stripIndexFormat="_undef_"] [:isAsync=true;topology="_undef_";stripIndexFormat="uint16"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;topology="_undef_";stripIndexFormat="uint32"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;topology="line-list";stripIndexFormat="_undef_"] [:isAsync=true;topology="line-list";stripIndexFormat="uint16"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;topology="line-list";stripIndexFormat="uint32"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;topology="line-strip";stripIndexFormat="_undef_"] @@ -55924,22 +55363,14 @@ [:isAsync=true;topology="point-list";stripIndexFormat="_undef_"] [:isAsync=true;topology="point-list";stripIndexFormat="uint16"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;topology="point-list";stripIndexFormat="uint32"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;topology="triangle-list";stripIndexFormat="_undef_"] [:isAsync=true;topology="triangle-list";stripIndexFormat="uint16"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;topology="triangle-list";stripIndexFormat="uint32"] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;topology="triangle-strip";stripIndexFormat="_undef_"] @@ -56458,8 +55889,6 @@ [cts.https.html?q=webgpu:api,validation,render_pipeline,shader_module:device_mismatch:*] [:] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:api,validation,render_pipeline,shader_module:invalid,fragment:*] @@ -56468,8 +55897,6 @@ [:isAsync=false;isFragmentShaderValid=true] [:isAsync=true;isFragmentShaderValid=false] - expected: - if os == "linux" and not debug: FAIL [:isAsync=true;isFragmentShaderValid=true] @@ -63906,12 +63333,8 @@ [cts.https.html?q=webgpu:api,validation,state,device_lost,destroy:createComputePipelineAsync:*] [:valid=false;awaitLost=false] - expected: - if os == "linux" and not debug: FAIL [:valid=false;awaitLost=true] - expected: - if os == "linux" and not debug: FAIL [:valid=true;awaitLost=false] @@ -64132,12 +63555,8 @@ [cts.https.html?q=webgpu:api,validation,state,device_lost,destroy:createRenderPipelineAsync:*] [:valid=false;awaitLost=false] - expected: - if os == "linux" and not debug: FAIL [:valid=false;awaitLost=true] - expected: - if os == "linux" and not debug: FAIL [:valid=true;awaitLost=false] @@ -70386,20 +69805,12 @@ [cts.https.html?q=webgpu:idl,constructable:pipeline_errors:*] [:msg="_undef_";options={"reason":"internal"}] - expected: - if os == "linux" and not debug: FAIL [:msg="_undef_";options={"reason":"validation"}] - expected: - if os == "linux" and not debug: FAIL [:msg="some%20msg";options={"reason":"internal"}] - expected: - if os == "linux" and not debug: FAIL [:msg="some%20msg";options={"reason":"validation"}] - expected: - if os == "linux" and not debug: FAIL [cts.https.html?q=webgpu:idl,constructable:uncaptured_error_event:*] @@ -93025,8 +92436,6 @@ [cts.https.html?q=webgpu:shader,execution,expression,call,builtin,pow:f32:*] - expected: - if os == "linux" and not debug: CRASH [:inputSource="const";vectorize="_undef_"] expected: if os == "linux" and not debug: FAIL