JRE fatal error printouts

Started by Kudze, April 17, 2016, 15:22:00

Previous topic - Next topic

Kudze

Can I get any useful information from JRE fatal error printouts?

I know that this error oquirs while I create SwapChain on Vulkan. My question is not how to fix this error but does this fatal error printout give any usual information?

My fatal error JRE printout
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00007ffd7424c702, pid=7820, tid=228
#
# JRE version: Java(TM) SE Runtime Environment (8.0_74-b02) (build 1.8.0_74-b02)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.74-b02 mixed mode windows-amd64 compressed oops)
# Problematic frame:
# C  [VkLayer_swapchain.dll+0xc702]
#
# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows
#
# An error report file with more information is saved as:
# C:\Users\Karolis\Programavimas\Eclipse\WorkSpace\_KKgames - VISION\hs_err_pid7820.log
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.java.com/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#

spasi

Normal you would see something like this in the log:

Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C  [VkLayer_swapchain.dll+0xb817]
C  [VkLayer_swapchain.dll+0xcda5]
C  [VkLayer_object_tracker.dll+0x1b801]
C  [VkLayer_core_validation.dll+0xa223f]
C  0x0000000002375e34

Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j  org.lwjgl.system.JNI.callPPPPI(JJJJJ)I+0
j  org.lwjgl.vulkan.KHRSwapchain.nvkCreateSwapchainKHR(Lorg/lwjgl/vulkan/VkDevice;JJJ)I+41
j  org.lwjgl.demo.vulkan.HelloVulkan.demo_prepare_buffers()V+323
j  org.lwjgl.demo.vulkan.HelloVulkan.demo_prepare()V+149
j  org.lwjgl.demo.vulkan.HelloVulkan.run()V+13
j  org.lwjgl.demo.vulkan.HelloVulkan.main([Ljava/lang/String;)V+7

This is a crash inside a Vulkan SDK validation layer. I don't think the validation layers are supposed to ever crash, but they're still being worked on and may improve in the future. Anyway, in order to get something useful out of the crash, you should use debug builds of the validation layers.

The Vulkan SDK comes with debug builds, in the <sdk path>/Source/lib directory. You can set the VK_LAYER_PATH environment variable to that directory and they will be used automatically. The output would change to:

Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C  [VkLayer_swapchain.dll+0x15fbf]  validateCreateSwapchainKHR+0x49f
C  [VkLayer_swapchain.dll+0x11665]  vkCreateSwapchainKHR+0x85
C  [VkLayer_object_tracker.dll+0x14d82]  vkCreateSwapchainKHR+0x102
C  [VkLayer_core_validation.dll+0x43a2e]  vkCreateSwapchainKHR+0x6e
C  0x00000000023f5e34

Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j  org.lwjgl.system.JNI.callPPPPI(JJJJJ)I+0
j  org.lwjgl.vulkan.KHRSwapchain.nvkCreateSwapchainKHR(Lorg/lwjgl/vulkan/VkDevice;JJJ)I+41
j  org.lwjgl.demo.vulkan.HelloVulkan.demo_prepare_buffers()V+323
j  org.lwjgl.demo.vulkan.HelloVulkan.demo_prepare()V+149
j  org.lwjgl.demo.vulkan.HelloVulkan.run()V+13
j  org.lwjgl.demo.vulkan.HelloVulkan.main([Ljava/lang/String;)V+7

This should help a bit with identifying the issue. You can also use a native debugger to step into the validation layers.

Disclaimer: The pre-built debug layers did not work for me (SDK 1.0.8, on Windows). I had to clone Vulkan-LoaderAndValidationLayers and build them manually.

Kudze

Alright thanks. Spasi, could you please give me your contacts (e-mail would be perfect), because I think that if I will continue developing on Vulkan way more questions will appear. Or should I just post my questions here?

Kai

It's far more likely that your question will be answered when posted here, as more people then have the chance to do so. If it's not a LWJGL-specific question I'd also recommend you to post in the Khronos Vulkan forum.

Example of not LWJGL-specific questions:
- "Why do I get an error from the validation layers when calling the vkSuchAndSuch method with a struct whose XYZ field is 4 (the corresponding VK constant) instead of 5?"

Example of a LWJGL-specific question:
- "How do I fill members of a struct which are structs themselves?"

Also, when you post here and get an answer this serves other people having the same problem as well, as they can just read up on it and see the solution here.

Kudze

Ok so I'm going to write my questions to this forum. Hmm about that overcrashing thing. Is it possible that it overcrashes because I use nightly build?