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

Unable to run example #249

Closed
justinmoon opened this issue Sep 23, 2021 · 8 comments
Closed

Unable to run example #249

justinmoon opened this issue Sep 23, 2021 · 8 comments

Comments

@justinmoon
Copy link

I'm on arch linux:

$ cargo run --example gallery
    Finished dev [unoptimized + debuginfo] target(s) in 0.10s
     Running `target/debug/examples/gallery`
MESA-INTEL: warning: Performance support disabled, consider sysctl dev.i915.perf_stream_paranoid=0

[2021-09-23T05:00:46Z ERROR wgpu_core::validation] Unexpected varying type: Array { base: [1], size: Constant([5]), stride: 4 }
[2021-09-23T05:00:46Z ERROR wgpu_core::validation] Unexpected varying type: Array { base: [1], size: Constant([5]), stride: 4 }
[2021-09-23T05:00:46Z ERROR wgpu_core::validation] Unexpected varying type: Array { base: [1], size: Constant([5]), stride: 4 }
[2021-09-23T05:00:46Z ERROR wgpu_core::validation] Unexpected varying type: Array { base: [1], size: Constant([5]), stride: 4 }
[2021-09-23T05:00:46Z ERROR wgpu_core::validation] Unexpected varying type: Array { base: [1], size: Constant([5]), stride: 4 }
[2021-09-23T05:00:46Z ERROR wgpu_core::validation] Unexpected varying type: Array { base: [1], size: Constant([5]), stride: 4 }
[2021-09-23T05:00:46Z ERROR wgpu_core::validation] Unexpected varying type: Array { base: [1], size: Constant([5]), stride: 4 }
[2021-09-23T05:00:46Z ERROR wgpu_core::validation] Unexpected varying type: Array { base: [1], size: Constant([5]), stride: 4 }
[2021-09-23T05:00:46Z ERROR wgpu_core::validation] Unexpected varying type: Array { base: [4], size: Constant([6]), stride: 4 }
[2021-09-23T05:00:46Z ERROR wgpu_core::validation] Unexpected varying type: Array { base: [4], size: Constant([6]), stride: 4 }
[2021-09-23T05:00:46Z ERROR wgpu_core::validation] Unexpected varying type: Array { base: [4], size: Constant([6]), stride: 4 }
[2021-09-23T05:00:46Z ERROR wgpu_core::validation] Unexpected varying type: Array { base: [4], size: Constant([6]), stride: 4 }
MESA-INTEL: error: ../mesa-21.2.1/src/intel/vulkan/anv_batch_chain.c:2053: execbuf2 failed: Invalid argument (VK_ERROR_DEVICE_LOST)
thread 'main' panicked at 'Error in Queue::submit: parent device is lost', /home/justin/.cargo/registry/src/github.com-1ecc6299db9ec823/wgpu-0.10.1/src/backend/direct.rs:186:9
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
[2021-09-23T05:00:46Z ERROR wgpu_core::device] failed to wait for the device: Lost

Not sure if I installed dependencies correctly ...

@dhardy
Copy link
Collaborator

dhardy commented Sep 23, 2021

So you're using Intel graphics. Which CPU generation? Can you try running some wgpu examples?

@justinmoon
Copy link
Author

justinmoon commented Sep 23, 2021

Yes Intel. Skylake. I get the same error when I try to run wgpu's "mipmap" example. But all the other ones I tried worked.

$ cargo run --example mipmap
   Compiling wgpu v0.10.1 (/home/justin/code/clones/wgpu/wgpu)
    Finished dev [unoptimized + debuginfo] target(s) in 11.66s
     Running `/home/justin/code/clones/wgpu/target/debug/examples/mipmap`
MESA-INTEL: warning: Performance support disabled, consider sysctl dev.i915.perf_stream_paranoid=0

Using Intel(R) HD Graphics 620 (KBL GT2) (Vulkan)
Generating mip level 1 took 69.833 μs and called the fragment shader 65536 times
Generating mip level 2 took 41.333 μs and called the fragment shader 16384 times
Generating mip level 3 took 16.083 μs and called the fragment shader 4096 times
Generating mip level 4 took 13.333 μs and called the fragment shader 1024 times
Generating mip level 5 took 13.083 μs and called the fragment shader 256 times
Generating mip level 6 took 13.417 μs and called the fragment shader 64 times
Generating mip level 7 took 14.333 μs and called the fragment shader 16 times
Generating mip level 8 took 14.417 μs and called the fragment shader 4 times
MESA-INTEL: error: ../mesa-21.2.1/src/intel/vulkan/anv_batch_chain.c:2053: execbuf2 failed: Invalid argument (VK_ERROR_DEVICE_LOST)
thread 'main' panicked at 'Error in Queue::submit: parent device is lost', wgpu/src/backend/direct.rs:197:9
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
[2021-09-23T16:24:10Z ERROR wgpu_core::device] failed to wait for the device: Lost

@dhardy
Copy link
Collaborator

dhardy commented Sep 23, 2021

I just tested on my Intel Haswell laptop.. and it doesn't draw (though no obvious error). Will have to investigate further. You might also consider reporting an issue to WGPU. See here if you wish to investigate further yourself.

@dhardy
Copy link
Collaborator

dhardy commented Oct 12, 2021

I can confirm that the update to WGPU 0.10 is what broke rendering on the Haswell laptop. I see WGPU 0.11 is out now, so testing that is next..

@dhardy
Copy link
Collaborator

dhardy commented Oct 13, 2021

WGPU v0.11 does not work on the Haswell laptop either, but it introduces an experimental fallback option which does (with some issues). This can be enabled with (in latest master):

KAS_BACKENDS=fallback cargo run --example gallery

@justinmoon it would be worth also testing without the fallback option now that master is updated to WGPU v0.11.

@justinmoon
Copy link
Author

$ cargo run --example gallery
...
MESA-INTEL: warning: Performance support disabled, consider sysctl dev.i915.perf_stream_paranoid=0

MESA-INTEL: error: ../mesa-21.2.2/src/intel/vulkan/anv_batch_chain.c:2053: execbuf2 failed: Invalid argument (VK_ERROR_DEVICE_LOST)
thread 'main' panicked at 'Error in Queue::submit: parent device is lost', /home/justin/.cargo/registry/src/github.com-1ecc6299db9ec823/wgpu-0.11.0/src/backend/direct.rs:204:9
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
[2021-10-14T17:22:14Z ERROR wgpu_core::device] failed to wait for the device: Lost

$ KAS_BACKENDS=fallback  cargo run --example gallery
    Finished dev [unoptimized + debuginfo] target(s) in 0.12s
     Running `target/debug/examples/gallery`
MESA-INTEL: warning: Performance support disabled, consider sysctl dev.i915.perf_stream_paranoid=0

Error: NoAdapter

@dhardy
Copy link
Collaborator

dhardy commented Oct 15, 2021

consider sysctl dev.i915.perf_stream_paranoid=0

Did you try this?

Currently KAS does not support pure-CPU rendering (#33). (It may happen eventually, given more motivation/resources.)

@dhardy
Copy link
Collaborator

dhardy commented Feb 23, 2022

Closing because this largely concerns WGPU and I do not have the capacity to work on this directly.

Instead non-GPU rendering (#287) should solve this (eventually).

@dhardy dhardy closed this as completed Feb 23, 2022
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