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

Crashing/Freezing/OutOfHostMemory with Nvidia or on MacOS systems #1247

Closed
AustinJ235 opened this issue Oct 20, 2019 · 15 comments
Closed

Crashing/Freezing/OutOfHostMemory with Nvidia or on MacOS systems #1247

AustinJ235 opened this issue Oct 20, 2019 · 15 comments

Comments

@AustinJ235
Copy link
Member

AustinJ235 commented Oct 20, 2019

This issue has been brought up many times and is possibly due to driver bugs. Further investigation is needed to see if this is an issue within vulkano. Pull request #1246 adds a workaround in the examples so that new users aren't put off when getting started with vulkano and aren't confused as to why it isn't work on their system.

Issues related: #1217 #959 #923 #627 #1022 #1210 #1136 #1135
Pull request related: #1246 #955 #1027

@nickwilcox
Copy link
Contributor

Has anybody done a deep dive on what the possible causes are?

@AustinJ235
Copy link
Member Author

#955 is about the deepest we have gone. Original thought it was an nvidia bug, but somebody posted about a validation error. Something may be incorrect about our GpuFuture handling. So if you cared to do any investigation sanity checking the gpu future code would be a good place to start.

@nickwilcox
Copy link
Contributor

nickwilcox commented Nov 16, 2019

I found that the issue with the triangle example was fixed by an upgrade to MoltenVK 1.1.126 from 1.1.101.

Before that when I took out the workaround I was seeing the MoltenVK swapchain code constantly leaking CAMetalDrawables at 12MiB each.

@Ella-0
Copy link

Ella-0 commented Oct 5, 2020

I'm still having issues with this. I've tried a couple solutions and my program still only works reliably on my Intel GPU (HD 630). It crashes after a few seconds on the Nvidia GPU (GTX 1050). I am making a new ImmutableImage every frame which probably isn't the best of ideas but I don't think that's what is causing it.

OS: Arch Linux VK_KHR_display/wayland

@AustinJ235
Copy link
Member Author

AustinJ235 commented Oct 5, 2020 via email

@Ella-0
Copy link

Ella-0 commented Oct 5, 2020

Yeah I've tried both of those and it still crashes. As for memory usage, it states it was 1.6% of memory before it crashed which is 256 mb.

@Ella-0
Copy link

Ella-0 commented Oct 5, 2020

I think it must be my code because I've_ never had issues like this before when using an Nvidia gpu with vulkano though I've never been copying lots of data each frame with vulkano.

@AustinJ235
Copy link
Member Author

AustinJ235 commented Oct 5, 2020 via email

@Ella-0
Copy link

Ella-0 commented Oct 6, 2020

Yeah, I'll do that and see if the errors still persist.

@Ella-0
Copy link

Ella-0 commented Oct 6, 2020

Well I switched everything to use StorageImage so now it doesn't crash, but no images are loaded when using the nvidia card. it works fine with my intel card though. weird.

@kgnlp
Copy link

kgnlp commented Jan 9, 2021

I'm getting memory leaks at around 1mb/s which makes my program practically unusable at the moment. I'm testing on linux with a mobile nvidia 1070 without Optimus.

I'm using an ImmutableImage which is updated only rarely when needed, a CpuAccessibleBuffer with storage usage of which I create a new one every frame, and push constants (potential related to #1118). I'm using both future.wait(None).unwrap(), without which I get OOM very quickly with PresentMode::Immediate, and cleanup_finished after every draw call.

Edit: as mentioned in the other issue this seems to be caused by push constants and only when running it on my nvidia GPU - on Intel HD the issue doesn't occur at all

@kgnlp
Copy link

kgnlp commented Jan 10, 2021

I haven't noticed it yesterday, but it seems like I'm also running into leaks caused by ImmutableImage even though I only replace it when the window is resized though I'm not entirely sure. I only know for certain that leaks occur when resizing the window

@Rua
Copy link
Contributor

Rua commented May 14, 2022

Is this still an issue?

@Ella-0
Copy link

Ella-0 commented May 14, 2022

I have no idea. I don't have nvidia hardware to test with anymore.

@AustinJ235
Copy link
Member Author

Should be closed with #1246

#1246 (comment)

Can you update your comments to refer to #1247 instead.

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

No branches or pull requests

5 participants