rsx: Minor fixes

- Dont skip cb if a problem occurs, just spin on it instead to allow possibility of recovery
- Vulkan cleanup for the die_with_error helper
This commit is contained in:
kd-11 2017-10-11 01:31:26 +03:00
parent 58860614e3
commit 9af71699a4
3 changed files with 5 additions and 7 deletions

View File

@ -495,7 +495,6 @@ namespace rsx
LOG_ERROR(RSX, "Invalid FIFO queue get/put registers found, get=0x%X, put=0x%X", get, put);
invalid_command_interrupt_raised = true;
ctrl->get = put;
continue;
}
@ -546,7 +545,6 @@ namespace rsx
LOG_ERROR(RSX, "Invalid FIFO queue args ptr found, get=0x%X, cmd=0x%X, count=%d", get, cmd, count);
invalid_command_interrupt_raised = true;
ctrl->get = put;
continue;
}

View File

@ -373,7 +373,7 @@ namespace vk
return (g_num_processed_frames > 0)? g_num_processed_frames - 1: 0;
}
void die_with_error(std::string faulting_addr, VkResult error_code)
void die_with_error(const char* faulting_addr, VkResult error_code)
{
std::string error_message;
int severity = 0; //0 - die, 1 - warn, 2 - nothing
@ -457,16 +457,16 @@ namespace vk
error_message = "Invalid external handle (VK_ERROR_INVALID_EXTERNAL_HANDLE_KHX)";
break;
default:
error_message = fmt::format("Unknown Code (%Xh, %d)", (s32)error_code, (s32&)error_code);
error_message = fmt::format("Unknown Code (%Xh, %d)%s", (s32)error_code, (s32&)error_code, faulting_addr);
break;
}
switch (severity)
{
case 0:
fmt::throw_exception("Assertion Failed! Vulkan API call failed with unrecoverable error: %s", (error_message + faulting_addr).c_str());
fmt::throw_exception("Assertion Failed! Vulkan API call failed with unrecoverable error: %s%s", error_message.c_str(), faulting_addr);
case 1:
LOG_ERROR(RSX, "Vulkan API call has failed with an error but will continue: %s", (error_message + faulting_addr).c_str());
LOG_ERROR(RSX, "Vulkan API call has failed with an error but will continue: %s%s", error_message.c_str(), faulting_addr);
break;
}
}

View File

@ -94,7 +94,7 @@ namespace vk
const u64 get_current_frame_id();
const u64 get_last_completed_frame_id();
void die_with_error(std::string faulting_addr, VkResult error_code);
void die_with_error(const char* faulting_addr, VkResult error_code);
struct memory_type_mapping
{