Comments (3)
There are a few limitations that we’ll need to assess and resolve:
-
MTLCommandBuffers
are disposable and can’t be reused…which means that population of the MTLCommandBuffer on theVkCommandBuffer
population thread will only ever apply to the first submission to the queue. After that…each resubmission of theVkCommandBuffer
would trigger the creation and population of aMTLCommandBuffer
on the rendering thread. -
MTLCommandBuffers must be created for a specific
MTLQueue
, whereasVkCommandBuffers
are allocated via a command pool associated with a queue family. We could possibly map these together by limiting Vulkan to one queue per queue family…if such a limitation makes conceptual sense. -
Creating one
MTLCommandBuffer
for eachVkCommandBuffer
works against theMTLCommandBuffer
consolidation requested in issue #33 and implemented in PR #40. We could possibly provide a config switch that would let an app choose which optimization to use (consolidatedMTLCommandBuffers
vs sideband-thread population of aMTLCommandBuffer
on the first submission of aVkCommandBuffer
).
from moltenvk.
@billhollings Thank you for the analysis. Based on the excellent performance we are seeing from the work in #33 I am less convinced that what I proposed here is actually a good idea. For our engine, it will almost certainly make performance considerably worse based on what I've learned about how sensitive Metal is to command buffer granularity. I think doing this work should probably wait until there is an application that would benefit from it. It's OK with me if we close this bug for now.
from moltenvk.
This enhancement was added in PR #261. It defaults to disabled, and can be enabled via MoltenVK configuration.
from moltenvk.
Related Issues (20)
- Possible regression in Khronos buffer_device_address sample in MoltenVK 1.2.8 HOT 5
- GPU address fault error when using descriptor indexing + variable descriptor count HOT 2
- Unnecessary 'Metal does not support disabling primitive restart' warnings HOT 8
- Support VK_EXT_rasterization_order_attachment_access
- EXC_BAD_ACCESS from mvkUpdateDescriptorSets on macOS HOT 13
- Latest MoltenVK instable on iOS and macOS HOT 7
- Uncaught selector, -[CAMetalDrawable addPresentedHandler:] (first introduced 1.2.6) HOT 20
- Possible regression in timeline semaphores on iOS in MoltenVK 1.2.10 HOT 3
- Was Vulkan SDK 1.3.290 released with MoltenVK 1.2.9? HOT 2
- Texture sharing between OpenGL and Vulkan on macOS
- Library not loaded: CoreSimulator when building MoltenVK in CI HOT 2
- Vulkan checkinfo broken in MoltenVK MacOS M1 HOT 5
- vkQueuePresentKHR often crashes HOT 2
- Bindless textures not always work with 1.2.10 on mac HOT 1
- Support more 32-bit floating-point pixel format caps on iOS HOT 1
- Enable blending cap for RGB9E5Float HOT 1
- `vkCmdSetScissor` behavior violates vulkan spec
- Swapchain images are incorrectly displayed in borderless fullscreen when using particular VkFormats
- vkQueueSubmit is leaking 13 GB of memory at every call when using an SSBO HOT 2
- DeviceAddressBuffer (encodeGPUAddressableBuffers) resource usage bug
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from moltenvk.