Module draw2d::graphics::vulkan::device_allocator[][src]

Expand description

This module defines traits and implementations for managing device (gpu) memory.

Big Idea: Allocators should compose.

Allocator Implementations (brainstorm):

  • passthrough allocator -> directly allocates a new block of device memory
    • done!
  • metric-gathering allocator -> decorates an allocator with metrics
    • done!
  • pooling allocator -> something something, gpu memory pools

Structs

A single allocated piece of device memory.

Build a human-friendly markdown report which is printed directly to the console.

An allocator which forces all allocations to have a fixed offset.

A device allocator decorator which records the number of allocations and other metrics. A summary of results is printed when the allocator is destroyed.

Decorate an allocator such that all allocation requests are rounded up to the nearest page.

An allocator implementation which just directly allocates a new piece of device memory on each call.

A device allocator implementation which represents a shared reference to an underlying allocator implementation.

A suballocator can divvy up a single allocation into multiple non-overlapping allocations.

The type index allocator creates a separate memory allocator for each memory type index, then dispatches allocations and frees.

Enums

Units of measurement for memory.

Traits

The external device memory allocation interface. This is the api used by applications to allocate and free memory on the gpu.

Functions

Build the standard allocator implementation.