Updates to support Vulkan SDK 1.1.121.

Remove obsolescence log message for vkCreateMacOSSurfaceMVK()
and vkCreateIOSSurfaceMVK() functions.
Fix test for alignment of invalid pixel formats.
Update dependency libraries to match Vulkan SDK 1.1.121.
Update to renaming of VK_INTEL_shader_integer_functions2
enums and structs in latest Vulkan headers.
Update Whats_New.md document.
This commit is contained in:
Bill Hollings 2019-09-10 13:25:19 -04:00
parent f8d8f9bd57
commit d585a9819e
9 changed files with 2405 additions and 2299 deletions

View File

@ -16,7 +16,7 @@ For best results, use a Markdown reader.*
MoltenVK 1.0.37
---------------
Released TBD
Released 2019/09/10
- Add support for extensions:
- `VK_KHR_device_group`
@ -25,17 +25,21 @@ Released TBD
- `vkInvalidateMappedMemoryRanges()` synchronizes managed device memory to CPU.
- Track supported instance and device extensions correctly.
- Revert to supporting host-coherent memory for linear images on macOS.
- Report limit of 64KB for constant buffer bindings on macOS.
- Disable depth and/or stencil testing if corresponding attachment is missing.
- Ensure Vulkan loader magic number is set every time before returning any dispatchable Vulkan handle.
- Fix crash when `VkDeviceCreateInfo` specifies queue families out of numerical order.
- Fix crash in `vkDestroyPipelineLayout()`.
- Fix crash when signalling swapchain semaphore using `MTLEvent`.
- Fix crash when determining alignment of invalid pixel formats.
- `vkCmdBlitImage():` Support format component swizzling.
- `vkCmdClearImage():` Set error if attempt made to clear 1D image, and fix validation of depth attachment formats.
- `vkCreateRenderPass():` Return `VK_ERROR_FORMAT_NOT_SUPPORTED` if format not supported.
- `vkCmdFillBuffer():` Improve performance 150x by using parallelism more effectively.
- Support optional use of `MTLFence` for Vulkan semaphores via the `MVK_ALLOW_METAL_FENCES` environment variable.
- Remove error logging on `VK_TIMEOUT` of `VkSemaphore` and `VkFence`.
- Remove log message warning of obsolescence of `vkCreateMacOSSurfaceMVK()` and `vkCreateIOSSurfaceMVK()` functions.
- Streamline design and use of `MVKSemaphore`.
- Consolidate the various linkable objects into a `MVKLinkableMixin` template base class.
- Use `MVKVector` whenever possible in MoltenVK, especially within render loop.
- No longer prefer dedicated allocations for buffer memory, including buffer-backed images.
@ -44,26 +48,34 @@ Released TBD
- Always submit surface presentations using `MTLCommandBuffer`.
`MVKConfiguration::presentWithCommandBuffer` is now obsolete.
- Don't use `MTLCommandBuffer push/popDebugGroup` if not available.
- `MVKSwapchain::signalWhenAvailable()` add autoreleasepool around `MTLCommandBuffer` use.
- Add ability to automatically cause an *Xcode* GPU capture without developer intervention.
- On macOS, limit uniform buffer bindings to 64k.
- Update `VK_MVK_MOLTENVK_SPEC_VERSION` to version 22.
- Update dependency libraries to match Vulkan SDK 1.1.121.
- Update to renaming of `VK_INTEL_shader_integer_functions2` enums and structs in latest Vulkan headers.
- Update to latest SPIRV-Cross version:
- Support the `SPV_EXT_fragment_shader_interlock` extension.
- MSL: Deal with array copies from and to threadgroup.
- MSL: Deal with `Modf/Frexp` where output is access chain to scalar.
- MSL: Inline all emitted functions.
- MSL: Inline all non-entry-point functions.
- MSL: Add `{Base,}{Vertex,Instance}{,Index}` to `bitcast_from_builtin_load`.
- MSL: Add support for sampler Y'CbCr conversion.
- MSL: Force storage images on iOS to use discrete descriptors.
- MSL: Support dynamic offsets for buffers in argument buffers.
- Support the `SPV_EXT_fragment_shader_interlock` extension.
- MSL: Cleanup temporary use with `emit_uninitialized_temporary`.
- MSL: Unify the `get_*_address_space()` methods.
- Assume image and sampler can be `RelaxedPrecision`.
- Fix post-depth coverage for ESSL.
- Fix variable scope when switch block exits multiple times.
- Fix severe performance issue with invariant expression invalidation.
- Fix `ParsedIR::mark_used_as_array_length(uint32_t id)`
- Deal correctly with sign on bitfield operations.
- Elide branches to continue block when continue block is also a merge.
- Move branchless analysis to CFG.
- Deal with `ldexp` taking `uint` input.
- Do not allow base expressions for non-native row-major matrices.
- GLSL: Assume image and sampler can be `RelaxedPrecision`.
- GLSL: Fix post-depth coverage for ESSL.
- Do not force temporary unless continue-only for loop dominates.
- Fix `ParsedIR::mark_used_as_array_length(uint32_t id)`.
- Refactor into stronger types in public API.

File diff suppressed because it is too large Load Diff

View File

@ -1 +1 @@
e3f96a9ccab9397481eb81c4d9bce4ea7590dc33
5671d014bc1792a116d374792f8a6cfba2e6f512

View File

@ -1 +1 @@
fb1fd1d63eb20cc6f922228f04d8b96cec452b46
bcabc204a27a93d6b686920a6d46c17f9aaa3ce0

View File

@ -1 +1 @@
5a52ebd648b5baf94f2346819b5cf3fdc14b4127
2403b94ed6463062acff8cfff563ad7ec5cf2b58

View File

@ -1 +1 @@
333d1c95792692205472c457d7bec915a94c8000
34953810a62c5230cc059cfdf42dc44c5aab2246

View File

@ -139,8 +139,8 @@ void MVKPhysicalDevice::getFeatures(VkPhysicalDeviceFeatures2* features) {
portabilityFeatures->samplerMipLodBias = false;
break;
}
case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_INTEGER_FUNCTIONS2_FEATURES_INTEL: {
auto* shaderIntFuncsFeatures = (VkPhysicalDeviceShaderIntegerFunctions2INTEL*)next;
case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_INTEGER_FUNCTIONS_2_FEATURES_INTEL: {
auto* shaderIntFuncsFeatures = (VkPhysicalDeviceShaderIntegerFunctions2FeaturesINTEL*)next;
shaderIntFuncsFeatures->shaderIntegerFunctions2 = true;
break;
}
@ -1164,22 +1164,20 @@ void MVKPhysicalDevice::initProperties() {
_properties.limits.nonCoherentAtomSize = _metalFeatures.mtlBufferAlignment;
if ([_mtlDevice respondsToSelector: @selector(minimumLinearTextureAlignmentForPixelFormat:)]) {
// Figure out the greatest alignment required by all supported formats, and
// whether or not they only require alignment to a single texel. We'll use this
// information to fill out the VkPhysicalDeviceTexelBufferAlignmentPropertiesEXT
// struct.
// Figure out the greatest alignment required by all supported formats, and whether
// or not they only require alignment to a single texel. We'll use this information
// to fill out the VkPhysicalDeviceTexelBufferAlignmentPropertiesEXT struct.
uint32_t maxStorage = 0, maxUniform = 0;
bool singleTexelStorage = true, singleTexelUniform = true;
mvkEnumerateSupportedFormats({0, 0, VK_FORMAT_FEATURE_UNIFORM_TEXEL_BUFFER_BIT | VK_FORMAT_FEATURE_STORAGE_TEXEL_BUFFER_BIT}, true, [&](VkFormat vk) {
// MTLDevice minimumLinearTextureAlignmentForPixelFormat with MTLPixelFormatInvalid will cause as a failed assertion on iOS 13.x and iPad OS 13.x
if ( vk == VK_FORMAT_UNDEFINED )
return false;
MTLPixelFormat mtlFmt = mvkMTLPixelFormatFromVkFormat(vk);
if ( !mtlFmt ) { return false; } // If format is invalid, avoid validation errors on MTLDevice format alignment calls
NSUInteger alignment;
if ([_mtlDevice respondsToSelector: @selector(minimumTextureBufferAlignmentForPixelFormat:)]) {
alignment = [_mtlDevice minimumTextureBufferAlignmentForPixelFormat: mvkMTLPixelFormatFromVkFormat(vk)];
alignment = [_mtlDevice minimumTextureBufferAlignmentForPixelFormat: mtlFmt];
} else {
alignment = [_mtlDevice minimumLinearTextureAlignmentForPixelFormat: mvkMTLPixelFormatFromVkFormat(vk)];
alignment = [_mtlDevice minimumLinearTextureAlignmentForPixelFormat: mtlFmt];
}
VkFormatProperties props = mvkVkFormatProperties(vk, getFormatIsSupported(vk));
// For uncompressed formats, this is the size of a single texel.

View File

@ -43,7 +43,7 @@ MVKSurface::MVKSurface(MVKInstance* mvkInstance,
const Vk_PLATFORM_SurfaceCreateInfoMVK* pCreateInfo,
const VkAllocationCallbacks* pAllocator) : _mvkInstance(mvkInstance) {
MVKLogInfo("%s(): This function is obsolete. Consider using the vkCreateMetalSurfaceEXT() function from the VK_EXT_metal_surface extension instead.", STR(vkCreate_PLATFORM_SurfaceMVK));
// MVKLogInfo("%s(): This function is obsolete. Consider using the vkCreateMetalSurfaceEXT() function from the VK_EXT_metal_surface extension instead.", STR(vkCreate_PLATFORM_SurfaceMVK));
// Get the platform object contained in pView
id<NSObject> obj = (id<NSObject>)pCreateInfo->pView;

View File

@ -87,7 +87,7 @@ MVK_EXTENSION(AMD_negative_viewport_height, AMD_NEGATIVE_VIEWPORT_HEIGHT, MVK_EX
MVK_EXTENSION(AMD_shader_image_load_store_lod, AMD_SHADER_IMAGE_LOAD_STORE_LOD, MVK_EXTENSION_DEVICE)
MVK_EXTENSION(AMD_shader_trinary_minmax, AMD_SHADER_TRINARY_MINMAX, MVK_EXTENSION_DEVICE)
MVK_EXTENSION(IMG_format_pvrtc, IMG_FORMAT_PVRTC, MVK_EXTENSION_DEVICE)
MVK_EXTENSION(INTEL_shader_integer_functions2, INTEL_SHADER_INTEGER_FUNCTIONS2, MVK_EXTENSION_DEVICE)
MVK_EXTENSION(INTEL_shader_integer_functions2, INTEL_SHADER_INTEGER_FUNCTIONS_2, MVK_EXTENSION_DEVICE)
MVK_EXTENSION_LAST(NV_glsl_shader, NV_GLSL_SHADER, MVK_EXTENSION_DEVICE)
#undef MVK_EXTENSION