summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon
diff options
context:
space:
mode:
authorJMC47 <JMC4789@gmail.com>2022-06-24 18:40:47 -0400
committerGitHub <noreply@github.com>2022-06-24 18:40:47 -0400
commitffa3bf86fba4b8e678a57f36f902339c4899f094 (patch)
tree7dee9e31bb06b778c5fb47ded8f6f235da5eb910 /Source/Core/VideoCommon
parent0a2aabe6ec91a5932d3ba6258529af253fec99dd (diff)
parent26529a31ab97f2743fe1a7c52969079d7764bc6d (diff)
Merge pull request #10760 from tellowkrinkle/std430
VideoCommon: Fix SSBO layout and remove associated "bug"
Diffstat (limited to 'Source/Core/VideoCommon')
-rw-r--r--Source/Core/VideoCommon/DriverDetails.cpp2
-rw-r--r--Source/Core/VideoCommon/DriverDetails.h8
-rw-r--r--Source/Core/VideoCommon/PixelShaderGen.cpp19
3 files changed, 3 insertions, 26 deletions
diff --git a/Source/Core/VideoCommon/DriverDetails.cpp b/Source/Core/VideoCommon/DriverDetails.cpp
index 6d7749c949..b532bf785d 100644
--- a/Source/Core/VideoCommon/DriverDetails.cpp
+++ b/Source/Core/VideoCommon/DriverDetails.cpp
@@ -128,8 +128,6 @@ constexpr BugInfo m_known_bugs[] = {
-1.0, -1.0, true},
{API_VULKAN, OS_ALL, VENDOR_ARM, DRIVER_ARM, Family::UNKNOWN, BUG_BROKEN_VECTOR_BITWISE_AND,
-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},
{API_OPENGL, OS_ANDROID, VENDOR_ALL, DRIVER_ALL, Family::UNKNOWN,
diff --git a/Source/Core/VideoCommon/DriverDetails.h b/Source/Core/VideoCommon/DriverDetails.h
index 70c39450c9..e75c4f7926 100644
--- a/Source/Core/VideoCommon/DriverDetails.h
+++ b/Source/Core/VideoCommon/DriverDetails.h
@@ -302,14 +302,6 @@ enum Bug
// Ended version: -1
BUG_BROKEN_VECTOR_BITWISE_AND,
- // BUG: Atomic writes to different fields or array elements of an SSBO have no effect, only
- // writing to the first field/element works. This causes bounding box emulation to give garbage
- // values under OpenGL.
- // Affected devices: AMD (Windows)
- // 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
diff --git a/Source/Core/VideoCommon/PixelShaderGen.cpp b/Source/Core/VideoCommon/PixelShaderGen.cpp
index 4a9e9105a8..950763f5d8 100644
--- a/Source/Core/VideoCommon/PixelShaderGen.cpp
+++ b/Source/Core/VideoCommon/PixelShaderGen.cpp
@@ -464,22 +464,9 @@ void WritePixelShaderCommonHeader(ShaderCode& out, APIType api_type,
}
else
{
- out.Write("SSBO_BINDING(0) buffer BBox {{\n");
-
- if (DriverDetails::HasBug(DriverDetails::BUG_BROKEN_SSBO_FIELD_ATOMICS))
- {
- // AMD drivers on Windows seemingly ignore atomic writes to fields or array elements of an
- // SSBO other than the first one, but using an int4 seems to work fine
- out.Write(" int4 bbox_data;\n");
- }
- else
- {
- // The Metal shader compiler fails to compile the atomic instructions when operating on
- // individual components of a vector
- out.Write(" int bbox_data[4];\n");
- }
-
- out.Write("}};");
+ out.Write("SSBO_BINDING(0) buffer BBox {{\n"
+ " int bbox_data[4];\n"
+ "}};");
}
out.Write(R"(