Nebula
Loading...
Searching...
No Matches
osxmemory.cc File Reference
#include "stdneb.h"
#include "core/types.h"
#include "core/sysfunc.h"

Namespaces

namespace  Memory
 

Functions

void * operator new (size_t size)
 Replacement global new/delete operators.
 
void * operator new (size_t size, size_t align)
 
void * operator new[] (size_t size)
 
void * operator new[] (size_t size, size_t align)
 
void operator delete (void *p)
 
void operator delete[] (void *p)
 
void * Memory::Alloc (HeapType heapType, size_t size, size_t alignment)
 Allocate a block of memory from one of the global heaps.
 
void * Memory::Realloc (HeapType heapType, void *ptr, size_t size)
 Re-Allocate a block of memory from one of the global heaps.
 
void Memory::Free (HeapType heapType, void *ptr)
 Free a block of memory.
 
char * Memory::DuplicateCString (const char *from)
 Duplicate a 0-terminated string, this method should no longer be used!
 
bool Memory::IsOverlapping (const unsigned char *srcPtr, size_t srcSize, const unsigned char *dstPtr, size_t dstSize)
 Test if 2 areas of memory areas are overlapping.
 
TotalMemoryStatus Memory::GetTotalMemoryStatus ()
 Get the system's total memory status.
 
void Memory::Copy (const void *from, void *to, size_t numBytes)
 Copy a chunk of memory (note the argument order is different from memcpy()!!!)
 
void Memory::Clear (void *ptr, size_t numBytes)
 Overwrite a chunk of memory with 0's.
 
void Memory::Fill (void *ptr, size_t numBytes, unsigned char value)
 Fill memory with a specific byte.
 

Function Documentation

◆ operator delete()

void operator delete ( void * p)

◆ operator delete[]()

void operator delete[] ( void * p)

◆ operator new() [1/2]

void * operator new ( size_t size)

Replacement global new/delete operators.

◆ operator new() [2/2]

void * operator new ( size_t size,
size_t align )

◆ operator new[]() [1/2]

void * operator new[] ( size_t size)

◆ operator new[]() [2/2]

void * operator new[] ( size_t size,
size_t align )