| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Vulkan.Core10.Enums.SystemAllocationScope
Synopsis
- newtype SystemAllocationScope where
- SystemAllocationScope Int32
- pattern SYSTEM_ALLOCATION_SCOPE_COMMAND :: SystemAllocationScope
- pattern SYSTEM_ALLOCATION_SCOPE_OBJECT :: SystemAllocationScope
- pattern SYSTEM_ALLOCATION_SCOPE_CACHE :: SystemAllocationScope
- pattern SYSTEM_ALLOCATION_SCOPE_DEVICE :: SystemAllocationScope
- pattern SYSTEM_ALLOCATION_SCOPE_INSTANCE :: SystemAllocationScope
Documentation
newtype SystemAllocationScope Source #
VkSystemAllocationScope - Allocation scope
Description
SYSTEM_ALLOCATION_SCOPE_COMMANDspecifies that the allocation is scoped to the duration of the Vulkan command.
SYSTEM_ALLOCATION_SCOPE_OBJECTspecifies that the allocation is scoped to the lifetime of the Vulkan object that is being created or used.SYSTEM_ALLOCATION_SCOPE_CACHEspecifies that the allocation is scoped to the lifetime of aPipelineCacheorValidationCacheEXTobject.SYSTEM_ALLOCATION_SCOPE_DEVICEspecifies that the allocation is scoped to the lifetime of the Vulkan device.SYSTEM_ALLOCATION_SCOPE_INSTANCEspecifies that the allocation is scoped to the lifetime of the Vulkan instance.
Most Vulkan commands operate on a single object, or there is a sole
object that is being created or manipulated. When an allocation uses an
allocation scope of SYSTEM_ALLOCATION_SCOPE_OBJECT or
SYSTEM_ALLOCATION_SCOPE_CACHE, the allocation is scoped to the object
being created or manipulated.
When an implementation requires host memory, it will make callbacks to the application using the most specific allocator and allocation scope available:
- If an allocation is scoped to the duration of a command, the
allocator will use the
SYSTEM_ALLOCATION_SCOPE_COMMANDallocation scope. The most specific allocator available is used: if the object being created or manipulated has an allocator, that object’s allocator will be used, else if the parentDevicehas an allocator it will be used, else if the parentInstancehas an allocator it will be used. Else, - If an allocation is associated with a
ValidationCacheEXTorPipelineCacheobject, the allocator will use theSYSTEM_ALLOCATION_SCOPE_CACHEallocation scope. The most specific allocator available is used (cache, else device, else instance). Else, - If an allocation is scoped to the lifetime of an object, that object
is being created or manipulated by the command, and that object’s
type is not
DeviceorInstance, the allocator will use an allocation scope ofSYSTEM_ALLOCATION_SCOPE_OBJECT. The most specific allocator available is used (object, else device, else instance). Else, - If an allocation is scoped to the lifetime of a device, the
allocator will use an allocation scope of
SYSTEM_ALLOCATION_SCOPE_DEVICE. The most specific allocator available is used (device, else instance). Else, - If the allocation is scoped to the lifetime of an instance and the
instance has an allocator, its allocator will be used with an
allocation scope of
SYSTEM_ALLOCATION_SCOPE_INSTANCE. - Otherwise an implementation will allocate memory through an alternative mechanism that is unspecified.
See Also
Constructors
| SystemAllocationScope Int32 |
Bundled Patterns