-
|
For example, in C/C++ headers if we call a PFN we skip the step when loader choose what driver to call. Do I need to call a PFN or ash does all work? |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments
-
|
@Jerrody Are you referring whether a function is loaded generically through Same for |
Beta Was this translation helpful? Give feedback.
-
|
I'm not big professional I refer to this article where shown that calling of https://gpuopen.com/learn/reducing-vulkan-api-call-overhead/ So, my question is does |
Beta Was this translation helpful? Give feedback.
-
|
@Jerrody Lines 3051 to 3052 in 29b935b
Lines 22 to 24 in 29b935b Which is used when creating a device: Lines 341 to 357 in 29b935b tl;dr: Ash uses optimized function pointers (specific to an instance/device) in almost all cases 1. Footnotes
|
Beta Was this translation helpful? Give feedback.
-
|
Thanks for the answer! |
Beta Was this translation helpful? Give feedback.
@Jerrody
PFN_vkCmdDrawit the type of a function pointer. The loader exports a function with this signature asvkCmdDraw, to be linked against directly but with aforementioned dispatch table overhead. Ash does not use those and instead loads it viavkGetDeviceProcAddr(device, "vkCmdDraw")directly, as written in that article:ash/ash/src/vk/features.rs
Lines 3051 to 3052 in 29b935b
_fhere is the loader function:ash/ash/src/device.rs
Lines 22 to 24 in 29b935b