• Login
  • Register
  • Dolphin Forums
  • Home
  • FAQ
  • Download
  • Wiki
  • Code


Dolphin, the GameCube and Wii emulator - Forums › Dolphin Emulator Discussion and Support › Support v
« Previous 1 ... 228 229 230 231 232 ... 1190 Next »

Dumping shaders to diagnose GPU kernel driver crashes?
View New Posts | View Today's Posts

Pages (2): 1 2 Next »
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Thread Modes
Dumping shaders to diagnose GPU kernel driver crashes?
09-19-2018, 09:13 PM (This post was last modified: 09-19-2018, 09:19 PM by Valmar.)
#1
Valmar Offline
Junior Member
**
Posts: 12
Threads: 3
Joined: Sep 2018
Is there a way to dump a shader, preferably in textual and / or compiled form? Maybe it's not the right solution for debugging this annoying situation...? Are they related to the "objects" that can be dumped, because that might mean I can use the software renderer for the task. It might even be a texture-related issue... just the annoyed ramblings of someone who doesn't know where to start with resolving the issue... :|

This bug is related to many "ring gfx timeout"-related bug/s in the AMDGPU kernel driver, but I can't do anything to help without being able to dump the shaders somehow. This seems impossible, because I don't know how to dump the shaders without them also crashing the driver... maybe I'm overthinking this, due to not having much understanding of shaders...?

The bug occurs with both the OpenGL and Vulkan backends, with both normal Synchronous shaders and Synchronous Ubershaders.

Anyways, the issues specifically begin at the end of Chapter 18 of Fire Emblem: Path of Radiance, after the end of the second scene with Ike, the soldier, and Nasir. when the scene fades to black, and before the scene with Naesala, whatever shader/s run at that moment cause the AMDGPU kernel driver to crash. I managed to skip past this bit with the software renderer, make a state save, and then discovered that it will crash again after the new chapter movie cutscene plays, before moving to the worldmap scene. Using the same method to skip to the Base, I discovered it will again happen after exiting the base when selecting "End". Thankfully, I made a game save at the base, so I can test it again to see when the bug is fixed, because all three scenarios seem related somehow. To the same shader/s set, maybe? I don't know...
Find
Reply
09-19-2018, 11:13 PM (This post was last modified: 09-19-2018, 11:13 PM by degasus.)
#2
degasus Offline
Developer
**********
Developers (Some Administrators and Super Moderators)
Posts: 1,827
Threads: 10
Joined: May 2012
I've used apitrace for this kind of dumps. Just run with the OGL backend:
apitrace trace dolphin-emu
apitrace replay dolphin-emu.trace
And see if it catches the crash. If so, upload the dolphin-emu.trace file (compress it!).
Find
Reply
09-20-2018, 12:42 AM
#3
Valmar Offline
Junior Member
**
Posts: 12
Threads: 3
Joined: Sep 2018
(09-19-2018, 11:13 PM)degasus Wrote: I've used apitrace for this kind of dumps. Just run with the OGL backend:
apitrace trace dolphin-emu
apitrace replay dolphin-emu.trace
And see if it catches the crash. If so, upload the dolphin-emu.trace file (compress it!).

Thanks! I'll give it a shot. Smile
Find
Reply
09-20-2018, 01:22 AM
#4
Valmar Offline
Junior Member
**
Posts: 12
Threads: 3
Joined: Sep 2018
(09-19-2018, 11:13 PM)degasus Wrote: I've used apitrace for this kind of dumps. Just run with the OGL backend:
apitrace trace dolphin-emu
apitrace replay dolphin-emu.trace
And see if it catches the crash. If so, upload the dolphin-emu.trace file (compress it!).

I'm not sure why, but apitrace is only capturing the OSD output, and not any of the actual game itself.

What dolphin-emu and apitrace settings do you use?

"apitrace replay" also spews a bunch of errors at me, which may or may not be related: https://paste.kde.org/pww2omep8
Find
Reply
09-20-2018, 01:28 AM
#5
degasus Offline
Developer
**********
Developers (Some Administrators and Super Moderators)
Posts: 1,827
Threads: 10
Joined: May 2012
This warnings are related:
1164 @0 glBufferData(target = GL_EXTERNAL_VIRTUAL_MEMORY_BUFFER_AMD, size = 33554432, data = blob(33554432), usage = GL_STREAM_COPY)
1164: warning: glGetError(glBufferData) = GL_INVALID_OPERATION

apitrace does not support AMD_pinned_memory.

May you try to disable this if() clause here: https://github.com/dolphin-emu/dolphin/blob/master/Source/Core/VideoBackends/OGL/StreamBuffer.cpp#L363 so that MapAndOrphan will be used?
Find
Reply
09-20-2018, 01:41 AM
#6
Valmar Offline
Junior Member
**
Posts: 12
Threads: 3
Joined: Sep 2018
(09-20-2018, 01:28 AM)degasus Wrote: This warnings are related:
1164 @0 glBufferData(target = GL_EXTERNAL_VIRTUAL_MEMORY_BUFFER_AMD, size = 33554432, data = blob(33554432), usage = GL_STREAM_COPY)
1164: warning: glGetError(glBufferData) = GL_INVALID_OPERATION

apitrace does not support AMD_pinned_memory.

May you try to disable this if() clause here: https://github.com/dolphin-emu/dolphin/blob/master/Source/Core/VideoBackends/OGL/StreamBuffer.cpp#L363 so that MapAndOrphan will be used?

Thanks! Does it require a full recompilation of Dolphin, or can I disable this extension temporarily elsewhere?
Find
Reply
09-20-2018, 01:45 AM
#7
Valmar Offline
Junior Member
**
Posts: 12
Threads: 3
Joined: Sep 2018
(09-20-2018, 01:41 AM)Valmar Wrote: Thanks! Does it require a full recompilation of Dolphin, or can I disable this extension temporarily elsewhere?

Nevermind. I can do this with a Mesa environment variable, apparently.
Find
Reply
09-20-2018, 02:16 AM
#8
Valmar Offline
Junior Member
**
Posts: 12
Threads: 3
Joined: Sep 2018
Okay, disable that code makes no difference.

apitrace replay output: https://paste.kde.org/pljjhcxom

Are there any tools similar to apitrace?
Find
Reply
09-20-2018, 02:24 AM
#9
degasus Offline
Developer
**********
Developers (Some Administrators and Super Moderators)
Posts: 1,827
Threads: 10
Joined: May 2012
Try to disable both: GL_AMD_pinned_memory and GL_ARB_buffer_storage
Find
Reply
09-20-2018, 03:18 AM
#10
Valmar Offline
Junior Member
**
Posts: 12
Threads: 3
Joined: Sep 2018
That works! Thanks. Smile
Find
Reply
« Next Oldest | Next Newest »
Pages (2): 1 2 Next »


  • View a Printable Version
  • Subscribe to this thread
Forum Jump:


Users browsing this thread: 1 Guest(s)



Powered By MyBB | Theme by Fragma

Linear Mode
Threaded Mode