-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
VideoCommon: Add shader logic ops support for Apple Silicon GPUs #9990
Closed
Closed
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
1f3e711
OGLRender: If dual source blend is not available, always use shader b…
OatmealDome 189d27f
MoltenVK: Use an external project instead of a pre-compiled dylib
OatmealDome 41265c6
ShaderCompiler: Add new helper define for input attachment binding
OatmealDome 3196d14
MoltenVK: Add patch to turn on framebuffer fetch in SPIRV-Cross
OatmealDome 774afc9
VulkanContext: Set Apple GPUs as supporting framebuffer fetch
OatmealDome 27c8dc3
ConstantManager: Add logic ops to PixelShaderConstants
OatmealDome 655f850
PixelShaderGen: Add logic ops to pixel_shader_uid_data
OatmealDome 6437fef
ShaderCompiler: Add helpers for Metal framebuffer fetch
OatmealDome ad60a65
ShaderCache: Don't turn on logic ops approximation if framebuffer fet…
OatmealDome 828119a
PixelShaderGen: Add shader logic ops support
OatmealDome 63c28e5
UberShaderPixel: Add shader logic ops support
OatmealDome 82e0191
GXPipelineTypes: Bump pipeline UID version
OatmealDome File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
include(ExternalProject) | ||
|
||
ExternalProject_Add(MoltenVK | ||
GIT_REPOSITORY https://github.com/KhronosGroup/MoltenVK.git | ||
GIT_TAG v1.1.4 | ||
|
||
CONFIGURE_COMMAND <SOURCE_DIR>/fetchDependencies --macos | ||
|
||
PATCH_COMMAND git reset --hard v1.1.4 && git apply ${CMAKE_SOURCE_DIR}/Externals/MoltenVK/patches/0001-SPIRVToMSLConverter-Enable-use_framebuffer_fetch_sub.patch | ||
|
||
BUILD_COMMAND make -C <SOURCE_DIR> macos | ||
BUILD_IN_SOURCE ON | ||
BUILD_BYPRODUCTS <SOURCE_DIR>/Package/Release/MoltenVK/dylib/macOS/libMoltenVK.dylib | ||
|
||
INSTALL_COMMAND "" | ||
|
||
LOG_CONFIGURE ON | ||
LOG_BUILD ON | ||
LOG_OUTPUT_ON_FAILURE ON | ||
) |
Binary file not shown.
24 changes: 24 additions & 0 deletions
24
Externals/MoltenVK/patches/0001-SPIRVToMSLConverter-Enable-use_framebuffer_fetch_sub.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
From 4ca33b7a9b149c6fbcc1c88ce08fc49f21294f6d Mon Sep 17 00:00:00 2001 | ||
From: OatmealDome <julian@oatmealdome.me> | ||
Date: Sat, 31 Jul 2021 19:18:35 -0400 | ||
Subject: [PATCH] SPIRVToMSLConverter: Enable use_framebuffer_fetch_subpasses | ||
|
||
--- | ||
.../MoltenVKShaderConverter/SPIRVToMSLConverter.cpp | 1 + | ||
1 file changed, 1 insertion(+) | ||
|
||
diff --git a/MoltenVKShaderConverter/MoltenVKShaderConverter/SPIRVToMSLConverter.cpp b/MoltenVKShaderConverter/MoltenVKShaderConverter/SPIRVToMSLConverter.cpp | ||
index 17c79394..97e98004 100644 | ||
--- a/MoltenVKShaderConverter/MoltenVKShaderConverter/SPIRVToMSLConverter.cpp | ||
+++ b/MoltenVKShaderConverter/MoltenVKShaderConverter/SPIRVToMSLConverter.cpp | ||
@@ -92,6 +92,7 @@ MVK_PUBLIC_SYMBOL SPIRVToMSLConversionOptions::SPIRVToMSLConversionOptions() { | ||
#endif | ||
|
||
mslOptions.pad_fragment_output_components = true; | ||
+ mslOptions.use_framebuffer_fetch_subpasses = true; | ||
} | ||
|
||
MVK_PUBLIC_SYMBOL bool mvk::MSLShaderInput::matches(const mvk::MSLShaderInput& other) const { | ||
-- | ||
2.30.1 (Apple Git-130) | ||
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A separate PR to add shader logic ops support on OpenGL ES (Android) will be opened after this is merged.