createPipelineCache :: MonadIO io=> Devicedeviceis the logical device that creates the pipeline cache object.-> PipelineCacheCreateInfopCreateInfois a pointer to a PipelineCacheCreateInfo structure containing initial parameters for the pipeline cache object.->"allocator"
::: Maybe AllocationCallbackspAllocatorcontrols host memory allocation as described in the Memory Allocation chapter.-> io PipelineCache
vkCreatePipelineCache - Creates a new pipeline cache
Description
Applications can track and manage the total host memory size of a
pipeline cache object using the pAllocator. Applications can limit
the amount of data retrieved from a pipeline cache object in
getPipelineCacheData. Implementations should not internally limit
the total number of entries added to a pipeline cache object or the
total host memory consumed.
Once created, a pipeline cache can be passed to the createGraphicsPipelines createRayTracingPipelinesKHR, createRayTracingPipelinesNV, createDataGraphPipelinesARM, and createComputePipelines commands. If the pipeline cache passed into these commands is not NULL_HANDLE, the implementation will query it for possible reuse opportunities and update it with new content. The use of the pipeline cache object in these commands is internally synchronized, and the same pipeline cache object can be used in multiple threads simultaneously.
If flags of pCreateInfo includes
PIPELINE_CACHE_CREATE_EXTERNALLY_SYNCHRONIZED_BIT,
all commands that modify the returned pipeline cache object must be
externally synchronized.
Implementations should make every effort to limit any critical
sections to the actual accesses to the cache, which is expected to be
significantly shorter than the duration of the vkCreate*Pipelines
commands.
Valid Usage (Implicit)
devicemust be a valid Device handle
pCreateInfomust be a valid pointer to a valid PipelineCacheCreateInfo structureIf
pAllocatoris notNULL,pAllocatormust be a valid pointer to a valid AllocationCallbacks structurepPipelineCachemust be a valid pointer to a PipelineCache handle
Return Codes
See Also
VK_VERSION_1_0, AllocationCallbacks, Device, PipelineCache, PipelineCacheCreateInfo