-
Notifications
You must be signed in to change notification settings - Fork 443
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Question: Guidance re MVK_CONFIG_USE_METAL_ARGUMENT_BUFFERS option #2146
Comments
For now, the big differentiator is how many resources you need. If you can get away with the very small number (31/128) of descriptor resources that are available to Metal without argument buffers, then you can leave BTW, the next round of development on this in the next couple of months, should see us move to argument buffers being used by default, particularly when Metal 3 is available. |
Thanks for the info and heads-up re new developments coming down the pipe. |
How would this affect |
When Metal Argument Buffers are not in use, Metal doesn't formally limit the number of samplers that can be created, hence the essentially infinite value returned in However, Metal does limit the number of samplers that can be used in Metal argument buffers. Therefore, when Metal argument buffers are in use, MoltenVK returns the limit in
Can you provide more info on what is/was breaking? |
On 1.2.9 (the current version packaged by nixpkgs), when starting, a SPIR-V to MSL conversion fails if |
Are there any docs that provide performance guidance on the use of the
MVK_CONFIG_USE_METAL_ARGUMENT_BUFFERS
option?Up to this point I have been using the setting
MVK_CONFIG_USE_METAL_ARGUMENT_BUFFERS_DESCRIPTOR_INDEXING
based on the assumption that performance will be improved. However, empirical evidence shows that I get slightly better performance (~5%) with it set toMVK_CONFIG_USE_METAL_ARGUMENT_BUFFERS_NEVER
, especially on my Apple Silicon M1 Air. On my x86 + AMD GPU machine, improvements are also observable with the setting off (i.e. never) but perhaps less pronounced (<5%) than on the M1.And using
MVK_CONFIG_USE_METAL_ARGUMENT_BUFFERS_ALWAYS
gives the same results asMVK_CONFIG_USE_METAL_ARGUMENT_BUFFERS_DESCRIPTOR_INDEXING
. This is expected sinceVK_EXT_descriptor_indexing
is enabled for my application.I am inclined to turn this setting off, but are there any hints or advice on how I should set this option? Note that I am using push constants almost exclusively for my app so I am not sure how this plays into it.
The text was updated successfully, but these errors were encountered: