#include "memory.hh"
Public Types | |
using | HugePageP = std::shared_ptr< HugePage > |
Public Member Functions | |
size_t | alignment () const |
char * | mem () const |
size_t | size () const |
Static Public Member Functions | |
static HugePageP | allocate (size_t minimum_alignment, size_t bytelength) |
Protected Member Functions | |
HugePage (void *m, size_t s) | |
virtual | ~HugePage () |
Protected Attributes | |
const size_t | size_ |
void *const | start_ |
Interface to the OS huge page allocator.
|
explicitprotected |
|
protectedvirtual |
size_t alignment | ( | ) | const |
Alignment of the memory area.
size_t size | ( | ) | const |
Size in bytes of the memroy area.
char * mem | ( | ) | const |
Allocated memroy area.
|
static |
Try to allocate a HugePage `>= bytelength` with `minimum_alignment`, usual sizes are 2MB.
|
protected |
|
protected |