AAL: add AalName and smallest_page_size

This commit is contained in:
Nathaniel Filardo
2020-05-13 13:58:12 +00:00
parent 3d3b048776
commit b2ee1902dc
4 changed files with 19 additions and 0 deletions

View File

@@ -44,6 +44,13 @@ namespace snmalloc
StrictProvenance = (1 << 2),
};
enum AalName : int
{
ARM,
X86,
X86_SGX,
};
/**
* Architecture Abstraction Layer. Includes default implementations of some
* functions using compiler builtins. Falls back to the definitions in the

View File

@@ -27,6 +27,10 @@ namespace snmalloc
static constexpr uint64_t aal_features =
IntegerPointers | NoCpuCycleCounters;
static constexpr enum AalName aal_name = ARM;
static constexpr size_t smallest_page_size = 0x1000;
/**
* On pipelined processors, notify the core that we are in a spin loop and
* that speculative execution past this point may not be a performance gain.

View File

@@ -60,6 +60,10 @@ namespace snmalloc
*/
static constexpr uint64_t aal_features = IntegerPointers;
static constexpr enum AalName aal_name = X86;
static constexpr size_t smallest_page_size = 0x1000;
/**
* On pipelined processors, notify the core that we are in a spin loop and
* that speculative execution past this point may not be a performance gain.

View File

@@ -26,6 +26,10 @@ namespace snmalloc
*/
static constexpr uint64_t aal_features = IntegerPointers;
static constexpr enum AalName aal_name = X86_SGX;
static constexpr size_t smallest_page_size = 0x1000;
/**
* On pipelined processors, notify the core that we are in a spin loop and
* that speculative execution past this point may not be a performance gain.