Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions src/launcher/diagnosis.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,14 @@ constexpr Rule kRules[] = {
{{"gpu reset", "ring timeout", "nvrm: xid", "gpu hang",
"stopped responding and has successfully recovered"}, // Windows: Display event 4101
"The graphics driver reset the GPU during the game.", kGpuAdvice},
// hle/vulkan/vulkan.cpp: the driver's own fault report says the GPU read or wrote an address that was not
// mapped. That is an error in the commands the game's rendering sent, not a driver or overlay problem, and
// the VR runtime's own crash afterwards (its streaming driver losing the device) is a consequence.
{{"gpu page fault detected"},
"The GPU read or wrote memory that was not mapped (a page fault) while the game was rendering.",
"This is most likely a bug in Venture or the game, not your driver. Send this report with an issue, and "
"say if it happens at the same point every time. If SteamVR or another VR runtime also reports a crash, "
"that probably came after this fault."},
// hle/vulkan/vulkan.cpp, and the host's own device loss.
{{"native vulkan device lost", "vk_error_device_lost"},
"The game lost the graphics device.", kGpuAdvice},
Expand Down
12 changes: 11 additions & 1 deletion src/runtime/hle/vulkan/address_log.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,17 @@ void address_log_detach(VkInstance instance) {
destroy(instance, messenger, nullptr);
}
bool address_log_device(const std::vector<VkExtensionProperties>& host) {
return address_log_enabled() && supported(host, VK_EXT_DEVICE_ADDRESS_BINDING_REPORT_EXTENSION_NAME);
if (!address_log_enabled()) return false;
if (supported(host, VK_EXT_DEVICE_ADDRESS_BINDING_REPORT_EXTENSION_NAME)) return true;
// The driver cannot report address bindings: say so once, or a fault report with no trace looks like a
// diagnostic that failed to start.
static std::once_flag warned;
std::call_once(warned, [] {
log::warn("vulkan",
"VENTURE_VULKAN_ADDRESS_LOG is set, but this GPU driver lacks VK_EXT_device_address_binding_report, "
"so a device fault will not be traced to an object");
});
return false;
}
void address_log_note(bool bind, std::uint64_t base, std::uint64_t size, int type, std::uint64_t handle,
unsigned flags) {
Expand Down
4 changes: 4 additions & 0 deletions tests/debug_report_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,10 @@ TEST_CASE("debug report: known causes, most specific first") {
auto lost = diagnose("E [vulkan-fault] Native Vulkan device lost on guest tid 7; ending the app\n");
REQUIRE(lost);
CHECK(lost->cause.find("graphics device") != std::string::npos);
auto fault = diagnose("W [vulkan-fault] vkGetDeviceFaultInfoEXT returned 0: GPU page fault detected (addresses=1)\n"
"E [vulkan-fault] Native Vulkan device lost on guest tid 7; ending the app\n");
REQUIRE(fault);
CHECK(fault->cause.find("page fault") != std::string::npos);
auto reset = diagnose("kernel: amdgpu 0000:03:00.0: amdgpu: GPU reset begin!\n");
REQUIRE(reset);
CHECK(reset->cause.find("reset the GPU") != std::string::npos);
Expand Down
Loading