Editor crashes when run with vulkan

In 4.18 Preview 1 and 2, the editor crashes when run with -vulkan. In 4.17 that still worked.

Steps:

  1. Create a new third person example project
  2. Go the the project settings, disable all RHIs, only enable vulkan:

https://puu.sh/xJunt/7fdc6dccda.png

  1. Restart the project
  2. Wait until its at 100% and when the editor just loads up, it crashes. No crash reporter shows up, only the windows error saying “Unreal Engine stopped working”.

I am using a GTX 1080 (newest driver) on Windows 10.

@RCaloca I see you fixed some vulkan bugs in preview 2 so I hoped those would fix this when I first saw this in preview 1, but the issue is same in preview 2.

Here’s the log file: [Log File][2]

Hi John, we haven’t been able to repro here, and the log doesn’t provide much. Do you get a crash reporter dialog? Can you send me a copy or screenshot?

Also can you run with -vulkan as the editor command line?

do you have visual studio? if so you can do
ue4editor yourproject -vulkan -waitfordebugger

then on visual studio do debug->attach to process and that will continue execution, which should then crash inside visual studio.

Hi Rolando, that was a quick reply!

I do not get the crash reporter unfortunately, only windows saying that UE4 stopped working.
I did try it with having both D3D11 and Vulkan enabled in the project settings and then running the project with -vulkan, that’s same results.

Of course I have VS :slight_smile: I just directly started the project from VS now, that should give the same result.

This is the call stack:

https://puu.sh/xJwbJ/b27a68def9.png

This is where it crashes in VulkanQuery.cpp:

https://puu.sh/xJwem/486f663b2c.png

It is in the game thread there, so thats why that check fails.

Ah, that commit is not in 4.18P2? I expected it would be in there already.

Yes, I think this has been fixed as of https://github.com/EpicGames/UnrealEngine/commit/acd848ddf1f551401fda73d4604d749015aecd81#diff-60f0c4774183c6a57058b1596babe1bf

Not sure TBH :slight_smile: In theory you can copy just the VulkanRHI folder and it ‘should’ work :smiley:

Awesome.

About the frame time, iirc only D3D does the full frame time (ie consoles won’t): the idea was that stat unit already shows the GPU time. I’ll add it as a todo, but I won’t get to it for this release.

Can just look here: https://github.com/EpicGames/UnrealEngine/commits/4.18.0-preview-2
Seems the newest commit in preview 2 is 3 days old, so the fix isn’t part of it. So I’ll just wait for Preview 3 and then test it.

btw, Vulkan works great in 4.18 without the editor, I no longer see any visual artifacts in the third person example :slight_smile:

Two minor things, I am happy that profilegpu works now, but why is there no number for the overall frame time? https://puu.sh/xJv01/a4c1f76656.png It’s a bit annoying to calculate the whole frame time manually.
Also, is vsync still enforced on vulkan? I can’t get it to render with more than 60 fps.

true, it isn’t really needed since the overall frame time is shown in stat unit.

What about vsync?

the GPU value is, but the overall fps is capped at 60 fps with vulkan. So with vulkan I get constant 60 fps while with D3D11 I get 400 fps. So I’m wondering if it’s still impossible to disable vsync on vulkan?

GPU in stat unit is w/o vsync.

Ah yes, it’s not implemented yet, but also there are CPU bottlenecks where it might not yet reach > 60 fps. 4.19 :slight_smile:

Thanks Rolando! :slight_smile: Very nice.

Btw, you haven’t looked at your vulkan forum thread for quite a while, you probably no longer get notifications since the forum was updated.

Just compiled current 4.18 from github, and I can confirm the issue is fixed there, editor starts up without issue with vulkan now :slight_smile: Thanks!