mirror of
https://github.com/GPUOpen-LibrariesAndSDKs/VulkanMemoryAllocator
synced 2024-11-05 04:10:06 +00:00
Improvements in documentation
This commit is contained in:
parent
4e4e1c085d
commit
e5c03604c9
@ -73,9 +73,10 @@ $(function() {
|
||||
Thread safety</h1>
|
||||
<ul>
|
||||
<li>The library has no global state, so separate <a class="el" href="struct_vma_allocator.html" title="Represents main object of this library initialized.">VmaAllocator</a> objects can be used independently. There should be no need to create multiple such objects though - one per <code>VkDevice</code> is enough.</li>
|
||||
<li>By default, all calls to functions that take <a class="el" href="struct_vma_allocator.html" title="Represents main object of this library initialized.">VmaAllocator</a> as first parameter are safe to call from multiple threads simultaneously because they are synchronized internally when needed.</li>
|
||||
<li>By default, all calls to functions that take <a class="el" href="struct_vma_allocator.html" title="Represents main object of this library initialized.">VmaAllocator</a> as first parameter are safe to call from multiple threads simultaneously because they are synchronized internally when needed. This includes allocation and deallocation from default memory pool, as well as custom <a class="el" href="struct_vma_pool.html" title="Represents custom memory pool.">VmaPool</a>.</li>
|
||||
<li>When the allocator is created with <a class="el" href="vk__mem__alloc_8h.html#a4f87c9100d154a65a4ad495f7763cf7ca4816ddaed324ba110172ca608a20f29d" title="Allocator and all objects created from it will not be synchronized internally, so you must guarantee ...">VMA_ALLOCATOR_CREATE_EXTERNALLY_SYNCHRONIZED_BIT</a> flag, calls to functions that take such <a class="el" href="struct_vma_allocator.html" title="Represents main object of this library initialized.">VmaAllocator</a> object must be synchronized externally.</li>
|
||||
<li>Access to a <a class="el" href="struct_vma_allocation.html" title="Represents single memory allocation.">VmaAllocation</a> object must be externally synchronized. For example, you must not call <a class="el" href="vk__mem__alloc_8h.html#a86dd08aba8633bfa4ad0df2e76481d8b" title="Returns current information about specified allocation and atomically marks it as used in current fra...">vmaGetAllocationInfo()</a> and <a class="el" href="vk__mem__alloc_8h.html#ad5bd1243512d099706de88168992f069" title="Maps memory represented by given allocation and returns pointer to it.">vmaMapMemory()</a> from different threads at the same time if you pass the same <a class="el" href="struct_vma_allocation.html" title="Represents single memory allocation.">VmaAllocation</a> object to these functions.</li>
|
||||
<li><a class="el" href="struct_vma_virtual_block.html" title="Handle to a virtual block object that allows to use core allocation algorithm without allocating any ...">VmaVirtualBlock</a> is also not safe to be used from multiple threads simultaneously.</li>
|
||||
</ul>
|
||||
<h1><a class="anchor" id="general_considerations_validation_layer_warnings"></a>
|
||||
Validation layer warnings</h1>
|
||||
|
@ -65,7 +65,7 @@ $(function() {
|
||||
<div class="headertitle"><div class="title">Vulkan Memory Allocator </div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<div class="textblock"><p ><b>Version 3.0.0-development</b> (2021-06-21)</p>
|
||||
<div class="textblock"><p ><b>Version 3.0.0-development</b></p>
|
||||
<p >Copyright (c) 2017-2021 Advanced Micro Devices, Inc. All rights reserved. <br />
|
||||
License: MIT</p>
|
||||
<p >Documentation of all members: <a class="el" href="vk__mem__alloc_8h.html">vk_mem_alloc.h</a></p>
|
||||
|
@ -72,7 +72,8 @@ $(function() {
|
||||
<p><code>#include <vk_mem_alloc.h></code></p>
|
||||
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
||||
<div class="textblock"><p >Handle to a virtual block object that allows to use core allocation algorithm without allocating any real GPU memory. </p>
|
||||
<p >Fill in <a class="el" href="struct_vma_virtual_block_create_info.html" title="Parameters of created VmaVirtualBlock object to be passed to vmaCreateVirtualBlock().">VmaVirtualBlockCreateInfo</a> structure and Use <a class="el" href="vk__mem__alloc_8h.html#ab585754076877265fdae33e5c40ef13b" title="Creates new VmaVirtualBlock object.">vmaCreateVirtualBlock()</a> to create it. Use <a class="el" href="vk__mem__alloc_8h.html#a3795f7783ae2c182cede067d656f66a5" title="Destroys VmaVirtualBlock object.">vmaDestroyVirtualBlock()</a> to destroy it. For more information, see documentation chapter <a class="el" href="virtual_allocator.html">Virtual allocator</a>. </p>
|
||||
<p >Fill in <a class="el" href="struct_vma_virtual_block_create_info.html" title="Parameters of created VmaVirtualBlock object to be passed to vmaCreateVirtualBlock().">VmaVirtualBlockCreateInfo</a> structure and use <a class="el" href="vk__mem__alloc_8h.html#ab585754076877265fdae33e5c40ef13b" title="Creates new VmaVirtualBlock object.">vmaCreateVirtualBlock()</a> to create it. Use <a class="el" href="vk__mem__alloc_8h.html#a3795f7783ae2c182cede067d656f66a5" title="Destroys VmaVirtualBlock object.">vmaDestroyVirtualBlock()</a> to destroy it. For more information, see documentation chapter <a class="el" href="virtual_allocator.html">Virtual allocator</a>.</p>
|
||||
<p >This object is not thread-safe - should not be used from multiple threads simultaneously, must be synchronized externally. </p>
|
||||
</div><hr/>The documentation for this struct was generated from the following file:<ul>
|
||||
<li>D:/PROJECTS/Vulkan Memory Allocator/REPO/include/<a class="el" href="vk__mem__alloc_8h.html">vk_mem_alloc.h</a></li>
|
||||
</ul>
|
||||
|
@ -25,7 +25,7 @@
|
||||
|
||||
/** \mainpage Vulkan Memory Allocator
|
||||
|
||||
<b>Version 3.0.0-development</b> (2021-06-21)
|
||||
<b>Version 3.0.0-development</b>
|
||||
|
||||
Copyright (c) 2017-2021 Advanced Micro Devices, Inc. All rights reserved. \n
|
||||
License: MIT
|
||||
@ -2297,8 +2297,10 @@ typedef struct VmaVirtualAllocationInfo
|
||||
/** \struct VmaVirtualBlock
|
||||
\brief Handle to a virtual block object that allows to use core allocation algorithm without allocating any real GPU memory.
|
||||
|
||||
Fill in #VmaVirtualBlockCreateInfo structure and Use vmaCreateVirtualBlock() to create it. Use vmaDestroyVirtualBlock() to destroy it.
|
||||
Fill in #VmaVirtualBlockCreateInfo structure and use vmaCreateVirtualBlock() to create it. Use vmaDestroyVirtualBlock() to destroy it.
|
||||
For more information, see documentation chapter \ref virtual_allocator.
|
||||
|
||||
This object is not thread-safe - should not be used from multiple threads simultaneously, must be synchronized externally.
|
||||
*/
|
||||
VK_DEFINE_HANDLE(VmaVirtualBlock);
|
||||
|
||||
@ -20620,6 +20622,7 @@ accompanying this library.
|
||||
- By default, all calls to functions that take #VmaAllocator as first parameter
|
||||
are safe to call from multiple threads simultaneously because they are
|
||||
synchronized internally when needed.
|
||||
This includes allocation and deallocation from default memory pool, as well as custom #VmaPool.
|
||||
- When the allocator is created with #VMA_ALLOCATOR_CREATE_EXTERNALLY_SYNCHRONIZED_BIT
|
||||
flag, calls to functions that take such #VmaAllocator object must be
|
||||
synchronized externally.
|
||||
@ -20627,6 +20630,7 @@ accompanying this library.
|
||||
you must not call vmaGetAllocationInfo() and vmaMapMemory() from different
|
||||
threads at the same time if you pass the same #VmaAllocation object to these
|
||||
functions.
|
||||
- #VmaVirtualBlock is also not safe to be used from multiple threads simultaneously.
|
||||
|
||||
\section general_considerations_validation_layer_warnings Validation layer warnings
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user