2637 Commits

Author SHA1 Message Date
MennoVink
53a14dee68
Update MVKGPUCapture.mm
Fix #1598 for macOS 12.4
2022-07-28 20:44:05 +02:00
MennoVink
46b74c8a40
Update copy_lib_to_staging.sh
Allow for building on removable volumes with a space in their name, ie "/Volumes/T7 Touch/"
2022-07-28 20:33:27 +02:00
Bill Hollings
60b2ae51dd
Merge pull request #1663 from billhollings/fix-inline-block-update-desc-with-template
Fix vkUpdateDescriptorSetWithTemplate() for inline block descriptors.
2022-07-27 14:23:51 -04:00
Bill Hollings
40d341ded2 Rename entities for VK_KHR_descriptor_update_template extension.
Rename entities for VK_KHR_descriptor_update_template
extension since it's promoted to Vulkan 1.1.
2022-07-26 17:40:51 -04:00
Bill Hollings
85c4b5c680 Fix vkUpdateDescriptorSetWithTemplate() for inline block descriptors.
Wrap incoming data in VkWriteDescriptorSetInlineUniformBlock
before passing to MVKInlineUniformBlockDescriptor::write().
2022-07-26 16:57:47 -04:00
Bill Hollings
b88c94a651
Merge pull request #1660 from billhollings/gpucapturescope-macos125
Apply Apple fix to MTLCaptureScope retention bug to macOS 12.5.
2022-07-25 13:35:15 -04:00
Bill Hollings
4c18bf49df Apply Apple fix to MTLCaptureScope retention bug to macOS 12.5 and iOS 15.4. 2022-07-25 11:31:44 -04:00
Bill Hollings
33d0420f0c
Merge pull request #1659 from billhollings/ignore-immutable-sampler-update
Ignore sampler update in descriptor set bindings that use immutable samplers.
2022-07-25 00:28:48 -04:00
Bill Hollings
3008ec71e8 Ignore sampler update in descriptor set bindings that use immutable samplers.
Inline MVKDescriptorSetLayoutBinding::getImmutableSampler()
for consistency with usesImmutableSamplers().
2022-07-24 20:36:02 -04:00
Bill Hollings
ed1f1f4866
Merge pull request #1658 from billhollings/fix-query-pool-wait-block
Fix query pool wait block when query is not encoded to be written to.
2022-07-24 16:54:29 -04:00
Bill Hollings
cb57bf9973 Fix query pool wait block when query is not encoded to be written to.
When checking query wait completion, all queries were previously
checked for Available status, and blocked until all became Available.
However, only queries that were encoded to be written should be checked.
It is okay for queries that are not encoded to be written to remain in
Initial state, and not block the wait.
2022-07-24 15:33:02 -04:00
Bill Hollings
a044496a65
Merge pull request #1653 from billhollings/gpuaddress-tier2
Check MTLDevice for gpuAddress support.
2022-07-19 14:52:01 -04:00
Bill Hollings
b04a6db72e Check MTLDevice for gpuAddress support.
Support by the MTLDevice for Metal Tier 2 argument buffers has an
impact on both descriptor indexing and buffer device address support.
Add MVKPhysicalDeviceMetalFeatures::argumentBuffersTier, to track
the MTLDevice argument buffers support tier, set it from
[MTLDevice argumentBuffersSupport], and subsequently enable support for
VK_KHR_buffer_device_address and VK_EXT_buffer_device_address extensions,
and set descriptor indexing resource counts, based on it.
Update documentation requirements.
2022-07-19 14:30:38 -04:00
Bill Hollings
fe8d4d4d34
Merge pull request #1636 from spnda/fix_swapchain_color_space
Fix: No need to check if EXT_swapchain_color_space was enabled
2022-07-15 15:24:08 -04:00
Bill Hollings
6b1d3f5ceb
Merge pull request #1649 from billhollings/mtldevice-barycentric-support
Check MTLDevice for barycentric coordinate support.
2022-07-15 14:57:35 -04:00
Bill Hollings
b54c701393 Check MTLDevice for barycentric coordinate support.
Add MVKPhysicalDeviceMetalFeatures::shaderBarycentricCoordinates,
enable it based on [MTLDevice supportsShaderBarycentricCoordinates],
and subsequently enable support for VK_KHR_fragment_shader_barycentric
and VK_NV_fragment_shader_barycentric extensions, based on it.
2022-07-15 13:43:48 -04:00
Bill Hollings
a8154b8569
Merge pull request #1648 from billhollings/metal-objects-timeline-semaphore
VK_EXT_metal_objects fix issue where timeline event incorrectly created.
2022-07-14 19:17:15 -04:00
Bill Hollings
e1b872479a VK_EXT_metal_objects fix issue where timeline event incorrectly created.
- vkCreateSemaphore() create binary semaphore, unless timeline explicitly
  requested. Previously, timeline semaphore was always created when
  exportObjectType == VK_EXPORT_METAL_OBJECT_TYPE_METAL_SHARED_EVENT_BIT_EXT.
- vkCreateSemaphore() record error when MTLSharedEvent imported or marked for
  export, and MoltenVK configured for VkSemaphore using MTLFence or CPU emulation.
- MVKTimelineSemaphore elide unused constructor arguments.
2022-07-14 18:25:54 -04:00
Bill Hollings
0548b750db
Merge pull request #1645 from billhollings/counterset-crash-on-intel-iris
Work around MTLCounterSet crash on additional Intel Iris Plus Graphics drivers
2022-07-14 13:11:07 -04:00
Bill Hollings
c5c7e80a6c Work around MTLCounterSet crash on additional Intel Iris Plus Graphics drivers.
Add 0x8a51 and 0x8a52 to list of device IDs requiring workaround.
2022-07-14 11:19:48 -04:00
Bill Hollings
41f59d0f3e
Merge pull request #1643 from billhollings/MVKDescriptorPool-ctor
Clean up MVKDescriptorPool constructor.
2022-07-14 10:21:53 -04:00
Bill Hollings
f2031c98da Clean up MVKDescriptorPool constructor.
- Derive MVKDescriptorPool::_hasPooledDescriptors within constructor, instead
  of being passed in from outside, and set before any other construction.
2022-07-13 22:22:24 -04:00
Bill Hollings
beee280ff8
Merge pull request #1641 from billhollings/xcode14-b3
Support Xcode 14.0 Beta 3.
2022-07-13 20:01:54 -04:00
Bill Hollings
6a611ce0c1 Support Xcode 14.0 Beta 3.
- Revert to avoid MTLLanguageVersion1_0 on macOS
  (Xcode 14.0 Beta 2 had erroneously indicated support).
2022-07-13 18:42:05 -04:00
Bill Hollings
5a123f729a
Merge pull request #1639 from js6i/has-pooled-desc
MVKDescriptorPool: Move _hasPooledDescriptors to the top to ensure it's initialized first.
2022-07-13 17:31:20 -04:00
Bill Hollings
313c64df38
Merge pull request #1635 from bangnoise/pr/maxTotalThreadsPerThreadgroup-crash-macOS_10_13
Fix crash creating compute pipelines on macOS versions < 10.14
2022-07-13 10:50:42 -04:00
Jan Sikorski
ab43d7fd53 MVKDescriptorPool: Move _hasPooledDescriptors to the top to ensure it's initialized first.
Creating an empty MVKDescriptorSet will read this member and tip off undefined
behavior sanitizer. It shouldn't actually cause any bugs, but with UB you never
know.
2022-07-13 12:40:18 +02:00
Tom Butterworth
195d302ca3
Style fix
Co-authored-by: Bill Hollings <bill.hollings@brenwill.com>
2022-07-13 09:41:32 +01:00
Bill Hollings
784b0dc28e
Merge pull request #1638 from billhollings/SPV_KHR_physical_storage_buffer
Enhancements to recent extensions.
2022-07-12 14:46:49 -04:00
Bill Hollings
6655beebd7 Enhancements to recent extensions.
- Update to latest SPIRV-Cross to support `SPV_KHR_physical_storage_buffer`
  for `VK_KHR_buffer_device_address` and `VK_EXT_buffer_device_address`
- Add support for `VK_EXT_buffer_device_address` extension.
- Advertise support for `VK_KHR_buffer_device_address`
  and `VK_EXT_buffer_device_address` on macOS 12.5.
- Add appropriate extension reporting and enablement for
  `VkPhysicalDeviceBufferDeviceAddressFeatures`,
  `VkPhysicalDeviceBufferDeviceAddressFeaturesEXT`, and
  `VkPhysicalDeviceFragmentShaderBarycentricFeaturesKHR`.
- Support reading `VkMemoryAllocateFlagsInfo` to identify memory allocations that
  need to support buffer pointer access (in case needed in future on non-shared memory).
- Update `Whats_New.md` and `MoltenVK_Runtime_UserGuide` documents.
2022-07-12 12:35:50 -04:00
sean
f84a9243af
Fix: No need to check if EXT_swapchain_color_space was enabled 2022-07-10 23:03:09 +02:00
Tom Butterworth
f23ff95a4e Fix crash creating compute pipelines on macOS versions < 10.14 2022-07-10 12:24:43 +01:00
Bill Hollings
ba183b4de7
Merge pull request #1632 from billhollings/support_xcode14
Support Xcode 14, macOS 13, and iOS/tvOS 16
2022-07-08 21:35:52 -04:00
Bill Hollings
8dd1454651 Xcode 14 build fixes from code review and further testing.
- Replace use of deprecated kIOMasterPortDefault with MACH_PORT_NULL.
- Convert an inline VLA with constant length array.
- Add input files to all build phases to trigger dependencies when inputs change.
- Add packaging scripts to per-platform ExternalDependencies targets.
2022-07-08 18:07:18 -04:00
Bill Hollings
5b2e153f26 Fix Xcode projects to support Xcode 11.7.
Add dummy output files to each Xcode Run Script build phase that doesn't
already have dependencies set, to avoid setting alwaysOutOfDate flag
(by disabling "Based on dependency analysis" UI flag), which forces
the Xcode project to a version that can't be read by Xcode 11.7.
2022-07-07 22:28:02 -04:00
Bill Hollings
59554d6139 Update Xcode project build settings to Xcode 14. 2022-07-06 18:23:51 -04:00
Bill Hollings
26d4a13e34 Support Xcode 14, macOS 13, and iOS/tvOS 16.
- Update minimum Xcode deployment targets to macOS 10.13, iOS 11, and tvOS 11,
  to avoid Xcode build warnings.
- Add support for MTLLanguageVersion3_0 enumeration.
- Build efficiencies:
  - Build scripts create_dylib.sh and gen_moltenvk_rev_hdr.sh
    only run if build dependencies require it.
  - Packaging and copy_to_staging.sh scripts are too complex to define dependencies,
    and are fast, so configured to run every time, to avoid build warning.
- Replace use of deprecated sprintf() with  snprintf().
- Replace use of deprecated kIOMasterPortDefault with  kIOMainPortDefault.
- Support old-style GPU debug capture only if building for earlier minimum
  deployment targets, to avoid deprecation warning.
- Update minimum Xcode deployment targets of Cube demo to macOS 10.14, iOS 12,
  and tvOS 12, to avoid Xcode build warning regarding MTLSharedEvent in .
- Update README.md document regarding minimum Xcode deployment targets.
2022-07-06 18:15:10 -04:00
Bill Hollings
0f722b84fb
Merge pull request #1619 from spnda/KHR_buffer_device_address
Add support for KHR_buffer_device_address
2022-07-04 16:21:55 -04:00
sean
83c0ca60fb
Add support for KHR_buffer_device_address 2022-06-16 17:32:25 +02:00
Bill Hollings
49f78f91a4
Merge pull request #1621 from billhollings/vk-ext-metal-objects-squash
Add support for VK_EXT_metal_objects extension.
2022-06-13 22:02:04 -04:00
Bill Hollings
2b05b95974 Add support for VK_EXT_metal_objects extension.
Update Vulkan-Headers version to include new VK_EXT_metal_objects extension.
Update MoltenVK version to 1.1.11.
Update What's New document.
2022-06-11 20:10:06 -04:00
Bill Hollings
a909822b69
Merge pull request #1594 from js6i/perf2
Reducing redundant state changes
2022-06-09 14:58:27 -04:00
Jan Sikorski
07780d6a30 Prevent marking state dirty if not needed.
Reduce the impact of Vulkan's overly static state and avoid reencoding
unchanged state repeatedly. Reduces encoding time.
2022-06-09 14:53:29 +02:00
Jan Sikorski
4db43a5c59 Call MVKCommandEncoderState::beginMetalRenderPass() from the overriden method. 2022-06-09 13:40:08 +02:00
Jan Sikorski
745af5379c Avoid redundant resource bindings.
When new descriptor sets are bound, it may be the case that many of the
bindings are not changed from their previous state. Detect this case and avoid
binding the same resources in the Metal comand buffer repeatedly. If possible,
change only the offset. This saves some encoding time.
2022-06-09 13:40:08 +02:00
Bill Hollings
334e0cee69
Merge pull request #1608 from billhollings/sdk-1.3.216
Update dependency libraries to match Vulkan SDK 1.3.216.
2022-06-06 15:13:27 -04:00
Bill Hollings
292ea5e55a Update dependency libraries to match Vulkan SDK 1.3.216.
Update What's New document.
2022-06-04 21:06:56 -04:00
Bill Hollings
02c29477ab
Merge pull request #1604 from billhollings/update-xcode-build-settings
Update Xcode project build settings.
2022-05-30 19:02:30 -04:00
Bill Hollings
7779f3c098 Update Xcode project build settings.
- Add clang -Wreorder warning.
- Align constructor member inits with member order.
- Update build settings to support Xcode 13.4.
2022-05-30 18:12:14 -04:00
Bill Hollings
d7890c7b98
Merge pull request #1603 from scandit-opm/reorder-ctor
Fix reorder-ctor warnings
2022-05-30 15:44:27 -04:00