| 3157 | } |
| 3158 | |
| 3159 | void BlockMetadata_Generic::Init(UINT64 size) |
| 3160 | { |
| 3161 | BlockMetadata::Init(size); |
| 3162 | m_ZeroInitializedRange.Reset(size); |
| 3163 | |
| 3164 | m_FreeCount = 1; |
| 3165 | m_SumFreeSize = size; |
| 3166 | |
| 3167 | Suballocation suballoc = {}; |
| 3168 | suballoc.offset = 0; |
| 3169 | suballoc.size = size; |
| 3170 | suballoc.type = SUBALLOCATION_TYPE_FREE; |
| 3171 | suballoc.privateData = NULL; |
| 3172 | |
| 3173 | D3D12MA_ASSERT(size > MIN_FREE_SUBALLOCATION_SIZE_TO_REGISTER); |
| 3174 | m_Suballocations.push_back(suballoc); |
| 3175 | SuballocationList::iterator suballocItem = m_Suballocations.end(); |
| 3176 | --suballocItem; |
| 3177 | m_FreeSuballocationsBySize.push_back(suballocItem); |
| 3178 | } |
| 3179 | |
| 3180 | bool BlockMetadata_Generic::Validate() const |
| 3181 | { |
no test coverage detected