Fix compilation warnings

This commit is contained in:
Wojtek Figat
2025-06-05 18:32:36 +02:00
parent f462a2187f
commit 0670c0bbd3
2 changed files with 5 additions and 5 deletions

View File

@@ -11,7 +11,7 @@ void ArenaAllocator::Free()
while (page)
{
#if COMPILE_WITH_PROFILER
ProfilerMemory::OnGroupUpdate(ProfilerMemory::Groups::MallocArena, -page->Size, -1);
ProfilerMemory::OnGroupUpdate(ProfilerMemory::Groups::MallocArena, -(int64)page->Size, -1);
#endif
Allocator::Free(page->Memory);
Page* next = page->Next;
@@ -35,7 +35,7 @@ void* ArenaAllocator::Allocate(uint64 size, uint64 alignment)
{
uint64 pageSize = Math::Max<uint64>(_pageSize, size);
#if COMPILE_WITH_PROFILER
ProfilerMemory::OnGroupUpdate(ProfilerMemory::Groups::MallocArena, pageSize, 1);
ProfilerMemory::OnGroupUpdate(ProfilerMemory::Groups::MallocArena, (int64)pageSize, 1);
#endif
page = (Page*)Allocator::Allocate(sizeof(Page));
page->Memory = Allocator::Allocate(pageSize);
@@ -51,4 +51,4 @@ void* ArenaAllocator::Allocate(uint64 size, uint64 alignment)
page->Offset += (uint32)size;
return mem;
}
}