Skip to content
Permalink
Browse files
Merge pull request #10107 from OatmealDome/amd-subgroup-reduction
VulkanContext: Disable subgroup reduction on Macs with AMD GPUs
  • Loading branch information
JosJuice committed Sep 17, 2021
2 parents 2d1ec63 + 7e8f520 commit a6baca6
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
@@ -944,7 +944,8 @@ void VulkanContext::PopulateShaderSubgroupSupport()
VK_SUBGROUP_FEATURE_BALLOT_BIT;
m_supports_shader_subgroup_operations =
(subgroup_properties.supportedOperations & required_operations) == required_operations &&
subgroup_properties.supportedStages & VK_SHADER_STAGE_FRAGMENT_BIT;
subgroup_properties.supportedStages & VK_SHADER_STAGE_FRAGMENT_BIT &&
!DriverDetails::HasBug(DriverDetails::BUG_BROKEN_SUBGROUP_INVOCATION_ID);
}

bool VulkanContext::SupportsExclusiveFullscreen(const WindowSystemInfo& wsi, VkSurfaceKHR surface)
@@ -127,6 +127,8 @@ constexpr BugInfo m_known_bugs[] = {
-1.0, -1.0, true},
{API_OPENGL, OS_WINDOWS, VENDOR_ATI, DRIVER_ATI, Family::UNKNOWN, BUG_BROKEN_SSBO_FIELD_ATOMICS,
-1.0, -1.0, true},
{API_VULKAN, OS_OSX, VENDOR_ATI, DRIVER_PORTABILITY, Family::UNKNOWN,
BUG_BROKEN_SUBGROUP_INVOCATION_ID, -1.0, -1.0, true},
};

static std::map<Bug, BugInfo> m_bugs;
@@ -305,6 +305,12 @@ enum Bug
// Started version: -1
// Ended version: -1
BUG_BROKEN_SSBO_FIELD_ATOMICS,

// BUG: Accessing gl_SubgroupInvocationID causes the Metal shader compiler to crash.
// Affected devices: AMD (macOS)
// Started version: -1
// Ended version: -1
BUG_BROKEN_SUBGROUP_INVOCATION_ID,
};

// Initializes our internal vendor, device family, and driver version

0 comments on commit a6baca6

Please sign in to comment.