Unable to create compute pipeline (creation aborted)
alienself opened this issue · 2 comments
Hi again,
I am having an issue while creating a compute pipeline.
For some reason I keep getting an assertion failed
when running wgpu_device_create_compute_pipeline
.
It seems to fail at retrieving the device from the store or something similar however everything works fine with the wgpu_device_create_render_pipeline
.
I can draw a geometry in the same context a few lines before but adding the compute pipeline raises this error.
I don't have this issue with the official emscripten webgpu library with the same code.
WGpuShaderModule shaderModule;
{
WGpuShaderModuleDescriptor desc = {};
desc.code = blurWGSL;
shaderModule = wgpu_device_create_shader_module(device, &desc);
}
WGpuPipelineLayout layout = WGPU_AUTO_LAYOUT_MODE_AUTO;
wgpu_device_create_compute_pipeline(device, shaderModule, "main", layout, nullptr, 0);
Thanks for the report. Pushed two commits, first should improve that assertion failure message to actually print out what the assertion check was that failed. The second commit fixes this issue, which looks like I refactored the magic ID for auto layout to be integer value 1 instead of 0, but did not update the assert tests.
Hopefully there won't be too many of these types of issues that come about (unfortunately like you see here, I haven't had the bandwidth to create tests to exercise all API functions yet), but happy to get all the bug reports that you will run into.
Awesome thanks a lot!