D3D12 Memory Allocator 1.0.0

In July 2017 we released first public version of Vulkan Memory Allocator. Since then the library is in ongoing development, got few major releases, one general redesign, and currently at version 2.2.0 it supports many useful features. During that time it has been successfully used in many Vulkan® projects, from amateur and educational experiments to AAA game titles, from Windows® PC through Linux®, MacOS, to mobile platforms like Android.

Direct3D 12 is another explicit graphics API that offers similar set of features and performance as Vulkan. A recommendation to allocate large memory blocks and sub-allocate parts of them for your textures and buffers holds there as well. That’s why today we want to present our new project: D3D12 Memory Allocator. It is another C++ library intended to be a D3D12-equivalent of VMA. The style of its API is adjusted to be similar to DirectX® rather than Vulkan, so it’s easy to learn and integrate into your project.

The initial version 1.0.0 we present here is just the beginning of its development. It provides minimum set of features, but it’s already useful for D3D12 applications and has been successfully integrated in one large game project by a developer whom we already shared the code with. Future development is planned to reach feature-parity with VMA and beyond.

D3D12MA has the following key features:

  • Allocates and keeps track of bigger memory heaps, used and unused ranges inside them, finds best matching unused ranges to create new resources there as placed resources.
  • Automatically respects alignment requirements for created resources.
  • Automatically handles resource heap tier – whether it’s D3D12_RESOURCE_HEAP_TIER_1 that requires to keep certain classes of resources separate or D3D12_RESOURCE_HEAP_TIER_2 that allows to keep them all together.

Additional features:

  • Well-documented – description of all classes and functions provided, along with chapters that contain general description and example code.
  • Thread-safety: Library is designed to be used in multithreaded code.
  • Configuration: Fill optional members of ALLOCATOR_DESC structure to provide custom CPU memory allocator and other parameters.
  • Customization: Predefine appropriate macros to provide your own implementation of external facilities used by the library, like assert, mutex, and atomic.

You can find the project as D3D12MemoryAllocator repository on GitHub. The repository also includes documentation and a sample application that shows how the library can be used.

Latest news

Looking for a good place to get started with exploring GPUOpen?

Getting started: our software

New or fairly new to AMD’s tools, libraries, and effects? This is the best place to get started on GPUOpen!

Getting started: development and performance

Looking for tips on getting started with developing and/or optimizing your game, whether on AMD hardware or generally? We’ve got you covered!

You may also like...

Explore our huge collection of detailed tutorials, sample code, presentations, and documentation to find answers to your graphics development questions.

Create wonder. No black boxes.

The home of great performance and optimization advice for AMD RDNA™ 2 GPUs, AMD Ryzen™ CPUs, and so much more.

Browse all our useful samples. Perfect for when you’re needing to get started, want to integrate one of our libraries, and much more.

Discover what our SDK technologies can offer you. Query hardware or software, manage memory, create rendering applications or machine learning, and much more!

Analyze, Optimize, Profile, Benchmark. We provide you with the developer tools you need to make sure your game is the best it can be!