mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-13 09:39:33 +01:00
Fix pipeline lifetime issue, misc.
This commit is contained in:
1 parent
caff2ea573
commit
14b5a1a7cd
7 files changed
+18
-13
No files matched your search
@@ -38,9 +38,9 @@ void PipelineManagerVulkan::Clear() {
|
||||
if (!value->pipeline) {
|
||||
// Something went wrong.
|
||||
ERROR_LOG(G3D, "Null pipeline found in PipelineManagerVulkan::Clear - didn't wait for asyncs?");
|
||||
delete value;
|
||||
} else {
|
||||
value->pipeline->QueueForDeletion(vulkan_);
|
||||
}
|
||||
value->pipeline->QueueForDeletion(vulkan_);
|
||||
delete value;
|
||||
});
|
||||
|
||||
|
||||
@@ -71,7 +71,7 @@ Promise<VkShaderModule> *CompileShaderModuleAsync(VulkanContext *vulkan, VkShade
|
||||
|
||||
VkShaderModule shaderModule = VK_NULL_HANDLE;
|
||||
if (success) {
|
||||
success = vulkan->CreateShaderModule(spirv, &shaderModule);
|
||||
success = vulkan->CreateShaderModule(spirv, &shaderModule, stage == VK_SHADER_STAGE_VERTEX_BIT ? "game_vertex" : "game_fragment");
|
||||
#ifdef SHADERLOG
|
||||
OutputDebugStringA("OK");
|
||||
#endif
|
||||
@@ -81,7 +81,7 @@ Promise<VkShaderModule> *CompileShaderModuleAsync(VulkanContext *vulkan, VkShade
|
||||
};
|
||||
|
||||
#ifdef _DEBUG
|
||||
// Don't parallelize in debug mode, pathological behavior due to mutex locks in allocator.
|
||||
// Don't parallelize in debug mode, pathological behavior due to mutex locks in allocator which is HEAVILY used by glslang.
|
||||
return Promise<VkShaderModule>::AlreadyDone(compile());
|
||||
#else
|
||||
return Promise<VkShaderModule>::Spawn(&g_threadManager, compile, TaskType::CPU_COMPUTE);
|
||||
|
||||
@@ -44,7 +44,7 @@ VkShaderModule CompileShaderModule(VulkanContext *vulkan, VkShaderStageFlagBits
|
||||
return VK_NULL_HANDLE;
|
||||
} else {
|
||||
VkShaderModule module;
|
||||
if (vulkan->CreateShaderModule(spirv, &module)) {
|
||||
if (vulkan->CreateShaderModule(spirv, &module, stage == VK_SHADER_STAGE_VERTEX_BIT ? "system_vs" : "system_fs")) {
|
||||
return module;
|
||||
} else {
|
||||
return VK_NULL_HANDLE;
|
||||
|
||||
Reference in new issue
Block a user