Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update wgpu to v23 #343

Closed
torsteingrindvik opened this issue Dec 4, 2024 · 2 comments
Closed

Update wgpu to v23 #343

torsteingrindvik opened this issue Dec 4, 2024 · 2 comments

Comments

@torsteingrindvik
Copy link
Contributor

torsteingrindvik commented Dec 4, 2024

Currently if you try to use comptime! { .. } to build Arrays in cube kernels accessing them works fine for CUDA.

Using WGPU + WGSL doesn't work. This was recently fixed, the v23 changelog shows:

(See https://github.com/gfx-rs/wgpu/blob/trunk/CHANGELOG.md#contributor-spotlight-sagudev)
image

On main this currently happens on WGPU + WGSL:

wgpu error: Validation Error

Caused by:
  In Device::create_shader_module

Shader validation error:
   ┌─ :62:11
   │
62 │ let _24 = arrays_0[_23];
   │           ^^^^^^^^^^^^^ naga::Expression [84]


      Entry point foo_f32 at Compute is invalid
        Expression [84] is invalid
          The expression [83] may only be indexed by a constant

on WGPU + SPIRV:

thread 'main' panicked at $PATH/cubecl/crates/cubecl-spirv/src/variable.rs:399:49:
index out of bounds: the len is 0 but the index is 0
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

A "quick and dirty" update to v23 locally fixed the WGPU + WGSL issue for me.

For a proper update a few things must be cleared up:

@AsherJingkongChen
Copy link
Contributor

AsherJingkongChen commented Dec 4, 2024

Hi, I am working on #211. You can write comments there.

It is recommended to see the relevant PRs first.

@torsteingrindvik
Copy link
Contributor Author

Fixed in #211

Thanks @AsherJingkongChen

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants