From ee92a03f59e2b61fe655ffcc739297c0e8f916c6 Mon Sep 17 00:00:00 2001 From: Adam Sawicki Date: Wed, 18 Oct 2017 15:35:00 +0200 Subject: [PATCH] VmaAllocator_T::AllocateMemoryOfType: Fixed major bug when VMA_ALLOCATION_CREATE_PERSISTENT_MAP_BIT is used with VMA_MEMORY_USAGE_GPU_ONLY. --- bin/VulkanSample_Release_2015.exe | Bin 100864 -> 100864 bytes src/vk_mem_alloc.h | 20 ++++++++++---------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/bin/VulkanSample_Release_2015.exe b/bin/VulkanSample_Release_2015.exe index d216b3d96e3476bcf026e41ffda91cac06d8e932..e3da0c0e891ee68a32cf761001f14f67d442a71a 100644 GIT binary patch delta 20553 zcmZ`>30zdw_kVX}Sj2HacmgT{IxLD1iYSOEDCk2`amzi?$SgN1a7k@YBpqK<>eWUq zjW)B=TyS3sLx*?z#89HI@o#n- zd@og3;8$a?7_~bCy5lr>y*i+eYxK|FscyiGTKz`eS_6hx>%S)St%h_6Ze$aIL$T^P z*RN(5i`%*GW#QKE(0H}4yJ8(=3Rdc!$WY7dO+65xI?I%$s2QdhCHAP@k2iLo5&p-w z|6g~edmY_)(w)Y)xsPBIcq5M}mc)}i+AuFZ$s?RC;LAK-VQ+DVhlvg2rurtBKXQh0P zXDqYwD$mX=lSegZ$=dM#4PIlrcv*u`UHhZ_Tce3LH2AO)yoDi(Me$5SqVBJq+-hi} zE8EHY8+`b2Lj-%9-#0|*hH8w2h7qhOAKNgB{lOPCOkx}Oao}@+%iP--%i?*OF^bja zZy3YauY9Gk1vY!gCn??e{E`*=q& z9iQnPrn|V6e_#w@L-_&k1nL;?C|%}Oq1mlb1Z%`6G>X#wwnZ?$0b>n63&wPf(Zr{a zt>;BPv)O3g+&7lp5>0B>Iv0gk@?#v842ly|1wVcF0=9hrK z!Rt3pWzoD}<0vNa*^N81GQJD=GH!1i#wK&4U#QMr%8&U5@_~Nsb^mPO7QbNK8^kg3 z6MjByC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1tIvV*9@b)@M+6}xK@QwA7^bk0u*0z@?p%bPM_B7C8d+M`GEBq*6bjP@>5?gvNkRa0kjm;5z}kAhYD? zFrC#;DU@!Wpag(V(0BxjzzL2)F$2#4^eD%=6L-_Yr_A zj;nYf;9(T%#j4}@)M)hy)wl@o9EuPC#-36Q5&$))Ron=;6oqsO0au)H;((S)Cl0vc z8z&C9;;a(~T!Bm|Y-=-O4il;JWu(ADw18j%%4Xn{7Eht<23`p`6xoc7Dcwyuj~op? zwsBG^iWuR54UpDIr+$i~RCfa5bA}DAL*pI3m~$Wd`v2>5kG~{53QHe1a(`g~01)JIZ=}?0Dk9 zC-|Hl_kTBt3=qrI+M*3?GmkDSk z;J~}8EhWK%dl<0b7XoVj#I2&o8}N6OLh!5q#PdJ#FIA8U*ynFmkPeu1AKe6{bighT z@Mr-~05m;R@d!ZgM=Blw=<-;_jevhSap?(WR}`w4a_SA_(F&>15zKsJ17aj z3I2;R1h|Aham~ra&m<5#0q>#Epa{U<>kdV(oB@9Q97?&g3}rd^1ka-s0j~nAMDpAT zoRaBeB+v@rQvq>cB7(zFj5G_0lLE~I%tb-3Lds@Y>Igr6H6n&VNQGm;BpkIjNn)wCOxH~0r9bq5l7JC;9CD7tFElopVKPfODiC|!V8 z0e14olK~tjZ_-4R5a4tYL#Hsbv!hJ|Z5RlrRU@q|3o&>Jz7zl+a4ev5#L9@2XoW-z zAi@dKVux^otx<~5VuEQ-emdX=6biHm@DC?m4H(}>SOk50S_(4(!;VI{4X Pu%Fq=h=yC1GS~kHwt=nR diff --git a/src/vk_mem_alloc.h b/src/vk_mem_alloc.h index 4cc87ca..92265d9 100644 --- a/src/vk_mem_alloc.h +++ b/src/vk_mem_alloc.h @@ -6496,12 +6496,19 @@ VkResult VmaAllocator_T::AllocateMemoryOfType( VMA_ASSERT(pAllocation != VMA_NULL); VMA_DEBUG_LOG(" AllocateMemory: MemoryTypeIndex=%u, Size=%llu", memTypeIndex, vkMemReq.size); - uint32_t blockVectorType = VmaAllocationCreateFlagsToBlockVectorType(createInfo.flags); + VmaAllocationCreateInfo finalCreateInfo = createInfo; + + // If memory type is not HOST_VISIBLE, disable PERSISTENT_MAP. + if((finalCreateInfo.flags & VMA_ALLOCATION_CREATE_PERSISTENT_MAP_BIT) != 0 && + (m_MemProps.memoryTypes[memTypeIndex].propertyFlags & VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT) == 0) + { + finalCreateInfo.flags &= ~VMA_ALLOCATION_CREATE_PERSISTENT_MAP_BIT; + } + + uint32_t blockVectorType = VmaAllocationCreateFlagsToBlockVectorType(finalCreateInfo.flags); VmaBlockVector* const blockVector = m_pBlockVectors[memTypeIndex][blockVectorType]; VMA_ASSERT(blockVector); - VmaAllocationCreateInfo finalCreateInfo = createInfo; - const VkDeviceSize preferredBlockSize = blockVector->GetPreferredBlockSize(); bool preferDedicatedMemory = VMA_DEBUG_ALWAYS_DEDICATED_MEMORY || @@ -6516,13 +6523,6 @@ VkResult VmaAllocator_T::AllocateMemoryOfType( finalCreateInfo.flags |= VMA_ALLOCATION_CREATE_DEDICATED_MEMORY_BIT; } - // If memory type is not HOST_VISIBLE, disable PERSISTENT_MAP. - if((finalCreateInfo.flags & VMA_ALLOCATION_CREATE_PERSISTENT_MAP_BIT) != 0 && - (m_MemProps.memoryTypes[memTypeIndex].propertyFlags & VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT) == 0) - { - finalCreateInfo.flags &= ~VMA_ALLOCATION_CREATE_PERSISTENT_MAP_BIT; - } - if((finalCreateInfo.flags & VMA_ALLOCATION_CREATE_DEDICATED_MEMORY_BIT) != 0) { if((finalCreateInfo.flags & VMA_ALLOCATION_CREATE_NEVER_ALLOCATE_BIT) != 0)