From df121de03be930338dfecdf01790f2acb5456636 Mon Sep 17 00:00:00 2001 From: sawickiap Date: Fri, 9 Jan 2026 21:29:19 +0100 Subject: [PATCH 1/5] Updated year to 2026 in comments Prepared CHANGELOG.md for next version. Rebuilt the docs. --- CHANGELOG.md | 9 ++++ CMakeLists.txt | 2 +- LICENSE.txt | 2 +- docs/html/allocation_annotation.html | 6 +-- docs/html/annotated.html | 6 +-- docs/html/choosing_memory_type.html | 8 ++-- docs/html/classes.html | 6 +-- docs/html/configuration.html | 6 +-- docs/html/custom_memory_pools.html | 6 +-- docs/html/debugging_memory_usage.html | 6 +-- docs/html/defragmentation.html | 6 +-- docs/html/deprecated.html | 6 +-- .../dir_d44c64559bbebec7f509842c48db8b23.html | 6 +-- docs/html/doxygen.css | 42 ++++++++++++++++--- docs/html/doxygen_crawl.html | 2 +- docs/html/enabling_buffer_device_address.html | 6 +-- docs/html/faq.html | 8 ++-- docs/html/files.html | 6 +-- docs/html/functions.html | 6 +-- docs/html/functions_vars.html | 6 +-- docs/html/general_considerations.html | 6 +-- docs/html/globals.html | 6 +-- docs/html/globals_defs.html | 6 +-- docs/html/globals_enum.html | 6 +-- docs/html/globals_eval.html | 6 +-- docs/html/globals_func.html | 6 +-- docs/html/globals_type.html | 6 +-- docs/html/group__group__alloc.html | 6 +-- docs/html/group__group__init.html | 6 +-- docs/html/group__group__stats.html | 6 +-- docs/html/group__group__virtual.html | 6 +-- docs/html/index.html | 8 ++-- docs/html/memory_mapping.html | 6 +-- docs/html/other_api_interop.html | 6 +-- docs/html/pages.html | 6 +-- docs/html/quick_start.html | 8 ++-- docs/html/resource_aliasing.html | 6 +-- docs/html/statistics.html | 6 +-- docs/html/staying_within_budget.html | 6 +-- docs/html/struct_vma_allocation.html | 6 +-- ...ct_vma_allocation_create_info-members.html | 6 +-- .../struct_vma_allocation_create_info.html | 16 +++---- .../struct_vma_allocation_info-members.html | 6 +-- docs/html/struct_vma_allocation_info.html | 10 ++--- .../struct_vma_allocation_info2-members.html | 6 +-- docs/html/struct_vma_allocation_info2.html | 6 +-- docs/html/struct_vma_allocator.html | 6 +-- ...uct_vma_allocator_create_info-members.html | 6 +-- .../struct_vma_allocator_create_info.html | 10 ++--- .../struct_vma_allocator_info-members.html | 6 +-- docs/html/struct_vma_allocator_info.html | 6 +-- docs/html/struct_vma_budget-members.html | 6 +-- docs/html/struct_vma_budget.html | 8 ++-- .../struct_vma_defragmentation_context.html | 6 +-- ...ruct_vma_defragmentation_info-members.html | 6 +-- .../html/struct_vma_defragmentation_info.html | 6 +-- ...ruct_vma_defragmentation_move-members.html | 6 +-- .../html/struct_vma_defragmentation_move.html | 12 +++--- ...efragmentation_pass_move_info-members.html | 6 +-- ...ct_vma_defragmentation_pass_move_info.html | 12 +++--- ...uct_vma_defragmentation_stats-members.html | 6 +-- .../struct_vma_defragmentation_stats.html | 6 +-- ...truct_vma_detailed_statistics-members.html | 6 +-- docs/html/struct_vma_detailed_statistics.html | 6 +-- ...t_vma_device_memory_callbacks-members.html | 6 +-- .../struct_vma_device_memory_callbacks.html | 6 +-- docs/html/struct_vma_pool.html | 6 +-- .../struct_vma_pool_create_info-members.html | 6 +-- docs/html/struct_vma_pool_create_info.html | 6 +-- docs/html/struct_vma_statistics-members.html | 6 +-- docs/html/struct_vma_statistics.html | 10 ++--- .../struct_vma_total_statistics-members.html | 6 +-- docs/html/struct_vma_total_statistics.html | 6 +-- docs/html/struct_vma_virtual_allocation.html | 6 +-- ...irtual_allocation_create_info-members.html | 6 +-- ...ct_vma_virtual_allocation_create_info.html | 6 +-- ...t_vma_virtual_allocation_info-members.html | 6 +-- .../struct_vma_virtual_allocation_info.html | 6 +-- docs/html/struct_vma_virtual_block.html | 6 +-- ...vma_virtual_block_create_info-members.html | 6 +-- .../struct_vma_virtual_block_create_info.html | 6 +-- .../struct_vma_vulkan_functions-members.html | 6 +-- docs/html/struct_vma_vulkan_functions.html | 6 +-- docs/html/topics.html | 6 +-- docs/html/usage_patterns.html | 6 +-- docs/html/virtual_allocator.html | 6 +-- docs/html/vk__mem__alloc_8h.html | 6 +-- docs/html/vk_amd_device_coherent_memory.html | 6 +-- docs/html/vk_ext_memory_priority.html | 6 +-- docs/html/vk_khr_dedicated_allocation.html | 6 +-- include/vk_mem_alloc.h | 4 +- src/CMakeLists.txt | 2 +- src/Common.cpp | 2 +- src/Common.h | 2 +- src/Shaders/CMakeLists.txt | 2 +- src/Shaders/Shader.frag | 2 +- src/Shaders/Shader.vert | 2 +- src/Shaders/SparseBindingTest.comp | 2 +- src/SparseBindingTest.cpp | 2 +- src/SparseBindingTest.h | 2 +- src/Tests.cpp | 2 +- src/Tests.h | 2 +- src/VmaUsage.cpp | 2 +- src/VmaUsage.h | 2 +- src/VolkUsage.cpp | 2 +- src/VulkanSample.cpp | 2 +- tools/GpuMemDumpVis/GpuMemDumpVis.py | 2 +- 107 files changed, 344 insertions(+), 303 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3e21d9d4..aace46e6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,12 @@ +# 3.4.0 (2026-??-??) + +- Improvements for external memory export & import (#503): + - Added functions `vmaCreateDedicatedBuffer`, `vmaCreateDedicatedImage`, `vmaAllocateDedicatedMemory` offering extra parameter `void* pMemoryAllocateNext`. + - Added function `vmaGetMemoryWin32Handle2` offering extra parameter `VkExternalMemoryHandleTypeFlagBits handleType`. +- Added `VMA_VERSION` macro with library version number (#507). +- Fixes for compatibility with C++20 modules on Clang 21 and GCC15 (#513, #514). +- Other fixes and improvements, including compatibility with various platforms and compilers, improvements in documentation, sample application, and tests. + # 3.3.0 (2025-05-12) Additions to the library API: diff --git a/CMakeLists.txt b/CMakeLists.txt index c284c581..d879d484 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,5 +1,5 @@ # -# Copyright (c) 2017-2025 Advanced Micro Devices, Inc. All rights reserved. +# Copyright (c) 2017-2026 Advanced Micro Devices, Inc. All rights reserved. # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal diff --git a/LICENSE.txt b/LICENSE.txt index a080d9bf..be95175d 100644 --- a/LICENSE.txt +++ b/LICENSE.txt @@ -1,4 +1,4 @@ -Copyright (c) 2017-2025 Advanced Micro Devices, Inc. All rights reserved. +Copyright (c) 2017-2026 Advanced Micro Devices, Inc. All rights reserved. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/docs/html/allocation_annotation.html b/docs/html/allocation_annotation.html index 73454683..ce99f9dc 100644 --- a/docs/html/allocation_annotation.html +++ b/docs/html/allocation_annotation.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: Allocation names and user data @@ -31,7 +31,7 @@ - + @@ -120,7 +120,7 @@

diff --git a/docs/html/annotated.html b/docs/html/annotated.html index 4080b50a..5786c7b4 100644 --- a/docs/html/annotated.html +++ b/docs/html/annotated.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: Class List @@ -31,7 +31,7 @@ - + @@ -106,7 +106,7 @@ diff --git a/docs/html/choosing_memory_type.html b/docs/html/choosing_memory_type.html index 3e83c9b3..519959c0 100644 --- a/docs/html/choosing_memory_type.html +++ b/docs/html/choosing_memory_type.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: Choosing memory type @@ -31,7 +31,7 @@ - + @@ -125,7 +125,7 @@

VmaAllocationCreateFlags flags
Use VmaAllocationCreateFlagBits enum.
Definition vk_mem_alloc.h:1296

For more examples of creating different kinds of resources, see chapter Recommended usage patterns. See also: Memory mapping.

Usage values VMA_MEMORY_USAGE_AUTO* are legal to use only when the library knows about the resource being created by having VkBufferCreateInfo / VkImageCreateInfo passed, so they work with functions like: vmaCreateBuffer(), vmaCreateImage(), vmaFindMemoryTypeIndexForBufferInfo() etc. If you allocate raw memory using function vmaAllocateMemory(), you have to use other means of selecting memory type, as described below.

-
Note
Old usage values (VMA_MEMORY_USAGE_GPU_ONLY, VMA_MEMORY_USAGE_CPU_ONLY, VMA_MEMORY_USAGE_CPU_TO_GPU, VMA_MEMORY_USAGE_GPU_TO_CPU, VMA_MEMORY_USAGE_CPU_COPY) are still available and work same way as in previous versions of the library for backward compatibility, but they are deprecated.
+
Note
Old usage values (VMA_MEMORY_USAGE_GPU_ONLY, VMA_MEMORY_USAGE_CPU_ONLY, VMA_MEMORY_USAGE_CPU_TO_GPU, VMA_MEMORY_USAGE_GPU_TO_CPU, VMA_MEMORY_USAGE_CPU_COPY) are still available and work same way as in previous versions of the library for backward compatibility, but they are deprecated.

Required and preferred flags

You can specify more detailed requirements by filling members VmaAllocationCreateInfo::requiredFlags and VmaAllocationCreateInfo::preferredFlags with a combination of bits from enum VkMemoryPropertyFlags. For example, if you want to create a buffer that will be persistently mapped on host (so it must be HOST_VISIBLE) and preferably will also be HOST_COHERENT and HOST_CACHED, use following code:

@@ -178,7 +178,7 @@

diff --git a/docs/html/classes.html b/docs/html/classes.html index 82c10757..bc417b5c 100644 --- a/docs/html/classes.html +++ b/docs/html/classes.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: Class Index @@ -31,7 +31,7 @@ - + @@ -83,7 +83,7 @@ diff --git a/docs/html/configuration.html b/docs/html/configuration.html index 6b7baee5..0c6260d7 100644 --- a/docs/html/configuration.html +++ b/docs/html/configuration.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: Configuration @@ -31,7 +31,7 @@ - + @@ -109,7 +109,7 @@

diff --git a/docs/html/custom_memory_pools.html b/docs/html/custom_memory_pools.html index 90449392..bd068483 100644 --- a/docs/html/custom_memory_pools.html +++ b/docs/html/custom_memory_pools.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: Custom memory pools @@ -31,7 +31,7 @@ - + @@ -227,7 +227,7 @@

diff --git a/docs/html/debugging_memory_usage.html b/docs/html/debugging_memory_usage.html index aac63dff..4eec6564 100644 --- a/docs/html/debugging_memory_usage.html +++ b/docs/html/debugging_memory_usage.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: Debugging incorrect memory usage @@ -31,7 +31,7 @@ - + @@ -120,7 +120,7 @@

diff --git a/docs/html/defragmentation.html b/docs/html/defragmentation.html index dff4b8dd..e473e3a5 100644 --- a/docs/html/defragmentation.html +++ b/docs/html/defragmentation.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: Defragmentation @@ -31,7 +31,7 @@ - + @@ -204,7 +204,7 @@ diff --git a/docs/html/deprecated.html b/docs/html/deprecated.html index fdc6db35..118a27f5 100644 --- a/docs/html/deprecated.html +++ b/docs/html/deprecated.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: Deprecated List @@ -31,7 +31,7 @@ - + @@ -92,7 +92,7 @@ diff --git a/docs/html/dir_d44c64559bbebec7f509842c48db8b23.html b/docs/html/dir_d44c64559bbebec7f509842c48db8b23.html index cb11150f..5adabd29 100644 --- a/docs/html/dir_d44c64559bbebec7f509842c48db8b23.html +++ b/docs/html/dir_d44c64559bbebec7f509842c48db8b23.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: C:/Code/VulkanMemoryAllocator/REPO/include Directory Reference @@ -31,7 +31,7 @@ - + @@ -86,7 +86,7 @@ diff --git a/docs/html/doxygen.css b/docs/html/doxygen.css index 5d2eecd6..8c4d5835 100644 --- a/docs/html/doxygen.css +++ b/docs/html/doxygen.css @@ -1,4 +1,4 @@ -/* The standard CSS for doxygen 1.14.0*/ +/* The standard CSS for doxygen 1.15.0*/ html { /* page base colors */ @@ -158,6 +158,7 @@ html { --fragment-lineno-link-hover-fg-color: #4665A2; --fragment-lineno-link-hover-bg-color: #C8C8C8; --fragment-copy-ok-color: #2EC82E; +--fragment-highlight-filter: -3; --tooltip-foreground-color: black; --tooltip-background-color: rgba(255,255,255,0.8); --tooltip-arrow-background-color: white; @@ -360,6 +361,7 @@ html { --fragment-lineno-link-hover-fg-color: #8E96A1; --fragment-lineno-link-hover-bg-color: #505050; --fragment-copy-ok-color: #0EA80E; +--fragment-highlight-filter: 5; --tooltip-foreground-color: #C9D1D9; --tooltip-background-color: #202020; --tooltip-arrow-background-color: #202020; @@ -744,6 +746,7 @@ pre.fragment { span.tt { white-space: pre; font-family: var(--font-family-monospace); + background-color: var(--fragment-background-color); } .clipboard { @@ -1914,6 +1917,10 @@ dl.warning dt, dl.attention dt, dl.important dt { color: var(--warning-color-hl); } +dl.warning .tt, dl.attention .tt, dl.important .tt { + background-color: hsl(from var(--warning-color-bg) h s calc(l + var(--fragment-highlight-filter))); +} + dl.note, dl.remark { background: var(--note-color-bg); border-left: 8px solid var(--note-color-hl); @@ -1924,6 +1931,10 @@ dl.note dt, dl.remark dt { color: var(--note-color-hl); } +dl.note .tt, dl.remark .tt { + background-color: hsl(from var(--note-color-bg) h s calc(l + var(--fragment-highlight-filter))); +} + dl.todo { background: var(--todo-color-bg); border-left: 8px solid var(--todo-color-hl); @@ -1934,6 +1945,10 @@ dl.todo dt { color: var(--todo-color-hl); } +dl.todo .tt { + background-color: hsl(from var(--todo-color-bg) h s calc(l + var(--fragment-highlight-filter))); +} + dl.test { background: var(--test-color-bg); border-left: 8px solid var(--test-color-hl); @@ -1944,6 +1959,10 @@ dl.test dt { color: var(--test-color-hl); } +dl.test .tt { + background-color: hsl(from var(--test-color-bg) h s calc(l + var(--fragment-highlight-filter))); +} + dl.bug dt a { color: var(--bug-color-hl) !important; } @@ -1958,6 +1977,10 @@ dl.bug dt a { color: var(--bug-color-hl) !important; } +dl.bug .tt { + background-color: hsl(from var(--bug-color-bg) h s calc(l + var(--fragment-highlight-filter))); +} + dl.deprecated { background: var(--deprecated-color-bg); border-left: 8px solid var(--deprecated-color-hl); @@ -1968,12 +1991,11 @@ dl.deprecated dt a { color: var(--deprecated-color-hl) !important; } -dl.note dd, dl.warning dd, dl.pre dd, dl.post dd, -dl.remark dd, dl.attention dd, dl.important dd, dl.invariant dd, -dl.bug dd, dl.deprecated dd, dl.todo dd, dl.test dd { - margin-inline-start: 0px; +dl.deprecated .tt { + background-color: hsl(from var(--deprecated-color-bg) h s calc(l + var(--fragment-highlight-filter))); } + dl.invariant, dl.pre, dl.post { background: var(--invariant-color-bg); border-left: 8px solid var(--invariant-color-hl); @@ -1984,6 +2006,16 @@ dl.invariant dt, dl.pre dt, dl.post dt { color: var(--invariant-color-hl); } +dl.invariant .tt, dl.pre .tt, dl.post .tt { + background-color: hsl(from var(--invariant-color-bg) h s calc(l + var(--fragment-highlight-filter))); +} + +dl.note dd, dl.warning dd, dl.pre dd, dl.post dd, +dl.remark dd, dl.attention dd, dl.important dd, dl.invariant dd, +dl.bug dd, dl.deprecated dd, dl.todo dd, dl.test dd { + margin-inline-start: 0px; +} + #projectrow { diff --git a/docs/html/doxygen_crawl.html b/docs/html/doxygen_crawl.html index f4404e93..793b5a0f 100644 --- a/docs/html/doxygen_crawl.html +++ b/docs/html/doxygen_crawl.html @@ -4,7 +4,7 @@ Validator / crawler helper - + diff --git a/docs/html/enabling_buffer_device_address.html b/docs/html/enabling_buffer_device_address.html index 46613248..ae5448af 100644 --- a/docs/html/enabling_buffer_device_address.html +++ b/docs/html/enabling_buffer_device_address.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: Enabling buffer device address @@ -31,7 +31,7 @@ - + @@ -99,7 +99,7 @@

diff --git a/docs/html/faq.html b/docs/html/faq.html index 2ac0387a..a166154e 100644 --- a/docs/html/faq.html +++ b/docs/html/faq.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: Frequently asked questions @@ -31,7 +31,7 @@ - + @@ -103,7 +103,7 @@

VMA is an STB-style single-header C++ library.

You can pull the entire GitHub repository, e.g. using Git submodules. The repository contains ancillary files like the Cmake script, Doxygen config file, sample application, test suite, and others. You can compile it as a library and link with your project.

However, a simpler way is taking the single file "include/vk_mem_alloc.h" and including it in your project. This extensive file contains all you need: a copyright notice, declarations of the public library interface (API), its internal implementation, and even the documentation in form of Doxygen-style comments.

-

The "STB style" means not everything is implemented as inline functions in the header file. You need to extract the internal implementation using a special macro. This means that in every .cpp file where you need to use the library you should #include "vk_mem_alloc.h" to include its public interface, but additionally in exactly one .cpp file you should #define VMA_IMPLEMENTATION before this #include to enable its internal implementation. For more information, see Project setup.

+

The "STB style" means not everything is implemented as inline functions in the header file. You need to extract the internal implementation using a special macro. This means that in every .cpp file where you need to use the library you should #include "vk_mem_alloc.h" to include its public interface, but additionally in exactly one .cpp file you should #define VMA_IMPLEMENTATION before this #include to enable its internal implementation. For more information, see Project setup.

Does the library work with C or C++?

The internal implementation of VMA is written in C++. It is distributed in the source format, so you need a compiler supporting at least C++14 to build it.

However, the public interface of the library is written in C - using only enums, structs, and global functions, in the same style as Vulkan, so you can use the library in the C code.

@@ -155,7 +155,7 @@ diff --git a/docs/html/files.html b/docs/html/files.html index 59195e77..95679291 100644 --- a/docs/html/files.html +++ b/docs/html/files.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: File List @@ -31,7 +31,7 @@ - + @@ -83,7 +83,7 @@ diff --git a/docs/html/functions.html b/docs/html/functions.html index 641dbf75..d84ea601 100644 --- a/docs/html/functions.html +++ b/docs/html/functions.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: Class Members @@ -31,7 +31,7 @@ - + @@ -214,7 +214,7 @@

- v -