class Memory

Entity allocated relative to an Mmap More...

Definition#include <qvmm.h>
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

Public Members

Protected Members


Detailed Description

Entity allocated relative to an Mmap

Memory instances are the basic currency of ColdStore, providing interfaces to the store's features

void lock (void)

lock this object

void unlock (void)

unlock this object

void inc ( size_t& val)
[static]

Atomic counter increment

int dec ( size_t& val)
[static]

Atomic counter decrement

void* operator new ( size_t size, void* where=(void*)

C++ extent placement new @arg size size of allocation in bytes @arg where neighborhood into which to allocate

Returns: storage allocated as requested

void* operator new ( size_t size, size_t extra, void* where=(void*)

C++ extent additional placement new @arg size size of allocation in bytes @arg extra extra allocation in bytes @arg where neighborhood into which to allocate

Returns: storage allocated as requested

void operator delete ( void* ptr)

C++ object deletion @arg ptr a pointer returned by operator new() @arg extra extra allocation in bytes @arg where neighborhood into which to allocate

Returns: storage allocated as requested

void* operator new[] (size_t size, void* where=(void*)

C++ extent placement array new @arg size size of allocation in bytes @arg where neighborhood into which to allocate

void operator delete[] ( void* ptr)

C++ array object deletion @arg ptr a pointer returned by operator new[]() @arg extra extra allocation in bytes @arg where neighborhood into which to allocate

void* realloc ( void* addr, size_t size, void* allocator=(void*)
[static]

C storage reallocation @arg addr a pointer to previously alloc'd storage @arg size size of new allocation in bytes @arg allocator neighborhood into which to allocate

Returns: storage allocated as requested

void* alloc ( size_t size, void* allocator)
[static]

C storage allocation @arg size size of new allocation in bytes @arg allocator neighborhood into which to allocate

Returns: storage allocated as requested

void free ( void* ptr)
[static]

C storage deletion @arg ptr a pointer returned by alloc()

size_t size (const void* ptr)
[static]

external size of allocation @arg ptr a pointer returned by alloc()

Returns: size occupied by the allocation of ptr

size_t itsSize (const void* ptr)
[const]

internal size of some allocation

size_t mySize ()
[const]

internal size of allocation surrounding this

void* allocator ( void* ptr)
[static]

allocator of given region @arg ptr a pointer to allocated storage

Returns: the neighborhood with which ptr is associated

void * myAllocator ()

allocator of instance

Returns: the neighborhood with which this is associated

int check (void)
[static]

predicate: BTree is healthy

void Assert ( void)
[static]

Assert health of BTree

void * checkGuard (void *ptr, bool damage=false)
[static]

Check Guards' health

void * guard (void *ptr, void *alloc, size_t size)
[protected static]

construct a pair of Guards around the allocation to detect overwriting and double-deletion.

void validGuard ()
[protected const]

Non-destructively Validate Guards of this Memory instance