summaryrefslogtreecommitdiff
path: root/memory.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'memory.cpp')
-rw-r--r--memory.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/memory.cpp b/memory.cpp
index 30574e9..901fbab 100644
--- a/memory.cpp
+++ b/memory.cpp
@@ -124,6 +124,7 @@ Memory_Block_PrincipalBitmap_AllocateNew(project_data *File, project_state *Stat
uint32 Blocks_Max = Memory->Slot[B_CachedBitmaps].Size / BitmapBlockSize;
Assert(Blocks_Max > (LastBlock + BlockSize));
+
return LastBlock + BlockSize;
}
@@ -260,6 +261,15 @@ void Memory_Copy(uint8 *Address_Write, uint8 *Address_Read, uint64 Size)
}
}
+void Memory_Fill(uint8 *Address_Write, uint8 *Address_Read, uint64 WriteSize, uint64 ReadSize)
+{
+ uint64 i = 0;
+ while (i < WriteSize) {
+ *(Address_Write + i) = *(Address_Read + (i % ReadSize));
+ i++;
+ }
+}
+
void Arbitrary_Zero(uint8 *Address_Write, uint64 Size)
{
uint64 i = 0;