diff --git a/Docs/MoltenVK_Runtime_UserGuide.md b/Docs/MoltenVK_Runtime_UserGuide.md
index f2434d10..f236a7e9 100644
--- a/Docs/MoltenVK_Runtime_UserGuide.md
+++ b/Docs/MoltenVK_Runtime_UserGuide.md
@@ -32,6 +32,7 @@ Table of Contents
- [Performance Considerations](#performance)
- [Shader Loading Time](#shader_load_time)
- [Swapchains](#swapchains)
+ - [Timestamping](#timestamping)
- [Xcode Configuration](#xcode_config)
- [Metal System Trace Tool](#trace_tool)
- [Known **MoltenVK** Limitations](#limitations)
@@ -327,6 +328,7 @@ In addition to core *Vulkan* functionality, **MoltenVK** also supports the foll
- `VK_KHR_get_surface_capabilities2`
- `VK_KHR_imageless_framebuffer`
- `VK_KHR_image_format_list`
+- `VK_KHR_incremental_present`
- `VK_KHR_maintenance1`
- `VK_KHR_maintenance2`
- `VK_KHR_maintenance3`
@@ -369,6 +371,7 @@ In addition to core *Vulkan* functionality, **MoltenVK** also supports the foll
- `VK_EXT_metal_objects`
- `VK_EXT_metal_surface`
- `VK_EXT_pipeline_creation_cache_control`
+- `VK_EXT_pipeline_creation_feedback`
- `VK_EXT_post_depth_coverage` *(iOS and macOS, requires family 4 (A11) or better Apple GPU)*
- `VK_EXT_private_data `
- `VK_EXT_robustness2`
@@ -581,6 +584,20 @@ than when using an internal compositor, which increases the risk that a swapchai
vailable when you request it, resulting in frame delays and visual stuttering.
+
+### Timestamping
+
+On non-Apple Silicon devices (older Mac devices), the GPU can switch power and performance
+states as required by usage. This affects the GPU timestamps retrievable through the Vulkan
+API. As a result, the value of `VkPhysicalDeviceLimits::timestampPeriod` can vary over time.
+Consider calling `vkGetPhysicalDeviceProperties()`, when needed, and retrieve the current
+value of `VkPhysicalDeviceLimits::timestampPeriod`, to help you calibrate recent GPU
+timestamps queried through the Vulkan API.
+
+This is not needed on Apple Silicon devices, where all GPU timestamps are always returned
+as nanoseconds, regardless of variations in power and performance states as the app runs.
+
+
### Xcode Configuration
diff --git a/Docs/Whats_New.md b/Docs/Whats_New.md
index 6a69083d..68332ce7 100644
--- a/Docs/Whats_New.md
+++ b/Docs/Whats_New.md
@@ -16,12 +16,14 @@ Copyright (c) 2015-2023 [The Brenwill Workshop Ltd.](http://www.brenwill.com)
MoltenVK 1.2.5
--------------
-Released TBD
+Released 2023/08/15
- Add support for extensions:
+ - `VK_KHR_incremental_present`
- `VK_KHR_shader_non_semantic_info`
- `VK_EXT_4444_formats`
- `VK_EXT_calibrated_timestamps`
+ - `VK_EXT_pipeline_creation_feedback`
- `VK_EXT_shader_demote_to_helper_invocation`
- `VK_EXT_shader_subgroup_ballot`
- `VK_EXT_shader_subgroup_vote`
@@ -31,9 +33,29 @@ Released TBD
- Support maximizing the concurrent executing compilation tasks via `MVKConfiguration::shouldMaximizeConcurrentCompilation`
- Support `VK_PRESENT_MODE_IMMEDIATE_KHR` if `VkPresentTimeGOOGLE::desiredPresentTime` is zero.
- Add support for `VK_PRESENT_MODE_IMMEDIATE_KHR` to macOS Cube demo.
+- Allow both `renderPass` and `VkPipelineRenderingCreateInfo` to be missing.
+- Fix sync delay between calls to `vkQueueSubmit()` on non-Apple-Silicon devices.
- Ensure Xcode simulator always uses 256B buffer alignment.
+- Don't attempt to force the window system to use the same high-power GPU as the app, on every swapchain creation.
- Log more info about SPIR-V to MSL conversion errors.
+- Implement Deferred Host Operations.
+- Support _MSL Version 3.1_.
- Drop official support for using *Xcode 11* to build MoltenVK.
+- To allow building MoltenVK without an internet connection, don't fetch a submodule if the commit is already known.
+- Update dependency libraries to match _Vulkan SDK 1.3.261_.
+- Update to latest SPIRV-Cross:
+ - MSL: Fix argument buffer padding when content includes arrays.
+ - MSL: ray-query intersection params
+ - MSL: Support `SPV_KHR_shader_ballot` and `SPV_KHR_subgroup_vote`.
+ - Skip line directives when emitting loop condition blocks.
+ - MSL: Consider changed array types for array-of-constant-bool in struct.
+ - MSL: Consider bool-short remapping for constant expressions as well.
+ - Minor cleanup in constant_expression().
+ - MSL: Add test for bool-in-struct edge cases.
+ - MSL: Handle more complex array copy scenarios with bool <-> short.
+ - MSL: Handle stores to struct bool[].
+ - MSL: Consider bool/short remapping when dealing with composites.
+ - MSL: fix function constant deduplication misfire
@@ -364,7 +386,6 @@ Released 2022/02/07
- Fix issue where *MSL 2.3* only available on *Apple Silicon*, even on *macOS*.
- Fix memory leak of dummy `MTLTexture` in render subpasses that use no attachments.
- Fix Metal object retain-release errors in assignment operators.
-- Fix sync delay between calls to `vkQueueSubmit()` on non-Apple-Silicon devices.
- Fix use of GPU counter sets on older versions of iOS running on the simulator.
- `mvk::getShaderOutputs()` in `SPRIVReflection.h` support flattening nested structures.
- Replaced ASL logging levels with `MVKConfigLogLevel`.
diff --git a/ExternalDependencies.xcodeproj/project.pbxproj b/ExternalDependencies.xcodeproj/project.pbxproj
index 8cdb8e76..fdbcf75f 100644
--- a/ExternalDependencies.xcodeproj/project.pbxproj
+++ b/ExternalDependencies.xcodeproj/project.pbxproj
@@ -7204,11 +7204,11 @@
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_PARAMETER = YES;
GCC_WARN_UNUSED_VARIABLE = NO;
- IPHONEOS_DEPLOYMENT_TARGET = 11.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 12.0;
MACH_O_TYPE = staticlib;
MACOSX_DEPLOYMENT_TARGET = 10.13;
SKIP_INSTALL = YES;
- TVOS_DEPLOYMENT_TARGET = 11.0;
+ TVOS_DEPLOYMENT_TARGET = 12.0;
};
name = Debug;
};
@@ -7254,11 +7254,11 @@
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_PARAMETER = YES;
GCC_WARN_UNUSED_VARIABLE = NO;
- IPHONEOS_DEPLOYMENT_TARGET = 11.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 12.0;
MACH_O_TYPE = staticlib;
MACOSX_DEPLOYMENT_TARGET = 10.13;
SKIP_INSTALL = YES;
- TVOS_DEPLOYMENT_TARGET = 11.0;
+ TVOS_DEPLOYMENT_TARGET = 12.0;
VALIDATE_PRODUCT = YES;
};
name = Release;
diff --git a/ExternalRevisions/SPIRV-Cross_repo_revision b/ExternalRevisions/SPIRV-Cross_repo_revision
index ce73e44a..590969e2 100644
--- a/ExternalRevisions/SPIRV-Cross_repo_revision
+++ b/ExternalRevisions/SPIRV-Cross_repo_revision
@@ -1 +1 @@
-aafcc207ea82308722124db2575aa95f42cb99c9
+bccaa94db814af33d8ef05c153e7c34d8bd4d685
diff --git a/ExternalRevisions/Vulkan-Headers_repo_revision b/ExternalRevisions/Vulkan-Headers_repo_revision
index e48127cb..a8ebecec 100644
--- a/ExternalRevisions/Vulkan-Headers_repo_revision
+++ b/ExternalRevisions/Vulkan-Headers_repo_revision
@@ -1 +1 @@
-9e61870ecbd32514113b467e0a0c46f60ed222c7
+85c2334e92e215cce34e8e0ed8b2dce4700f4a50
diff --git a/ExternalRevisions/Vulkan-Tools_repo_revision b/ExternalRevisions/Vulkan-Tools_repo_revision
index 4359b342..bf77fda0 100644
--- a/ExternalRevisions/Vulkan-Tools_repo_revision
+++ b/ExternalRevisions/Vulkan-Tools_repo_revision
@@ -1 +1 @@
-695887a994ef9cc00a7aa3f9c00b31a56ea79534
+300d9bf6b3cf7b237ee5e2c1d0ae10b9236f82d3
diff --git a/ExternalRevisions/glslang_repo_revision b/ExternalRevisions/glslang_repo_revision
index d336b042..aba7fbb1 100644
--- a/ExternalRevisions/glslang_repo_revision
+++ b/ExternalRevisions/glslang_repo_revision
@@ -1 +1 @@
-d1517d64cfca91f573af1bf7341dc3a5113349c0
+76b52ebf77833908dc4c0dd6c70a9c357ac720bd
diff --git a/MoltenVK/MoltenVK.xcodeproj/project.pbxproj b/MoltenVK/MoltenVK.xcodeproj/project.pbxproj
index c18c9b14..202efa91 100644
--- a/MoltenVK/MoltenVK.xcodeproj/project.pbxproj
+++ b/MoltenVK/MoltenVK.xcodeproj/project.pbxproj
@@ -478,7 +478,7 @@
DCFD7F4A2A45BC6E007BBBF7 /* MVKRenderPass.mm in Sources */ = {isa = PBXBuildFile; fileRef = A94FB7941C7DFB4800632CA3 /* MVKRenderPass.mm */; };
DCFD7F4B2A45BC6E007BBBF7 /* MVKCmdTransfer.mm in Sources */ = {isa = PBXBuildFile; fileRef = A94FB76D1C7DFB4800632CA3 /* MVKCmdTransfer.mm */; };
DCFD7F4C2A45BC6E007BBBF7 /* MVKCmdQueries.mm in Sources */ = {isa = PBXBuildFile; fileRef = A94FB7711C7DFB4800632CA3 /* MVKCmdQueries.mm */; };
- DCFD7F4D2A45BC6E007BBBF7 /* vk_mvk_moltenvk.mm in Sources */ = {isa = PBXBuildFile; fileRef = A94FB7AC1C7DFB4800632CA3 /* vk_mvk_moltenvk.mm */; };
+ DCFD7F4D2A45BC6E007BBBF7 /* mvk_api.mm in Sources */ = {isa = PBXBuildFile; fileRef = A94FB7AC1C7DFB4800632CA3 /* mvk_api.mm */; };
DCFD7F4E2A45BC6E007BBBF7 /* MVKSwapchain.mm in Sources */ = {isa = PBXBuildFile; fileRef = A94FB79C1C7DFB4800632CA3 /* MVKSwapchain.mm */; };
DCFD7F4F2A45BC6E007BBBF7 /* MVKCommandEncoderState.mm in Sources */ = {isa = PBXBuildFile; fileRef = A95B7D681D3EE486003183D3 /* MVKCommandEncoderState.mm */; };
DCFD7F502A45BC6E007BBBF7 /* MVKGPUCapture.mm in Sources */ = {isa = PBXBuildFile; fileRef = A93E83342121F0C8001FEBD4 /* MVKGPUCapture.mm */; };
@@ -1860,7 +1860,7 @@
DCFD7F4A2A45BC6E007BBBF7 /* MVKRenderPass.mm in Sources */,
DCFD7F4B2A45BC6E007BBBF7 /* MVKCmdTransfer.mm in Sources */,
DCFD7F4C2A45BC6E007BBBF7 /* MVKCmdQueries.mm in Sources */,
- DCFD7F4D2A45BC6E007BBBF7 /* vk_mvk_moltenvk.mm in Sources */,
+ DCFD7F4D2A45BC6E007BBBF7 /* mvk_api.mm in Sources */,
DCFD7F4E2A45BC6E007BBBF7 /* MVKSwapchain.mm in Sources */,
DCFD7F4F2A45BC6E007BBBF7 /* MVKCommandEncoderState.mm in Sources */,
DCFD7F502A45BC6E007BBBF7 /* MVKGPUCapture.mm in Sources */,
@@ -2001,7 +2001,7 @@
"\"$(SRCROOT)/../External/cereal/include\"",
"\"${BUILT_PRODUCTS_DIR}\"",
);
- IPHONEOS_DEPLOYMENT_TARGET = 11.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 12.0;
MACH_O_TYPE = staticlib;
MACOSX_DEPLOYMENT_TARGET = 10.13;
MTL_ENABLE_DEBUG_INFO = YES;
@@ -2011,7 +2011,7 @@
PRELINK_LIBS = "${CONFIGURATION_BUILD_DIR}/libMoltenVKShaderConverter.a";
PRODUCT_NAME = MoltenVK;
SKIP_INSTALL = YES;
- TVOS_DEPLOYMENT_TARGET = 11.0;
+ TVOS_DEPLOYMENT_TARGET = 12.0;
WARNING_CFLAGS = "-Wreorder";
};
name = Debug;
@@ -2072,7 +2072,7 @@
"\"$(SRCROOT)/../External/cereal/include\"",
"\"${BUILT_PRODUCTS_DIR}\"",
);
- IPHONEOS_DEPLOYMENT_TARGET = 11.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 12.0;
MACH_O_TYPE = staticlib;
MACOSX_DEPLOYMENT_TARGET = 10.13;
MTL_ENABLE_DEBUG_INFO = NO;
@@ -2082,7 +2082,7 @@
PRELINK_LIBS = "${CONFIGURATION_BUILD_DIR}/libMoltenVKShaderConverter.a";
PRODUCT_NAME = MoltenVK;
SKIP_INSTALL = YES;
- TVOS_DEPLOYMENT_TARGET = 11.0;
+ TVOS_DEPLOYMENT_TARGET = 12.0;
VALIDATE_PRODUCT = YES;
WARNING_CFLAGS = "-Wreorder";
};
diff --git a/MoltenVKShaderConverter/MoltenVKShaderConverter.xcodeproj/project.pbxproj b/MoltenVKShaderConverter/MoltenVKShaderConverter.xcodeproj/project.pbxproj
index 4b64e66d..6372955e 100644
--- a/MoltenVKShaderConverter/MoltenVKShaderConverter.xcodeproj/project.pbxproj
+++ b/MoltenVKShaderConverter/MoltenVKShaderConverter.xcodeproj/project.pbxproj
@@ -732,12 +732,12 @@
"\"$(SRCROOT)/glslang\"",
"\"$(SRCROOT)/glslang/External/spirv-tools/include\"",
);
- IPHONEOS_DEPLOYMENT_TARGET = 11.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 12.0;
MACH_O_TYPE = staticlib;
MACOSX_DEPLOYMENT_TARGET = 10.13;
PRODUCT_NAME = MoltenVKShaderConverter;
SKIP_INSTALL = YES;
- TVOS_DEPLOYMENT_TARGET = 11.0;
+ TVOS_DEPLOYMENT_TARGET = 12.0;
WARNING_CFLAGS = "-Wreorder";
};
name = Debug;
@@ -792,12 +792,12 @@
"\"$(SRCROOT)/glslang\"",
"\"$(SRCROOT)/glslang/External/spirv-tools/include\"",
);
- IPHONEOS_DEPLOYMENT_TARGET = 11.0;
+ IPHONEOS_DEPLOYMENT_TARGET = 12.0;
MACH_O_TYPE = staticlib;
MACOSX_DEPLOYMENT_TARGET = 10.13;
PRODUCT_NAME = MoltenVKShaderConverter;
SKIP_INSTALL = YES;
- TVOS_DEPLOYMENT_TARGET = 11.0;
+ TVOS_DEPLOYMENT_TARGET = 12.0;
VALIDATE_PRODUCT = YES;
WARNING_CFLAGS = "-Wreorder";
};
diff --git a/Scripts/runcts b/Scripts/runcts
index 8b956422..20ae1abe 100755
--- a/Scripts/runcts
+++ b/Scripts/runcts
@@ -93,6 +93,9 @@ if [ "${is_portability}" != "" ]; then
export MVK_CONFIG_ADVERTISE_EXTENSIONS=0xA
fi
+# ----- System settings ------
+export DYLD_LIBRARY_PATH="/usr/local/lib"
+
# ----- Metal validation settings ------
export METAL_DEVICE_WRAPPER_TYPE=1
export METAL_ERROR_MODE=3
diff --git a/Templates/spirv-tools/build.zip b/Templates/spirv-tools/build.zip
index ee4797c8..3879c9b8 100644
Binary files a/Templates/spirv-tools/build.zip and b/Templates/spirv-tools/build.zip differ