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

Running any Vulkano projects results in a freeze and crash #1217

Closed
Ldash4 opened this issue Jul 6, 2019 · 4 comments · Fixed by #1246
Closed

Running any Vulkano projects results in a freeze and crash #1217

Ldash4 opened this issue Jul 6, 2019 · 4 comments · Fixed by #1246

Comments

@Ldash4
Copy link

Ldash4 commented Jul 6, 2019

  • OS: Arch 5.1.15-arch1-1-ARCH
  • GPU: NVIDIA GeForce GTX 1070
  • GPU Driver: nvidia-430.26-7

Running any Vulkano project (I tried several from the examples repo) results in the following:

➜  vulkano-examples git:(master) cargo run --release --bin triangle
    Finished release [optimized] target(s) in 0.07s
     Running `target/release/triangle`
Using device: GeForce GTX 1070 (type: DiscreteGpu)
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: OutOfHostMemory', src/libcore/result.rs:997:5
note: Run with `RUST_BACKTRACE=1` environment variable to display a backtrace.

The backtrace contains no useful information. The exact same results are shown on any example.

The project renders one frame, shows the above message, hangs for ~4 seconds and then crashes.

@simdimdim
Copy link
Contributor

simdimdim commented Jul 25, 2019

might be related: #955 , #1210 might also be related. And most likely so is #1135

@theotherphil
Copy link
Contributor

theotherphil commented Oct 20, 2019

I see the same behaviour on my machine.

OS: Ubuntu 19.04
GPU: NVIDIA GeForce RTX 2070 SUPER
GPU Driver: 430.50-0ubuntu0.19.04.1

→ cargo run --bin triangle
Finished dev [unoptimized + debuginfo] target(s) in 0.03s
Running target/debug/triangle
Using device: GeForce RTX 2070 SUPER (type: DiscreteGpu)
thread 'main' panicked at 'called Result::unwrap() on an Err value: OutOfHostMemory', src/libcore/result.rs:1084:5
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace.

@AustinJ235
Copy link
Member

This is a know issue at this point and has yet to be corrected in the examples. On nvidia systems you need to call wait after then_signal_fence_and_flush.

@theotherphil
Copy link
Contributor

theotherphil commented Oct 20, 2019

Thanks. The following change fixes the triangle example for me. I'll create a PR to fix the examples in vulkano-examples.

(Edit: d'oh. Got as far as creating a PR, only to discover that I need to commit to vulkano instead. I'll do that then...)

diff --git a/src/bin/triangle.rs b/src/bin/triangle.rs
index 172075d..e8848a0 100644
--- a/src/bin/triangle.rs
+++ b/src/bin/triangle.rs
@@ -415,6 +415,7 @@ void main() {
 
         match future {
             Ok(future) => {
+                future.wait(None);
                 previous_frame_end = Box::new(future) as Box<_>;
             }
             Err(FlushError::OutOfDate) => {

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

Successfully merging a pull request may close this issue.

4 participants