11/*
2- * Copyright 2019-2022 Diligent Graphics LLC
2+ * Copyright 2019-2025 Diligent Graphics LLC
33 * Copyright 2015-2019 Egor Yusov
44 *
55 * Licensed under the Apache License, Version 2.0 (the "License");
@@ -34,7 +34,7 @@ SRBMemoryAllocator::~SRBMemoryAllocator()
3434{
3535 if (m_DataAllocators != nullptr )
3636 {
37- auto TotalAllocatorCount = m_ShaderVariableDataAllocatorCount + m_ResourceCacheDataAllocatorCount;
37+ Uint32 TotalAllocatorCount = m_ShaderVariableDataAllocatorCount + m_ResourceCacheDataAllocatorCount;
3838 for (Uint32 s = 0 ; s < TotalAllocatorCount; ++s)
3939 {
4040 m_DataAllocators[s].~FixedBlockMemoryAllocator ();
@@ -54,20 +54,20 @@ void SRBMemoryAllocator::Initialize(Uint32 SRBAllocationGranularity
5454
5555 m_ShaderVariableDataAllocatorCount = ShaderVariableDataAllocatorCount;
5656 m_ResourceCacheDataAllocatorCount = ResourceCacheDataAllocatorCount;
57- auto TotalAllocatorCount = m_ShaderVariableDataAllocatorCount + m_ResourceCacheDataAllocatorCount;
57+ Uint32 TotalAllocatorCount = m_ShaderVariableDataAllocatorCount + m_ResourceCacheDataAllocatorCount;
5858
5959 if (TotalAllocatorCount == 0 )
6060 return ;
6161
62- auto * pAllocatorsRawMem = m_RawMemAllocator.Allocate (
62+ void * pAllocatorsRawMem = m_RawMemAllocator.Allocate (
6363 sizeof (FixedBlockMemoryAllocator) * TotalAllocatorCount,
6464 " Raw memory for SRBMemoryAllocator::m_ShaderVariableDataAllocators" ,
6565 __FILE__, __LINE__);
6666 m_DataAllocators = reinterpret_cast <FixedBlockMemoryAllocator*>(pAllocatorsRawMem);
6767
6868 for (Uint32 s = 0 ; s < TotalAllocatorCount; ++s)
6969 {
70- auto size = s < ShaderVariableDataAllocatorCount ? ShaderVariableDataSizes[s] : ResourceCacheDataSizes[s - ShaderVariableDataAllocatorCount];
70+ size_t size = s < ShaderVariableDataAllocatorCount ? ShaderVariableDataSizes[s] : ResourceCacheDataSizes[s - ShaderVariableDataAllocatorCount];
7171 new (m_DataAllocators + s) FixedBlockMemoryAllocator (GetRawAllocator (), size, SRBAllocationGranularity);
7272 }
7373}
0 commit comments