2982 Commits

Author SHA1 Message Date
Bill Hollings
bdbf9abf0a
Merge pull request #1944 from RaafatAkkad/main
Allows maximizing the concurrent executing compilation tasks.
2023-06-14 17:58:40 -04:00
Raafat Akkad
e7243572d7 Allows maximizing the concurrent executing compilation tasks.
https://developer.apple.com/videos/play/wwdc2023/10127/?time=540
On an M1 Pro Macbook Pro 16" maximumConcurrentCompilationTaskCount goes from 2 to 8
2023-06-14 20:17:53 +01:00
Bill Hollings
4949c34b4d
Merge pull request #1936 from billhollings/present-imm-mode-unless-present-time
Support VK_PRESENT_MODE_IMMEDIATE_KHR if VkPresentTimeGOOGLE::desiredPresentTime is zero.
2023-06-07 18:41:57 -04:00
Bill Hollings
49748602dd
Merge pull request #1935 from cdavis5e/shader-demote-to-helper
Advertise the VK_EXT_shader_demote_to_helper_invocation extension.
2023-06-07 16:10:27 -04:00
Chip Davis
750adcaae2 Advertise the VK_EXT_shader_demote_to_helper_invocation extension.
As of macOS Big Sur and iOS/tvOS 14, the `discard_fragment()` function
in MSL is defined to have demote semantics; that is, fragment shader
output is discarded, but the fragment shader thread continues to run as
a helper invocation. This is very useful for Direct3D emulation, since
this is the semantic that HLSL `discard` has.

Signed-off-by: Chip Davis <chip@holochip.com>
2023-06-07 12:48:02 -07:00
Bill Hollings
3690a52a0e
Merge pull request #1942 from rcombs/spirv-cross-fix
Update SPIRV-Cross revision to include function constant fix
2023-06-07 11:35:08 -04:00
rcombs
3fbde1615d update SPIRV-Cross revision to include function constant fix; closes #1941 2023-06-06 14:26:29 -05:00
Bill Hollings
6fb53471b1 Support VK_PRESENT_MODE_IMMEDIATE_KHR if VkPresentTimeGOOGLE::desiredPresentTime is zero.
- [MTLDrawable presentAtTime:] syncs to display vsync. To support
  VK_PRESENT_MODE_IMMEDIATE_KHR while using VkPresentTimeGOOGLE::presentID,
  only call presentAtTime: if VkPresentTimeGOOGLE::desiredPresentTime has
  been explicitly set to a non-zero value.
- Clarify initially clearing MVKImagePresentInfo to all zeros.
2023-06-05 19:17:10 -04:00
Bill Hollings
0332055cff
Merge pull request #1927 from billhollings/demo-support-immediate-present-mode
Add support for VK_PRESENT_MODE_IMMEDIATE_KHR to macOS Cube demo.
2023-05-30 21:56:17 -04:00
Bill Hollings
107be116b7 Add support for VK_PRESENT_MODE_IMMEDIATE_KHR to macOS Cube demo.
- Only log performance stats on FPS logging if logging style is explicitly
  set to MVK_CONFIG_ACTIVITY_PERFORMANCE_LOGGING_STYLE_FRAME_COUNT (unrelated).
2023-05-30 21:11:02 -04:00
Bill Hollings
2a4e415665
Merge pull request #1922 from billhollings/fix-comp-enc-state
Ensure compute encoding state is marked dirty for non-dispatch commands.
2023-05-26 08:21:05 -04:00
Bill Hollings
83a1811230 Ensure compute encoding state is marked dirty for non-dispatch commands.
The same compute encoder is used across dispatches and other commands,
which may override compute state, and end up breaking subsequent dispatches.

- Mark compute encoding state dirty when following commands,
  which use Metal compute encoders, are issued:
  - vkCmdCopyBuffer()
  - vkCmdClearColorImage()
  - vkCmdClearDepthStencilImage()
  - vkCmdFillBuffer()
  - vkCmdCopyQueryPoolResults()

- MVKCommandEncoder move marking compute state dirty from
  endCurrentMetalEncoding() to getMTLComputeEncoder().
- For efficiency, don't prematurely force end of query copy compute encoder
  used on renderpass end, in case compute dispatches follow.

- Update MoltenVK to 1.2.5 (unrelated).
2023-05-26 00:06:40 -04:00
Bill Hollings
4c6bfbebd1
Merge pull request #1920 from billhollings/always-advertise-VK_KHR_depth_stencil_resolve
Advertise VK_KHR_depth_stencil_resolve extension on all devices.
2023-05-23 20:14:26 -04:00
Bill Hollings
b26ce32a60 Advertise VK_KHR_depth_stencil_resolve extension on all devices.
Advertise VK_KHR_depth_stencil_resolve extension on early iOS devices,
since VK_RESOLVE_MODE_SAMPLE_ZERO_BIT is supported on all devices,
even if other resolve modes are not, and makes it consistent with
Vulkan 1.2 mandatory support for VK_RESOLVE_MODE_SAMPLE_ZERO_BIT.
2023-05-23 19:01:31 -04:00
Bill Hollings
3d7f996f6a
Merge pull request #1918 from billhollings/accumulate-render-stages
Accumulate render stages when a resource is used by multiple descriptor bindings.
2023-05-23 16:55:51 -04:00
Bill Hollings
b863ecef4d Accumulate render stages when a resource is used by multiple descriptor bindings. 2023-05-23 13:13:19 -04:00
Bill Hollings
a832e3805a
Merge pull request #1916 from billhollings/sdk-1.3.250
Update dependency libraries to match Vulkan SDK 1.3.250.
2023-05-23 11:06:02 -04:00
Bill Hollings
c231c90dd4 Update dependency libraries to match Vulkan SDK 1.3.250.
- Update Whats New document.
2023-05-22 20:00:14 -04:00
Bill Hollings
1a386e0493
Merge pull request #1913 from italomandara/update-spirv-cross-revision
Update SPIRV-Cross revision to fix explicit LOD workaround regression
2023-05-21 07:19:58 -04:00
Italo Mandara
0125e5b739 Revert "Allow to disable Explicit LOD Workaround"
This reverts commit 6f3a2b709fbfcfdf7dc077b80b12f02463cc07b1.
2023-05-21 00:27:16 +01:00
Italo Mandara
6c633a7a18 update SPIRV-Cross revision to include explicit LOD workaround regression fix 2023-05-21 00:26:44 +01:00
Bill Hollings
b3ae0f48d0
Merge pull request #1911 from etang-cw/NoAbortOnCompilationFailure
Check if shader compiled before adding it to a pipeline
2023-05-18 11:47:46 -04:00
Evan Tang
75b4d26fbc Check if shader compiled before adding it to a pipeline
Prevents Metal from aborting when you try to set a null function on the descriptor
2023-05-17 15:47:47 -05:00
Bill Hollings
ae0ee6a012
Merge pull request #1908 from billhollings/fix-deviceUUID
Populate deviceUUID from MTLDevice location and peer group info.
2023-05-17 15:09:46 -04:00
Bill Hollings
665ef6df13 Improve support for deviceUUID and deviceLUID.
- MTLDevice registryID is not constant across OS reboots,
  which is not conformant with deviceUUID requirements.
- Replace with combination of MTLDevice location, locationNumber,
  peerGroupID, and peerIndex, which should define uniqueness,
  and should be constant across OS reboots.
- Populate deviceLUID from MTLDevice registryID.
2023-05-17 14:50:48 -04:00
Bill Hollings
6111aabc8f
Merge pull request #1910 from billhollings/fix-ts-qp
Do not fail on request for timestamp query pool that is too large.
2023-05-17 10:50:23 -04:00
Bill Hollings
d29092ab78 Do not fail on request for timestamp query pool that is too large.
- Report error, but do not fail on request for timestamp query pool
  that is too large for MTLCounterSampleBuffer.
- Change reported error to VK_ERROR_OUT_OF_DEVICE_MEMORY and clarify
  text of error reported when timestamp query pool is too large.
- Clarify error reported for occlusion query pool errors (unrelated).
2023-05-16 17:26:26 -04:00
Bill Hollings
44c3063439
Merge pull request #1906 from billhollings/ensure-present-time
Ensure swapchain image presented time is always populated when requested.
2023-05-15 19:09:40 -04:00
Bill Hollings
65ce195a6f Ensure swapchain image presented time is always populated when requested.
If Metal reports zero presentedTime, and desired presentation
time has not been set by app, use the current time.
2023-05-15 18:47:22 -04:00
Bill Hollings
9c55ef3116
Merge pull request #1905 from billhollings/id-unsupp-dvc-feat-flags
Identify each unsupported device feature flag that the app attempts to enable.
2023-05-15 15:49:45 -04:00
Bill Hollings
4893f78b29 Identify each unsupported device feature flag that the app attempts to be enable.
- Make MVKDevice::enableFeatures() functions into templates to pass struct type.
- Add mvkGetAddressOfFirstMember() to retrieve the address of the first member of
  a struct, taking into consideration whether the struct has a Vulkan pNext member.
- Add mvk::getTypeName() and mvk::getOrdinalSuffix() string functions.
2023-05-15 15:14:30 -04:00
Bill Hollings
7d4f5745f7
Merge pull request #1903 from ChibiDenDen/simulator_feature_discovery_fix
Fix simulator feature discovery
2023-05-13 12:28:07 -04:00
Bill Hollings
9bdc29a5ec
Merge pull request #1902 from etang-cw/FixReorderCtor
Fix reorder-ctor warning
2023-05-13 12:05:40 -04:00
ChibiDenDen
0139b95849 Fix simulator feature discovery
Fix depth clamp and texture swizzle feature discovery on simulator builds

Both of these features are not supported by the iphone simulator
and leads to crashes when used
2023-05-12 23:41:46 +03:00
Evan Tang
47ce47ad4c Fix reorder-ctor warning 2023-05-12 14:10:14 -05:00
Bill Hollings
734a185170
Merge pull request #1898 from etang-cw/PushBindPoint
Respect the bind point supplied to vkCmdBindDescriptorSets / vkCmdPushDescriptorSets
2023-05-12 14:42:26 -04:00
Bill Hollings
d3b64c8c53
Merge pull request #1900 from Steveice10/release-workflow-patch
Make the GitHub Actions release workflow more lenient.
2023-05-12 14:13:19 -04:00
Evan Tang
1b6750bef8 Respect the bind point supplied to vkCmdBindDescriptorSets 2023-05-12 13:00:06 -05:00
Steveice10
9c72022ac3
Make the GitHub Actions release workflow more lenient. 2023-05-12 10:11:11 -07:00
Bill Hollings
c893a0380a
Merge pull request #1897 from Steveice10/main
Update release action artifact glob.
2023-05-11 13:38:40 -04:00
Steveice10
0618c43070 Update release action artifact glob. 2023-05-10 23:18:05 -07:00
Bill Hollings
dd5faf2135
Merge pull request #1896 from billhollings/ci-reduce-artifact-sizes
GitHub CI streamline uploaded artifact sizes.
2023-05-10 17:47:13 -04:00
Bill Hollings
3247bd465d GitHub CI streamline uploaded artifact sizes.
- Reinstate per-platform upload artifacts.
- Don't upload shader converter binaries.
2023-05-10 17:27:08 -04:00
Bill Hollings
5bce402a6f
Merge pull request #1895 from Steveice10/main
Add GitHub Actions workflow for automatically creating releases.
2023-05-10 16:03:16 -04:00
Steveice10
f19ac2c03d Add GitHub Actions workflow for automatically creating releases. 2023-05-09 20:50:03 -07:00
Bill Hollings
fbaba84b32
Merge pull request #1893 from billhollings/ci-improvements
GitHub CI improvements.
2023-05-09 11:34:11 -04:00
Bill Hollings
ab5429b18c GitHub CI improvements.
- Build one universal build, instead of per-platform.
- Upload this single build artifact to GitHub.
- Upgrade to v3 of action dependencies to remove Node.js deprecation warnings.
- Avoid use of deprecated set-output GitHub action command.
- Use macOS 13 and Xcode 14.3.
- README.md document access to binary artifacts.
2023-05-09 00:12:16 -04:00
Bill Hollings
dfc0af84aa
Merge pull request #1890 from billhollings/fix-display-timing-race-condition
Fix race condition when updating values in VkPastPresentationTimingGOOGLE.
2023-05-05 17:57:40 -04:00
Bill Hollings
9e466699e5 Fix race condition when updating values in VkPastPresentationTimingGOOGLE.
- MVKPresentableSwapchainImage::presentCAMetalDrawable() and
  addPresentedHandler() pass MVKImagePresentInfo by value instead
  of reference, to avoid callbacks colliding with tracked
  MVKImagePresentInfos being cleared when
  MVKQueuePresentSurfaceSubmission is destroyed after it is run.
2023-05-05 14:45:43 -04:00
Bill Hollings
af9544d4a5
Merge pull request #1889 from billhollings/rmv-config2
Remove vkGetMoltenVKConfiguration2MVK() and vkSetMoltenVKConfiguration2MVK()
2023-05-05 12:33:40 -04:00