document experimental options
This commit is contained in:
parent
ae1794a852
commit
08e0f14c2a
@ -218,17 +218,19 @@ mi_decl_export bool mi_heap_visit_blocks(const mi_heap_t* heap, bool visit_all_b
|
|||||||
// ------------------------------------------------------
|
// ------------------------------------------------------
|
||||||
|
|
||||||
typedef enum mi_option_e {
|
typedef enum mi_option_e {
|
||||||
|
// stable options
|
||||||
|
mi_option_show_stats,
|
||||||
|
mi_option_show_errors,
|
||||||
|
mi_option_verbose,
|
||||||
|
// the following options are experimental
|
||||||
mi_option_page_reset,
|
mi_option_page_reset,
|
||||||
mi_option_cache_reset,
|
mi_option_cache_reset,
|
||||||
mi_option_eager_commit,
|
mi_option_eager_commit,
|
||||||
mi_option_eager_region_commit,
|
mi_option_eager_region_commit,
|
||||||
mi_option_large_os_pages, // implies eager commit
|
mi_option_large_os_pages, // implies eager commit
|
||||||
mi_option_reset_decommits,
|
mi_option_reset_decommits,
|
||||||
mi_option_reset_discards,
|
mi_option_reset_discards,
|
||||||
mi_option_secure,
|
mi_option_secure,
|
||||||
mi_option_show_stats,
|
|
||||||
mi_option_show_errors,
|
|
||||||
mi_option_verbose,
|
|
||||||
_mi_option_last
|
_mi_option_last
|
||||||
} mi_option_t;
|
} mi_option_t;
|
||||||
|
|
||||||
|
@ -31,22 +31,26 @@ typedef struct mi_option_desc_s {
|
|||||||
const char* name; // option name without `mimalloc_` prefix
|
const char* name; // option name without `mimalloc_` prefix
|
||||||
} mi_option_desc_t;
|
} mi_option_desc_t;
|
||||||
|
|
||||||
static mi_option_desc_t options[_mi_option_last] = {
|
static mi_option_desc_t options[_mi_option_last] =
|
||||||
|
{
|
||||||
|
// stable options
|
||||||
|
{ 0, UNINIT, "show_stats" },
|
||||||
|
{ MI_DEBUG, UNINIT, "show_errors" },
|
||||||
|
{ 0, UNINIT, "verbose" },
|
||||||
|
|
||||||
|
// the following options are experimental and not all combinations make sense.
|
||||||
{ 0, UNINIT, "page_reset" },
|
{ 0, UNINIT, "page_reset" },
|
||||||
{ 0, UNINIT, "cache_reset" },
|
{ 0, UNINIT, "cache_reset" },
|
||||||
{ 1, UNINIT, "eager_commit" },
|
{ 1, UNINIT, "eager_commit" },
|
||||||
{ 1, UNINIT, "eager_region_commit" },
|
{ 1, UNINIT, "eager_region_commit" }, // eager_commit should be on when eager_region_commit is on
|
||||||
{ 0, UNINIT, "large_os_pages" }, // use large OS pages, use only with eager commit to prevent fragmentation of VMA's
|
{ 0, UNINIT, "large_os_pages" }, // use large OS pages, use only with eager commit to prevent fragmentation of VMA's
|
||||||
{ 0, UNINIT, "reset_decommits" },
|
{ 0, UNINIT, "reset_decommits" },
|
||||||
{ 0, UNINIT, "reset_discards" },
|
{ 0, UNINIT, "reset_discards" },
|
||||||
#if MI_SECURE
|
#if MI_SECURE
|
||||||
{ MI_SECURE, INITIALIZED, "secure" }, // in secure build the environment setting is ignored
|
{ MI_SECURE, INITIALIZED, "secure" } // in a secure build the environment setting is ignored
|
||||||
#else
|
#else
|
||||||
{ 0, UNINIT, "secure" },
|
{ 0, UNINIT, "secure" }
|
||||||
#endif
|
#endif
|
||||||
{ 0, UNINIT, "show_stats" },
|
|
||||||
{ MI_DEBUG, UNINIT, "show_errors" },
|
|
||||||
{ 0, UNINIT, "verbose" }
|
|
||||||
};
|
};
|
||||||
|
|
||||||
static void mi_option_init(mi_option_desc_t* desc);
|
static void mi_option_init(mi_option_desc_t* desc);
|
||||||
|
Loading…
Reference in New Issue
Block a user