mirror of
https://github.com/microsoft/mimalloc.git
synced 2024-12-25 20:14:12 +08:00
update documentation
This commit is contained in:
parent
24777f6a91
commit
c977a1629d
@ -48,20 +48,23 @@ Notable aspects of the design include:
|
||||
- __first-class heaps__: efficiently create and use multiple heaps to allocate across different regions.
|
||||
A heap can be destroyed at once instead of deallocating each object separately.
|
||||
- __bounded__: it does not suffer from _blowup_ \[1\], has bounded worst-case allocation
|
||||
times (_wcat_), bounded space overhead (~0.2% meta-data, with at most 16.7% waste in allocation sizes),
|
||||
times (_wcat_), bounded space overhead (~0.2% meta-data, with at most 12.5% waste in allocation sizes),
|
||||
and has no internal points of contention using only atomic operations.
|
||||
- __fast__: In our benchmarks (see [below](#performance)),
|
||||
_mimalloc_ always outperforms all other leading allocators (_jemalloc_, _tcmalloc_, _Hoard_, etc),
|
||||
and usually uses less memory (up to 25% more in the worst case). A nice property
|
||||
is that it does consistently well over a wide range of benchmarks.
|
||||
|
||||
You can read more on the design of _mimalloc_ in the upcoming technical report
|
||||
You can read more on the design of _mimalloc_ in the
|
||||
[technical report](https://www.microsoft.com/en-us/research/publication/mimalloc-free-list-sharding-in-action)
|
||||
which also has detailed benchmark results.
|
||||
|
||||
|
||||
Further information:
|
||||
|
||||
- \ref build
|
||||
- \ref using
|
||||
- \ref environment
|
||||
- \ref overrides
|
||||
- \ref bench
|
||||
- \ref malloc
|
||||
@ -293,31 +296,34 @@ size_t mi_good_size(size_t size);
|
||||
/// resource usage by calling this every once in a while.
|
||||
void mi_collect(bool force);
|
||||
|
||||
/// Print statistics.
|
||||
/// @param out Output file. Use \a NULL for \a stderr.
|
||||
/// Print the main statistics.
|
||||
/// @param out Output function. Use \a NULL for outputting to \a stderr.
|
||||
///
|
||||
/// Most detailed when using a debug build.
|
||||
void mi_stats_print(FILE* out);
|
||||
void mi_stats_print(mi_output_fun* out);
|
||||
|
||||
/// Reset statistics.
|
||||
void mi_stats_reset();
|
||||
void mi_stats_reset(void);
|
||||
|
||||
/// Merge thread local statistics with the main statistics and reset.
|
||||
void mi_stats_merge(void);
|
||||
|
||||
/// Initialize mimalloc on a thread.
|
||||
/// Should not be used as on most systems (pthreads, windows) this is done
|
||||
/// automatically.
|
||||
void mi_thread_init();
|
||||
void mi_thread_init(void);
|
||||
|
||||
/// Uninitialize mimalloc on a thread.
|
||||
/// Should not be used as on most systems (pthreads, windows) this is done
|
||||
/// automatically. Ensures that any memory that is not freed yet (but will
|
||||
/// be freed by other threads in the future) is properly handled.
|
||||
void mi_thread_done();
|
||||
void mi_thread_done(void);
|
||||
|
||||
/// Print out heap statistics for this thread.
|
||||
/// @param out Output file. Use \a NULL for \a stderr.
|
||||
/// @param out Output function. Use \a NULL for outputting to \a stderr.
|
||||
///
|
||||
/// Most detailed when using a debug build.
|
||||
void mi_thread_stats_print(FILE* out);
|
||||
void mi_thread_stats_print(mi_output_fun* out);
|
||||
|
||||
/// Type of deferred free functions.
|
||||
/// @param force If \a true all outstanding items should be freed.
|
||||
@ -342,6 +348,45 @@ typedef void (mi_deferred_free_fun)(bool force, unsigned long long heartbeat);
|
||||
/// At most one \a deferred_free function can be active.
|
||||
void mi_register_deferred_free(mi_deferred_free_fun* deferred_free);
|
||||
|
||||
/// Type of output functions.
|
||||
/// @param msg Message to output.
|
||||
///
|
||||
/// @see mi_register_output()
|
||||
typedef void (mi_output_fun)(const char* msg);
|
||||
|
||||
/// Register an output function.
|
||||
/// @param out The output function, use `NULL` to output to stdout.
|
||||
///
|
||||
/// The `out` function is called to output any information from mimalloc,
|
||||
/// like verbose or warning messages.
|
||||
void mi_register_output(mi_output_fun* out) mi_attr_noexcept;
|
||||
|
||||
/// Is a pointer part of our heap?
|
||||
/// @param p The pointer to check.
|
||||
/// @returns \a true if this is a pointer into our heap.
|
||||
/// This function is relatively fast.
|
||||
bool mi_is_in_heap_region(const void* p);
|
||||
|
||||
/// Reserve \a pages of huge OS pages (1GiB) but stops after at most `max_secs` seconds.
|
||||
/// @param pages The number of 1GiB pages to reserve.
|
||||
/// @param max_secs Maximum number of seconds to try reserving.
|
||||
/// @param pages_reserved If not \a NULL, it is set to the actual number of pages that were reserved.
|
||||
/// @returns 0 if successfull, \a ENOMEM if running out of memory, or \a ETIMEDOUT if timed out.
|
||||
///
|
||||
/// The reserved memory is used by mimalloc to satisfy allocations.
|
||||
/// May quit before \a max_secs are expired if it estimates it will take more than
|
||||
/// 1.5 times \a max_secs. The time limit is needed because on some operating systems
|
||||
/// it can take a long time to reserve contiguous memory if the physical memory is
|
||||
/// fragmented.
|
||||
int mi_reserve_huge_os_pages(size_t pages, double max_secs, size_t* pages_reserved);
|
||||
|
||||
/// Is the C runtime \a malloc API redirected?
|
||||
/// @returns \a true if all malloc API calls are redirected to mimalloc.
|
||||
///
|
||||
/// Currenty only used on Windows.
|
||||
bool mi_is_redirected();
|
||||
|
||||
|
||||
/// \}
|
||||
|
||||
// ------------------------------------------------------
|
||||
@ -443,10 +488,18 @@ mi_heap_t* mi_heap_get_default();
|
||||
/// except by exiting the thread.
|
||||
mi_heap_t* mi_heap_get_backing();
|
||||
|
||||
/// Release outstanding resources in a specific heap.
|
||||
void mi_heap_collect(mi_heap_t* heap, bool force);
|
||||
|
||||
/// Allocate in a specific heap.
|
||||
/// @see mi_malloc()
|
||||
void* mi_heap_malloc(mi_heap_t* heap, size_t size);
|
||||
|
||||
/// Allocate a small object in a specific heap.
|
||||
/// \a size must be smaller or equal to MI_SMALL_SIZE_MAX().
|
||||
/// @see mi_malloc()
|
||||
void* mi_heap_malloc_small(mi_heap_t* heap, size_t size);
|
||||
|
||||
/// Allocate zero-initialized in a specific heap.
|
||||
/// @see mi_zalloc()
|
||||
void* mi_heap_zalloc(mi_heap_t* heap, size_t size);
|
||||
@ -486,6 +539,34 @@ void* mi_heap_realloc_aligned_at(mi_heap_t* heap, void* p, size_t newsize, size_
|
||||
|
||||
/// \}
|
||||
|
||||
|
||||
/// \defgroup zeroinit Zero initialized re-allocation
|
||||
///
|
||||
/// The zero-initialized re-allocations are only valid on memory that was
|
||||
/// originally allocated with zero initialization too.
|
||||
/// e.g. `mi_calloc`, `mi_zalloc`, `mi_zalloc_aligned` etc.
|
||||
/// see <https://github.com/microsoft/mimalloc/issues/63#issuecomment-508272992>
|
||||
///
|
||||
/// \{
|
||||
|
||||
void* mi_rezalloc(void* p, size_t newsize);
|
||||
void* mi_recalloc(void* p, size_t newcount, size_t size) ;
|
||||
|
||||
void* mi_rezalloc_aligned(void* p, size_t newsize, size_t alignment);
|
||||
void* mi_rezalloc_aligned_at(void* p, size_t newsize, size_t alignment, size_t offset);
|
||||
void* mi_recalloc_aligned(void* p, size_t newcount, size_t size, size_t alignment);
|
||||
void* mi_recalloc_aligned_at(void* p, size_t newcount, size_t size, size_t alignment, size_t offset);
|
||||
|
||||
void* mi_heap_rezalloc(mi_heap_t* heap, void* p, size_t newsize);
|
||||
void* mi_heap_recalloc(mi_heap_t* heap, void* p, size_t newcount, size_t size);
|
||||
|
||||
void* mi_heap_rezalloc_aligned(mi_heap_t* heap, void* p, size_t newsize, size_t alignment);
|
||||
void* mi_heap_rezalloc_aligned_at(mi_heap_t* heap, void* p, size_t newsize, size_t alignment, size_t offset);
|
||||
void* mi_heap_recalloc_aligned(mi_heap_t* heap, void* p, size_t newcount, size_t size, size_t alignment);
|
||||
void* mi_heap_recalloc_aligned_at(mi_heap_t* heap, void* p, size_t newcount, size_t size, size_t alignment, size_t offset);
|
||||
|
||||
/// \}
|
||||
|
||||
/// \defgroup typed Typed Macros
|
||||
///
|
||||
/// Typed allocation macros
|
||||
@ -532,6 +613,9 @@ void* mi_heap_realloc_aligned_at(mi_heap_t* heap, void* p, size_t newsize, size_
|
||||
/// Re-allocate to \a count blocks of type \a tp in a heap \a hp.
|
||||
#define mi_heap_reallocn_tp(hp,p,tp,count) ((tp*)mi_heap_reallocn(p,count,sizeof(tp)))
|
||||
|
||||
/// Re-allocate to \a count zero initialized blocks of type \a tp in a heap \a hp.
|
||||
#define mi_heap_recalloc_tp(hp,p,tp,count) ((tp*)mi_heap_recalloc(p,count,sizeof(tp)))
|
||||
|
||||
/// \}
|
||||
|
||||
/// \defgroup analysis Heap Introspection
|
||||
@ -614,14 +698,17 @@ typedef enum mi_option_e {
|
||||
mi_option_show_errors, ///< Print error messages to `stderr`.
|
||||
mi_option_verbose, ///< Print verbose messages to `stderr`.
|
||||
// the following options are experimental
|
||||
mi_option_secure, ///< Experimental
|
||||
mi_option_eager_commit, ///< Eagerly commit segments (4MiB) (enabled by default).
|
||||
mi_option_eager_region_commit, ///< Eagerly commit large (256MiB) memory regions (enabled by default except on Windows)
|
||||
mi_option_large_os_pages, ///< Use large OS pages if possible
|
||||
mi_option_eager_region_commit, ///< Eagerly commit large (256MiB) memory regions (enabled by default, except on Windows)
|
||||
mi_option_large_os_pages, ///< Use large OS pages (2MiB in size) if possible
|
||||
mi_option_reserve_huge_os_pages, ///< The number of huge OS pages (1GiB in size) to reserve at the start of the program.
|
||||
mi_option_segment_cache, ///< The number of segments per thread to keep cached.
|
||||
mi_option_page_reset, ///< Reset page memory when it becomes free.
|
||||
mi_option_cache_reset, ///< Reset segment memory when a segment is cached.
|
||||
mi_option_reset_decommits, ///< Experimental
|
||||
mi_option_reset_discards, ///< Experimental
|
||||
mi_option_eager_commit_delay, ///< Experimental
|
||||
mi_option_segment_reset, ///< Experimental
|
||||
mi_option_os_tag, ///< OS tag to assign to mimalloc'd memory
|
||||
_mi_option_last
|
||||
} mi_option_t;
|
||||
|
||||
@ -647,6 +734,8 @@ void mi_option_set_default(mi_option_t option, long value);
|
||||
void* mi_recalloc(void* p, size_t count, size_t size);
|
||||
size_t mi_malloc_size(const void* p);
|
||||
size_t mi_malloc_usable_size(const void *p);
|
||||
|
||||
/// Just as `free` but also checks if the pointer `p` belongs to our heap.
|
||||
void mi_cfree(void* p);
|
||||
|
||||
int mi_posix_memalign(void** p, size_t alignment, size_t size);
|
||||
@ -804,9 +893,12 @@ completely and redirect all calls to the _mimalloc_ library instead.
|
||||
|
||||
See \ref overrides for more info.
|
||||
|
||||
## Environment Options
|
||||
*/
|
||||
|
||||
You can set further options either programmatically (using [`mi_option_set`](https://microsoft.github.io/mimalloc/group__options.html)),
|
||||
/*! \page environment Environment Options
|
||||
|
||||
You can set further options either programmatically
|
||||
(using [`mi_option_set`](https://microsoft.github.io/mimalloc/group__options.html)),
|
||||
or via environment variables.
|
||||
|
||||
- `MIMALLOC_SHOW_STATS=1`: show statistics when the program terminates.
|
||||
@ -869,19 +961,23 @@ Note: unfortunately, at this time, dynamic overriding on macOS seems broken but
|
||||
### Windows
|
||||
|
||||
On Windows you need to link your program explicitly with the mimalloc
|
||||
DLL, and use the C-runtime library as a DLL (the `/MD` or `/MDd` switch).
|
||||
To ensure the mimalloc DLL gets loaded it is easiest to insert some
|
||||
DLL and use the C-runtime library as a DLL (using the `/MD` or `/MDd` switch).
|
||||
Moreover, you need to ensure the `mimalloc-redirect.dll` (or `mimalloc-redirect32.dll`) is available
|
||||
in the same folder as the mimalloc DLL at runtime (as it as referred to by the mimalloc DLL).
|
||||
The redirection DLL's ensure all calls to the C runtime malloc API get redirected to mimalloc.
|
||||
|
||||
To ensure the mimalloc DLL is loaded at run-time it is easiest to insert some
|
||||
call to the mimalloc API in the `main` function, like `mi_version()`
|
||||
(or use the `/INCLUDE:mi_version` switch on the linker)
|
||||
(or use the `/INCLUDE:mi_version` switch on the linker). See the `mimalloc-override-test` project
|
||||
for an example on how to use this.
|
||||
|
||||
Due to the way mimalloc intercepts the standard malloc at runtime, it is best
|
||||
to link to the mimalloc import library first on the command line so it gets
|
||||
loaded right after the universal C runtime DLL (`ucrtbase`). See
|
||||
the `mimalloc-override-test` project for an example.
|
||||
The environment variable `MIMALLOC_DISABLE_REDIRECT=1` can be used to disable dynamic
|
||||
overriding at run-time. Use `MIMALLOC_VERBOSE=1` to check if mimalloc successfully redirected.
|
||||
|
||||
Note: the current overriding on Windows works for most programs but some programs still have
|
||||
trouble -- the `dev-exp` branch contains a newer way of overriding that is more
|
||||
robust; try this out if you experience troubles.
|
||||
(Note: in principle, it should be possible to patch existing executables
|
||||
that are linked with the dynamic C runtime (`ucrtbase.dll`) by just putting the mimalloc DLL into
|
||||
the import table (and putting `mimalloc-redirect.dll` in the same folder)
|
||||
Such patching can be done for example with [CFF Explorer](https://ntcore.com/?page_id=388)).
|
||||
|
||||
## Static override
|
||||
|
||||
@ -897,8 +993,6 @@ object file. For example:
|
||||
gcc -o myprogram mimalloc-override.o myfile1.c ...
|
||||
```
|
||||
|
||||
|
||||
|
||||
## List of Overrides:
|
||||
|
||||
The specific functions that get redirected to the _mimalloc_ library are:
|
||||
|
@ -121,6 +121,9 @@ Typedefs</h2></td></tr>
|
||||
<tr class="memitem:ga22213691c3ce5ab4d91b24aff1023529"><td class="memItemLeft" align="right" valign="top">typedef void() </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga22213691c3ce5ab4d91b24aff1023529">mi_deferred_free_fun</a>(bool force, unsigned long long heartbeat)</td></tr>
|
||||
<tr class="memdesc:ga22213691c3ce5ab4d91b24aff1023529"><td class="mdescLeft"> </td><td class="mdescRight">Type of deferred free functions. <a href="#ga22213691c3ce5ab4d91b24aff1023529">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga22213691c3ce5ab4d91b24aff1023529"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga2bed6d40b74591a67f81daea4b4a246f"><td class="memItemLeft" align="right" valign="top">typedef void() </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga2bed6d40b74591a67f81daea4b4a246f">mi_output_fun</a>(const char *msg)</td></tr>
|
||||
<tr class="memdesc:ga2bed6d40b74591a67f81daea4b4a246f"><td class="mdescLeft"> </td><td class="mdescRight">Type of output functions. <a href="#ga2bed6d40b74591a67f81daea4b4a246f">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga2bed6d40b74591a67f81daea4b4a246f"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
</table><table class="memberdecls">
|
||||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
|
||||
Functions</h2></td></tr>
|
||||
@ -139,24 +142,39 @@ Functions</h2></td></tr>
|
||||
<tr class="memitem:ga421430e2226d7d468529cec457396756"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga421430e2226d7d468529cec457396756">mi_collect</a> (bool force)</td></tr>
|
||||
<tr class="memdesc:ga421430e2226d7d468529cec457396756"><td class="mdescLeft"> </td><td class="mdescRight">Eagerly free memory. <a href="#ga421430e2226d7d468529cec457396756">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga421430e2226d7d468529cec457396756"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga6bb821ca1b664b452112c0e17b15fcf1"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga6bb821ca1b664b452112c0e17b15fcf1">mi_stats_print</a> (FILE *out)</td></tr>
|
||||
<tr class="memdesc:ga6bb821ca1b664b452112c0e17b15fcf1"><td class="mdescLeft"> </td><td class="mdescRight">Print statistics. <a href="#ga6bb821ca1b664b452112c0e17b15fcf1">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga6bb821ca1b664b452112c0e17b15fcf1"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga9883b8a059aed7eb0888a01ec1461161"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga9883b8a059aed7eb0888a01ec1461161">mi_stats_reset</a> ()</td></tr>
|
||||
<tr class="memdesc:ga9883b8a059aed7eb0888a01ec1461161"><td class="mdescLeft"> </td><td class="mdescRight">Reset statistics. <a href="#ga9883b8a059aed7eb0888a01ec1461161">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga9883b8a059aed7eb0888a01ec1461161"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga9398517f01a1ec971244aa0db084ea46"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga9398517f01a1ec971244aa0db084ea46">mi_thread_init</a> ()</td></tr>
|
||||
<tr class="memdesc:ga9398517f01a1ec971244aa0db084ea46"><td class="mdescLeft"> </td><td class="mdescRight">Initialize mimalloc on a thread. <a href="#ga9398517f01a1ec971244aa0db084ea46">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga9398517f01a1ec971244aa0db084ea46"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:gac0f4849256aaf677f334690952c6ebbd"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#gac0f4849256aaf677f334690952c6ebbd">mi_thread_done</a> ()</td></tr>
|
||||
<tr class="memdesc:gac0f4849256aaf677f334690952c6ebbd"><td class="mdescLeft"> </td><td class="mdescRight">Uninitialize mimalloc on a thread. <a href="#gac0f4849256aaf677f334690952c6ebbd">More...</a><br /></td></tr>
|
||||
<tr class="separator:gac0f4849256aaf677f334690952c6ebbd"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga490826cbd7c494acc9fe69be23f018ac"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga490826cbd7c494acc9fe69be23f018ac">mi_thread_stats_print</a> (FILE *out)</td></tr>
|
||||
<tr class="memdesc:ga490826cbd7c494acc9fe69be23f018ac"><td class="mdescLeft"> </td><td class="mdescRight">Print out heap statistics for this thread. <a href="#ga490826cbd7c494acc9fe69be23f018ac">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga490826cbd7c494acc9fe69be23f018ac"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga8ca07ccff283956d71f48272f4fd5c01"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga8ca07ccff283956d71f48272f4fd5c01">mi_stats_print</a> (<a class="el" href="group__extended.html#ga2bed6d40b74591a67f81daea4b4a246f">mi_output_fun</a> *out)</td></tr>
|
||||
<tr class="memdesc:ga8ca07ccff283956d71f48272f4fd5c01"><td class="mdescLeft"> </td><td class="mdescRight">Print the main statistics. <a href="#ga8ca07ccff283956d71f48272f4fd5c01">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga8ca07ccff283956d71f48272f4fd5c01"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga3bb8468b8cfcc6e2a61d98aee85c5f99"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga3bb8468b8cfcc6e2a61d98aee85c5f99">mi_stats_reset</a> (void)</td></tr>
|
||||
<tr class="memdesc:ga3bb8468b8cfcc6e2a61d98aee85c5f99"><td class="mdescLeft"> </td><td class="mdescRight">Reset statistics. <a href="#ga3bb8468b8cfcc6e2a61d98aee85c5f99">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga3bb8468b8cfcc6e2a61d98aee85c5f99"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga854b1de8cb067c7316286c28b2fcd3d1"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga854b1de8cb067c7316286c28b2fcd3d1">mi_stats_merge</a> (void)</td></tr>
|
||||
<tr class="memdesc:ga854b1de8cb067c7316286c28b2fcd3d1"><td class="mdescLeft"> </td><td class="mdescRight">Merge thread local statistics with the main statistics and reset. <a href="#ga854b1de8cb067c7316286c28b2fcd3d1">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga854b1de8cb067c7316286c28b2fcd3d1"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:gaf8e73efc2cbca9ebfdfb166983a04c17"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#gaf8e73efc2cbca9ebfdfb166983a04c17">mi_thread_init</a> (void)</td></tr>
|
||||
<tr class="memdesc:gaf8e73efc2cbca9ebfdfb166983a04c17"><td class="mdescLeft"> </td><td class="mdescRight">Initialize mimalloc on a thread. <a href="#gaf8e73efc2cbca9ebfdfb166983a04c17">More...</a><br /></td></tr>
|
||||
<tr class="separator:gaf8e73efc2cbca9ebfdfb166983a04c17"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga0ae4581e85453456a0d658b2b98bf7bf"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga0ae4581e85453456a0d658b2b98bf7bf">mi_thread_done</a> (void)</td></tr>
|
||||
<tr class="memdesc:ga0ae4581e85453456a0d658b2b98bf7bf"><td class="mdescLeft"> </td><td class="mdescRight">Uninitialize mimalloc on a thread. <a href="#ga0ae4581e85453456a0d658b2b98bf7bf">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga0ae4581e85453456a0d658b2b98bf7bf"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga489670a15d1a257ab4639e645ee4612a"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga489670a15d1a257ab4639e645ee4612a">mi_thread_stats_print</a> (<a class="el" href="group__extended.html#ga2bed6d40b74591a67f81daea4b4a246f">mi_output_fun</a> *out)</td></tr>
|
||||
<tr class="memdesc:ga489670a15d1a257ab4639e645ee4612a"><td class="mdescLeft"> </td><td class="mdescRight">Print out heap statistics for this thread. <a href="#ga489670a15d1a257ab4639e645ee4612a">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga489670a15d1a257ab4639e645ee4612a"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga24dc9cc6fca8daa2aa30aa8025467ce2"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga24dc9cc6fca8daa2aa30aa8025467ce2">mi_register_deferred_free</a> (<a class="el" href="group__extended.html#ga22213691c3ce5ab4d91b24aff1023529">mi_deferred_free_fun</a> *deferred_free)</td></tr>
|
||||
<tr class="memdesc:ga24dc9cc6fca8daa2aa30aa8025467ce2"><td class="mdescLeft"> </td><td class="mdescRight">Register a deferred free function. <a href="#ga24dc9cc6fca8daa2aa30aa8025467ce2">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga24dc9cc6fca8daa2aa30aa8025467ce2"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga84a0c8b401e42eb5b1bce156852f44c5"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga84a0c8b401e42eb5b1bce156852f44c5">mi_register_output</a> (<a class="el" href="group__extended.html#ga2bed6d40b74591a67f81daea4b4a246f">mi_output_fun</a> *out) mi_attr_noexcept</td></tr>
|
||||
<tr class="memdesc:ga84a0c8b401e42eb5b1bce156852f44c5"><td class="mdescLeft"> </td><td class="mdescRight">Register an output function. <a href="#ga84a0c8b401e42eb5b1bce156852f44c5">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga84a0c8b401e42eb5b1bce156852f44c5"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga5f071b10d4df1c3658e04e7fd67a94e6"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga5f071b10d4df1c3658e04e7fd67a94e6">mi_is_in_heap_region</a> (const void *p)</td></tr>
|
||||
<tr class="memdesc:ga5f071b10d4df1c3658e04e7fd67a94e6"><td class="mdescLeft"> </td><td class="mdescRight">Is a pointer part of our heap? <a href="#ga5f071b10d4df1c3658e04e7fd67a94e6">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga5f071b10d4df1c3658e04e7fd67a94e6"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga2664f36a2dd557741c429cb799f04641"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#ga2664f36a2dd557741c429cb799f04641">mi_reserve_huge_os_pages</a> (size_t pages, double max_secs, size_t *pages_reserved)</td></tr>
|
||||
<tr class="memdesc:ga2664f36a2dd557741c429cb799f04641"><td class="mdescLeft"> </td><td class="mdescRight">Reserve <em>pages</em> of huge OS pages (1GiB) but stops after at most <code>max_secs</code> seconds. <a href="#ga2664f36a2dd557741c429cb799f04641">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga2664f36a2dd557741c429cb799f04641"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:gaad25050b19f30cd79397b227e0157a3f"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="group__extended.html#gaad25050b19f30cd79397b227e0157a3f">mi_is_redirected</a> ()</td></tr>
|
||||
<tr class="memdesc:gaad25050b19f30cd79397b227e0157a3f"><td class="mdescLeft"> </td><td class="mdescRight">Is the C runtime <em>malloc</em> API redirected? <a href="#gaad25050b19f30cd79397b227e0157a3f">More...</a><br /></td></tr>
|
||||
<tr class="separator:gaad25050b19f30cd79397b227e0157a3f"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
</table>
|
||||
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
||||
<p>Extended functionality. </p>
|
||||
@ -200,6 +218,29 @@ Functions</h2></td></tr>
|
||||
</dl>
|
||||
<dl class="section see"><dt>See also</dt><dd><a class="el" href="group__extended.html#ga24dc9cc6fca8daa2aa30aa8025467ce2" title="Register a deferred free function.">mi_register_deferred_free</a> </dd></dl>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga2bed6d40b74591a67f81daea4b4a246f"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga2bed6d40b74591a67f81daea4b4a246f">◆ </a></span>mi_output_fun</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">typedef void() mi_output_fun(const char *msg)</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Type of output functions. </p>
|
||||
<dl class="params"><dt>Parameters</dt><dd>
|
||||
<table class="params">
|
||||
<tr><td class="paramname">msg</td><td>Message to output.</td></tr>
|
||||
</table>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="section see"><dt>See also</dt><dd><a class="el" href="group__extended.html#ga84a0c8b401e42eb5b1bce156852f44c5" title="Register an output function.">mi_register_output()</a> </dd></dl>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<h2 class="groupheader">Function Documentation</h2>
|
||||
@ -257,6 +298,54 @@ Functions</h2></td></tr>
|
||||
<p>Generally, <code>mi_usable_size(mi_malloc(size)) == mi_good_size(size)</code>. This can be used to reduce internal wasted space when allocating buffers for example.</p>
|
||||
<dl class="section see"><dt>See also</dt><dd><a class="el" href="group__extended.html#ga089c859d9eddc5f9b4bd946cd53cebee" title="Return the available bytes in a memory block.">mi_usable_size()</a> </dd></dl>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga5f071b10d4df1c3658e04e7fd67a94e6"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga5f071b10d4df1c3658e04e7fd67a94e6">◆ </a></span>mi_is_in_heap_region()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">bool mi_is_in_heap_region </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">const void * </td>
|
||||
<td class="paramname"><em>p</em></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Is a pointer part of our heap? </p>
|
||||
<dl class="params"><dt>Parameters</dt><dd>
|
||||
<table class="params">
|
||||
<tr><td class="paramname">p</td><td>The pointer to check. </td></tr>
|
||||
</table>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="section return"><dt>Returns</dt><dd><em>true</em> if this is a pointer into our heap. This function is relatively fast. </dd></dl>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="gaad25050b19f30cd79397b227e0157a3f"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#gaad25050b19f30cd79397b227e0157a3f">◆ </a></span>mi_is_redirected()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">bool mi_is_redirected </td>
|
||||
<td>(</td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Is the C runtime <em>malloc</em> API redirected? </p>
|
||||
<dl class="section return"><dt>Returns</dt><dd><em>true</em> if all malloc API calls are redirected to mimalloc.</dd></dl>
|
||||
<p>Currenty only used on Windows. </p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga7136c2e55cb22c98ecf95d08d6debb99"></a>
|
||||
@ -313,8 +402,101 @@ Functions</h2></td></tr>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga6bb821ca1b664b452112c0e17b15fcf1"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga6bb821ca1b664b452112c0e17b15fcf1">◆ </a></span>mi_stats_print()</h2>
|
||||
<a id="ga84a0c8b401e42eb5b1bce156852f44c5"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga84a0c8b401e42eb5b1bce156852f44c5">◆ </a></span>mi_register_output()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void mi_register_output </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype"><a class="el" href="group__extended.html#ga2bed6d40b74591a67f81daea4b4a246f">mi_output_fun</a> * </td>
|
||||
<td class="paramname"><em>out</em></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Register an output function. </p>
|
||||
<dl class="params"><dt>Parameters</dt><dd>
|
||||
<table class="params">
|
||||
<tr><td class="paramname">out</td><td>The output function, use <code>NULL</code> to output to stdout.</td></tr>
|
||||
</table>
|
||||
</dd>
|
||||
</dl>
|
||||
<p>The <code>out</code> function is called to output any information from mimalloc, like verbose or warning messages. </p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga2664f36a2dd557741c429cb799f04641"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga2664f36a2dd557741c429cb799f04641">◆ </a></span>mi_reserve_huge_os_pages()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">int mi_reserve_huge_os_pages </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">size_t </td>
|
||||
<td class="paramname"><em>pages</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype">double </td>
|
||||
<td class="paramname"><em>max_secs</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype">size_t * </td>
|
||||
<td class="paramname"><em>pages_reserved</em> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>)</td>
|
||||
<td></td><td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Reserve <em>pages</em> of huge OS pages (1GiB) but stops after at most <code>max_secs</code> seconds. </p>
|
||||
<dl class="params"><dt>Parameters</dt><dd>
|
||||
<table class="params">
|
||||
<tr><td class="paramname">pages</td><td>The number of 1GiB pages to reserve. </td></tr>
|
||||
<tr><td class="paramname">max_secs</td><td>Maximum number of seconds to try reserving. </td></tr>
|
||||
<tr><td class="paramname">pages_reserved</td><td>If not <em>NULL</em>, it is set to the actual number of pages that were reserved. </td></tr>
|
||||
</table>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="section return"><dt>Returns</dt><dd>0 if successfull, <em>ENOMEM</em> if running out of memory, or <em>ETIMEDOUT</em> if timed out.</dd></dl>
|
||||
<p>The reserved memory is used by mimalloc to satisfy allocations. May quit before <em>max_secs</em> are expired if it estimates it will take more than 1.5 times <em>max_secs</em>. The time limit is needed because on some operating systems it can take a long time to reserve contiguous memory if the physical memory is fragmented. </p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga854b1de8cb067c7316286c28b2fcd3d1"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga854b1de8cb067c7316286c28b2fcd3d1">◆ </a></span>mi_stats_merge()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void mi_stats_merge </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">void </td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Merge thread local statistics with the main statistics and reset. </p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga8ca07ccff283956d71f48272f4fd5c01"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga8ca07ccff283956d71f48272f4fd5c01">◆ </a></span>mi_stats_print()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
@ -322,17 +504,17 @@ Functions</h2></td></tr>
|
||||
<tr>
|
||||
<td class="memname">void mi_stats_print </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">FILE * </td>
|
||||
<td class="paramtype"><a class="el" href="group__extended.html#ga2bed6d40b74591a67f81daea4b4a246f">mi_output_fun</a> * </td>
|
||||
<td class="paramname"><em>out</em></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Print statistics. </p>
|
||||
<p>Print the main statistics. </p>
|
||||
<dl class="params"><dt>Parameters</dt><dd>
|
||||
<table class="params">
|
||||
<tr><td class="paramname">out</td><td>Output file. Use <em>NULL</em> for <em>stderr</em>.</td></tr>
|
||||
<tr><td class="paramname">out</td><td>Output function. Use <em>NULL</em> for outputting to <em>stderr</em>.</td></tr>
|
||||
</table>
|
||||
</dd>
|
||||
</dl>
|
||||
@ -340,8 +522,8 @@ Functions</h2></td></tr>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga9883b8a059aed7eb0888a01ec1461161"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga9883b8a059aed7eb0888a01ec1461161">◆ </a></span>mi_stats_reset()</h2>
|
||||
<a id="ga3bb8468b8cfcc6e2a61d98aee85c5f99"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga3bb8468b8cfcc6e2a61d98aee85c5f99">◆ </a></span>mi_stats_reset()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
@ -349,6 +531,7 @@ Functions</h2></td></tr>
|
||||
<tr>
|
||||
<td class="memname">void mi_stats_reset </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">void </td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
@ -359,8 +542,8 @@ Functions</h2></td></tr>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="gac0f4849256aaf677f334690952c6ebbd"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#gac0f4849256aaf677f334690952c6ebbd">◆ </a></span>mi_thread_done()</h2>
|
||||
<a id="ga0ae4581e85453456a0d658b2b98bf7bf"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga0ae4581e85453456a0d658b2b98bf7bf">◆ </a></span>mi_thread_done()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
@ -368,6 +551,7 @@ Functions</h2></td></tr>
|
||||
<tr>
|
||||
<td class="memname">void mi_thread_done </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">void </td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
@ -379,8 +563,8 @@ Functions</h2></td></tr>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga9398517f01a1ec971244aa0db084ea46"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga9398517f01a1ec971244aa0db084ea46">◆ </a></span>mi_thread_init()</h2>
|
||||
<a id="gaf8e73efc2cbca9ebfdfb166983a04c17"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#gaf8e73efc2cbca9ebfdfb166983a04c17">◆ </a></span>mi_thread_init()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
@ -388,6 +572,7 @@ Functions</h2></td></tr>
|
||||
<tr>
|
||||
<td class="memname">void mi_thread_init </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">void </td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
@ -399,8 +584,8 @@ Functions</h2></td></tr>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga490826cbd7c494acc9fe69be23f018ac"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga490826cbd7c494acc9fe69be23f018ac">◆ </a></span>mi_thread_stats_print()</h2>
|
||||
<a id="ga489670a15d1a257ab4639e645ee4612a"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga489670a15d1a257ab4639e645ee4612a">◆ </a></span>mi_thread_stats_print()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
@ -408,7 +593,7 @@ Functions</h2></td></tr>
|
||||
<tr>
|
||||
<td class="memname">void mi_thread_stats_print </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">FILE * </td>
|
||||
<td class="paramtype"><a class="el" href="group__extended.html#ga2bed6d40b74591a67f81daea4b4a246f">mi_output_fun</a> * </td>
|
||||
<td class="paramname"><em>out</em></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
@ -418,7 +603,7 @@ Functions</h2></td></tr>
|
||||
<p>Print out heap statistics for this thread. </p>
|
||||
<dl class="params"><dt>Parameters</dt><dd>
|
||||
<table class="params">
|
||||
<tr><td class="paramname">out</td><td>Output file. Use <em>NULL</em> for <em>stderr</em>.</td></tr>
|
||||
<tr><td class="paramname">out</td><td>Output function. Use <em>NULL</em> for outputting to <em>stderr</em>.</td></tr>
|
||||
</table>
|
||||
</dd>
|
||||
</dl>
|
||||
|
@ -2,15 +2,21 @@ var group__extended =
|
||||
[
|
||||
[ "MI_SMALL_SIZE_MAX", "group__extended.html#ga1ea64283508718d9d645c38efc2f4305", null ],
|
||||
[ "mi_deferred_free_fun", "group__extended.html#ga22213691c3ce5ab4d91b24aff1023529", null ],
|
||||
[ "mi_output_fun", "group__extended.html#ga2bed6d40b74591a67f81daea4b4a246f", null ],
|
||||
[ "mi_collect", "group__extended.html#ga421430e2226d7d468529cec457396756", null ],
|
||||
[ "mi_good_size", "group__extended.html#gac057927cd06c854b45fe7847e921bd47", null ],
|
||||
[ "mi_is_in_heap_region", "group__extended.html#ga5f071b10d4df1c3658e04e7fd67a94e6", null ],
|
||||
[ "mi_is_redirected", "group__extended.html#gaad25050b19f30cd79397b227e0157a3f", null ],
|
||||
[ "mi_malloc_small", "group__extended.html#ga7136c2e55cb22c98ecf95d08d6debb99", null ],
|
||||
[ "mi_register_deferred_free", "group__extended.html#ga24dc9cc6fca8daa2aa30aa8025467ce2", null ],
|
||||
[ "mi_stats_print", "group__extended.html#ga6bb821ca1b664b452112c0e17b15fcf1", null ],
|
||||
[ "mi_stats_reset", "group__extended.html#ga9883b8a059aed7eb0888a01ec1461161", null ],
|
||||
[ "mi_thread_done", "group__extended.html#gac0f4849256aaf677f334690952c6ebbd", null ],
|
||||
[ "mi_thread_init", "group__extended.html#ga9398517f01a1ec971244aa0db084ea46", null ],
|
||||
[ "mi_thread_stats_print", "group__extended.html#ga490826cbd7c494acc9fe69be23f018ac", null ],
|
||||
[ "mi_register_output", "group__extended.html#ga84a0c8b401e42eb5b1bce156852f44c5", null ],
|
||||
[ "mi_reserve_huge_os_pages", "group__extended.html#ga2664f36a2dd557741c429cb799f04641", null ],
|
||||
[ "mi_stats_merge", "group__extended.html#ga854b1de8cb067c7316286c28b2fcd3d1", null ],
|
||||
[ "mi_stats_print", "group__extended.html#ga8ca07ccff283956d71f48272f4fd5c01", null ],
|
||||
[ "mi_stats_reset", "group__extended.html#ga3bb8468b8cfcc6e2a61d98aee85c5f99", null ],
|
||||
[ "mi_thread_done", "group__extended.html#ga0ae4581e85453456a0d658b2b98bf7bf", null ],
|
||||
[ "mi_thread_init", "group__extended.html#gaf8e73efc2cbca9ebfdfb166983a04c17", null ],
|
||||
[ "mi_thread_stats_print", "group__extended.html#ga489670a15d1a257ab4639e645ee4612a", null ],
|
||||
[ "mi_usable_size", "group__extended.html#ga089c859d9eddc5f9b4bd946cd53cebee", null ],
|
||||
[ "mi_zalloc_small", "group__extended.html#ga220f29f40a44404b0061c15bc1c31152", null ]
|
||||
];
|
@ -135,9 +135,15 @@ Functions</h2></td></tr>
|
||||
<tr class="memitem:ga5d03fbe062ffcf38f0f417fd968357fc"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__heap.html#ga34a47cde5a5b38c29f1aa3c5e76943c2">mi_heap_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="group__heap.html#ga5d03fbe062ffcf38f0f417fd968357fc">mi_heap_get_backing</a> ()</td></tr>
|
||||
<tr class="memdesc:ga5d03fbe062ffcf38f0f417fd968357fc"><td class="mdescLeft"> </td><td class="mdescRight">Get the backing heap. <a href="#ga5d03fbe062ffcf38f0f417fd968357fc">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga5d03fbe062ffcf38f0f417fd968357fc"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga7922f7495cde30b1984d0e6072419298"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__heap.html#ga7922f7495cde30b1984d0e6072419298">mi_heap_collect</a> (<a class="el" href="group__heap.html#ga34a47cde5a5b38c29f1aa3c5e76943c2">mi_heap_t</a> *heap, bool force)</td></tr>
|
||||
<tr class="memdesc:ga7922f7495cde30b1984d0e6072419298"><td class="mdescLeft"> </td><td class="mdescRight">Release outstanding resources in a specific heap. <a href="#ga7922f7495cde30b1984d0e6072419298">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga7922f7495cde30b1984d0e6072419298"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga9cbed01e42c0647907295de92c3fa296"><td class="memItemLeft" align="right" valign="top">void * </td><td class="memItemRight" valign="bottom"><a class="el" href="group__heap.html#ga9cbed01e42c0647907295de92c3fa296">mi_heap_malloc</a> (<a class="el" href="group__heap.html#ga34a47cde5a5b38c29f1aa3c5e76943c2">mi_heap_t</a> *heap, size_t size)</td></tr>
|
||||
<tr class="memdesc:ga9cbed01e42c0647907295de92c3fa296"><td class="mdescLeft"> </td><td class="mdescRight">Allocate in a specific heap. <a href="#ga9cbed01e42c0647907295de92c3fa296">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga9cbed01e42c0647907295de92c3fa296"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:gaa1a1c7a1f4da6826b5a25b70ef878368"><td class="memItemLeft" align="right" valign="top">void * </td><td class="memItemRight" valign="bottom"><a class="el" href="group__heap.html#gaa1a1c7a1f4da6826b5a25b70ef878368">mi_heap_malloc_small</a> (<a class="el" href="group__heap.html#ga34a47cde5a5b38c29f1aa3c5e76943c2">mi_heap_t</a> *heap, size_t size)</td></tr>
|
||||
<tr class="memdesc:gaa1a1c7a1f4da6826b5a25b70ef878368"><td class="mdescLeft"> </td><td class="mdescRight">Allocate a small object in a specific heap. <a href="#gaa1a1c7a1f4da6826b5a25b70ef878368">More...</a><br /></td></tr>
|
||||
<tr class="separator:gaa1a1c7a1f4da6826b5a25b70ef878368"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga903104592c8ed53417a3762da6241133"><td class="memItemLeft" align="right" valign="top">void * </td><td class="memItemRight" valign="bottom"><a class="el" href="group__heap.html#ga903104592c8ed53417a3762da6241133">mi_heap_zalloc</a> (<a class="el" href="group__heap.html#ga34a47cde5a5b38c29f1aa3c5e76943c2">mi_heap_t</a> *heap, size_t size)</td></tr>
|
||||
<tr class="memdesc:ga903104592c8ed53417a3762da6241133"><td class="mdescLeft"> </td><td class="mdescRight">Allocate zero-initialized in a specific heap. <a href="#ga903104592c8ed53417a3762da6241133">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga903104592c8ed53417a3762da6241133"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
@ -321,6 +327,36 @@ Functions</h2></td></tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga7922f7495cde30b1984d0e6072419298"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga7922f7495cde30b1984d0e6072419298">◆ </a></span>mi_heap_collect()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void mi_heap_collect </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype"><a class="el" href="group__heap.html#ga34a47cde5a5b38c29f1aa3c5e76943c2">mi_heap_t</a> * </td>
|
||||
<td class="paramname"><em>heap</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype">bool </td>
|
||||
<td class="paramname"><em>force</em> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>)</td>
|
||||
<td></td><td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Release outstanding resources in a specific heap. </p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga2ab1af8d438819b55319c7ef51d1e409"></a>
|
||||
@ -510,6 +546,37 @@ Functions</h2></td></tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="gaa1a1c7a1f4da6826b5a25b70ef878368"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#gaa1a1c7a1f4da6826b5a25b70ef878368">◆ </a></span>mi_heap_malloc_small()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void* mi_heap_malloc_small </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype"><a class="el" href="group__heap.html#ga34a47cde5a5b38c29f1aa3c5e76943c2">mi_heap_t</a> * </td>
|
||||
<td class="paramname"><em>heap</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype">size_t </td>
|
||||
<td class="paramname"><em>size</em> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>)</td>
|
||||
<td></td><td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Allocate a small object in a specific heap. </p>
|
||||
<p><em>size</em> must be smaller or equal to <a class="el" href="group__extended.html#ga1ea64283508718d9d645c38efc2f4305" title="Maximum size allowed for small allocations in mi_malloc_small and mi_zalloc_small (usually 128*sizeof...">MI_SMALL_SIZE_MAX()</a>. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="group__malloc.html#ga3406e8b168bc74c8637b11571a6da83a" title="Allocate size bytes.">mi_malloc()</a> </dd></dl>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga851da6c43fe0b71c1376cee8aef90db0"></a>
|
||||
|
@ -4,6 +4,7 @@ var group__heap =
|
||||
[ "mi_heap_calloc", "group__heap.html#gaa6702b3c48e9e53e50e81b36f5011d55", null ],
|
||||
[ "mi_heap_calloc_aligned", "group__heap.html#ga4af03a6e2b93fae77424d93f889705c3", null ],
|
||||
[ "mi_heap_calloc_aligned_at", "group__heap.html#ga08ca6419a5c057a4d965868998eef487", null ],
|
||||
[ "mi_heap_collect", "group__heap.html#ga7922f7495cde30b1984d0e6072419298", null ],
|
||||
[ "mi_heap_delete", "group__heap.html#ga2ab1af8d438819b55319c7ef51d1e409", null ],
|
||||
[ "mi_heap_destroy", "group__heap.html#ga9f9c0844edb9717f4feacd79116b8e0d", null ],
|
||||
[ "mi_heap_get_backing", "group__heap.html#ga5d03fbe062ffcf38f0f417fd968357fc", null ],
|
||||
@ -11,6 +12,7 @@ var group__heap =
|
||||
[ "mi_heap_malloc", "group__heap.html#ga9cbed01e42c0647907295de92c3fa296", null ],
|
||||
[ "mi_heap_malloc_aligned", "group__heap.html#gab5b87e1805306f70df38789fcfcf6653", null ],
|
||||
[ "mi_heap_malloc_aligned_at", "group__heap.html#ga23acd7680fb0976dde3783254c6c874b", null ],
|
||||
[ "mi_heap_malloc_small", "group__heap.html#gaa1a1c7a1f4da6826b5a25b70ef878368", null ],
|
||||
[ "mi_heap_mallocn", "group__heap.html#ga851da6c43fe0b71c1376cee8aef90db0", null ],
|
||||
[ "mi_heap_new", "group__heap.html#ga766f672ba56f2fbfeb9d9dbb0b7f6b11", null ],
|
||||
[ "mi_heap_realloc", "group__heap.html#gaaef3395f66be48f37bdc8322509c5d81", null ],
|
||||
|
@ -115,16 +115,20 @@ Enumerations</h2></td></tr>
|
||||
  <a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca0957ef73b2550764b4840edf48422fda">mi_option_show_stats</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cafbf4822e5c00732c5984b32a032837f0">mi_option_show_errors</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca7c8b7bf5281c581bad64f5daa6442777">mi_option_verbose</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca083ee20765063fc6d727e11d33cf378f">mi_option_secure</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca1e8de72c93da7ff22d91e1e27b52ac2b">mi_option_eager_commit</a>,
|
||||
<br />
|
||||
  <a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca1e8de72c93da7ff22d91e1e27b52ac2b">mi_option_eager_commit</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca32ce97ece29f69e82579679cf8a307ad">mi_option_eager_region_commit</a>,
|
||||
  <a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca32ce97ece29f69e82579679cf8a307ad">mi_option_eager_region_commit</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca4192d491200d0055df0554d4cf65054e">mi_option_large_os_pages</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cada854dd272c66342f18a93ee254a2968">mi_option_page_reset</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884caca7ed041be3b0b9d0b82432c7bf41af2">mi_option_reserve_huge_os_pages</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca2ecbe7ef32f5c84de3739aa4f0b805a1">mi_option_segment_cache</a>,
|
||||
<br />
|
||||
  <a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cac2157a0cb79cd996c1db7d9f6a090c07">mi_option_cache_reset</a>,
|
||||
  <a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cada854dd272c66342f18a93ee254a2968">mi_option_page_reset</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cac2157a0cb79cd996c1db7d9f6a090c07">mi_option_cache_reset</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cac81ee965b130fa81238913a3c239d536">mi_option_reset_decommits</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cab3a837b5ceee250e14e051dbee2a441b">mi_option_reset_discards</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca17a190c25be381142d87e0468c4c068c">mi_option_eager_commit_delay</a>,
|
||||
<br />
|
||||
  <a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cafb121d30d87591850d5410ccc3a95c6d">mi_option_segment_reset</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca4b74ae2a69e445de6c2361b73c1d14bf">mi_option_os_tag</a>,
|
||||
<a class="el" href="group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca5b4357b74be0d87568036c32eb1a2e4a">_mi_option_last</a>
|
||||
<br />
|
||||
}</td></tr>
|
||||
@ -169,13 +173,15 @@ Functions</h2></td></tr>
|
||||
</td></tr>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884ca7c8b7bf5281c581bad64f5daa6442777"></a>mi_option_verbose </td><td class="fielddoc"><p>Print verbose messages to <code>stderr</code>. </p>
|
||||
</td></tr>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884ca083ee20765063fc6d727e11d33cf378f"></a>mi_option_secure </td><td class="fielddoc"><p>Experimental. </p>
|
||||
</td></tr>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884ca1e8de72c93da7ff22d91e1e27b52ac2b"></a>mi_option_eager_commit </td><td class="fielddoc"><p>Eagerly commit segments (4MiB) (enabled by default). </p>
|
||||
</td></tr>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884ca32ce97ece29f69e82579679cf8a307ad"></a>mi_option_eager_region_commit </td><td class="fielddoc"><p>Eagerly commit large (256MiB) memory regions (enabled by default except on Windows) </p>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884ca32ce97ece29f69e82579679cf8a307ad"></a>mi_option_eager_region_commit </td><td class="fielddoc"><p>Eagerly commit large (256MiB) memory regions (enabled by default, except on Windows) </p>
|
||||
</td></tr>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884ca4192d491200d0055df0554d4cf65054e"></a>mi_option_large_os_pages </td><td class="fielddoc"><p>Use large OS pages if possible. </p>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884ca4192d491200d0055df0554d4cf65054e"></a>mi_option_large_os_pages </td><td class="fielddoc"><p>Use large OS pages (2MiB in size) if possible. </p>
|
||||
</td></tr>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884caca7ed041be3b0b9d0b82432c7bf41af2"></a>mi_option_reserve_huge_os_pages </td><td class="fielddoc"><p>The number of huge OS pages (1GiB in size) to reserve at the start of the program. </p>
|
||||
</td></tr>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884ca2ecbe7ef32f5c84de3739aa4f0b805a1"></a>mi_option_segment_cache </td><td class="fielddoc"><p>The number of segments per thread to keep cached. </p>
|
||||
</td></tr>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884cada854dd272c66342f18a93ee254a2968"></a>mi_option_page_reset </td><td class="fielddoc"><p>Reset page memory when it becomes free. </p>
|
||||
</td></tr>
|
||||
@ -183,7 +189,11 @@ Functions</h2></td></tr>
|
||||
</td></tr>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884cac81ee965b130fa81238913a3c239d536"></a>mi_option_reset_decommits </td><td class="fielddoc"><p>Experimental. </p>
|
||||
</td></tr>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884cab3a837b5ceee250e14e051dbee2a441b"></a>mi_option_reset_discards </td><td class="fielddoc"><p>Experimental. </p>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884ca17a190c25be381142d87e0468c4c068c"></a>mi_option_eager_commit_delay </td><td class="fielddoc"><p>Experimental. </p>
|
||||
</td></tr>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884cafb121d30d87591850d5410ccc3a95c6d"></a>mi_option_segment_reset </td><td class="fielddoc"><p>Experimental. </p>
|
||||
</td></tr>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884ca4b74ae2a69e445de6c2361b73c1d14bf"></a>mi_option_os_tag </td><td class="fielddoc"><p>OS tag to assign to mimalloc'd memory. </p>
|
||||
</td></tr>
|
||||
<tr><td class="fieldname"><a id="ggafebf7ed116adb38ae5218bc3ce06884ca5b4357b74be0d87568036c32eb1a2e4a"></a>_mi_option_last </td><td class="fielddoc"></td></tr>
|
||||
</table>
|
||||
|
@ -4,14 +4,17 @@ var group__options =
|
||||
[ "mi_option_show_stats", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca0957ef73b2550764b4840edf48422fda", null ],
|
||||
[ "mi_option_show_errors", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cafbf4822e5c00732c5984b32a032837f0", null ],
|
||||
[ "mi_option_verbose", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca7c8b7bf5281c581bad64f5daa6442777", null ],
|
||||
[ "mi_option_secure", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca083ee20765063fc6d727e11d33cf378f", null ],
|
||||
[ "mi_option_eager_commit", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca1e8de72c93da7ff22d91e1e27b52ac2b", null ],
|
||||
[ "mi_option_eager_region_commit", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca32ce97ece29f69e82579679cf8a307ad", null ],
|
||||
[ "mi_option_large_os_pages", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca4192d491200d0055df0554d4cf65054e", null ],
|
||||
[ "mi_option_reserve_huge_os_pages", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884caca7ed041be3b0b9d0b82432c7bf41af2", null ],
|
||||
[ "mi_option_segment_cache", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca2ecbe7ef32f5c84de3739aa4f0b805a1", null ],
|
||||
[ "mi_option_page_reset", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cada854dd272c66342f18a93ee254a2968", null ],
|
||||
[ "mi_option_cache_reset", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cac2157a0cb79cd996c1db7d9f6a090c07", null ],
|
||||
[ "mi_option_reset_decommits", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cac81ee965b130fa81238913a3c239d536", null ],
|
||||
[ "mi_option_reset_discards", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cab3a837b5ceee250e14e051dbee2a441b", null ],
|
||||
[ "mi_option_eager_commit_delay", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca17a190c25be381142d87e0468c4c068c", null ],
|
||||
[ "mi_option_segment_reset", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cafb121d30d87591850d5410ccc3a95c6d", null ],
|
||||
[ "mi_option_os_tag", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca4b74ae2a69e445de6c2361b73c1d14bf", null ],
|
||||
[ "_mi_option_last", "group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca5b4357b74be0d87568036c32eb1a2e4a", null ]
|
||||
] ],
|
||||
[ "mi_option_enable", "group__options.html#ga6d45a20a3131f18bc351b69763b38ce4", null ],
|
||||
|
@ -115,6 +115,7 @@ Functions</h2></td></tr>
|
||||
<tr class="memitem:ga06d07cf357bbac5c73ba5d0c0c421e17"><td class="memItemLeft" align="right" valign="top">size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__posix.html#ga06d07cf357bbac5c73ba5d0c0c421e17">mi_malloc_usable_size</a> (const void *p)</td></tr>
|
||||
<tr class="separator:ga06d07cf357bbac5c73ba5d0c0c421e17"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga705dc7a64bffacfeeb0141501a5c35d7"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__posix.html#ga705dc7a64bffacfeeb0141501a5c35d7">mi_cfree</a> (void *p)</td></tr>
|
||||
<tr class="memdesc:ga705dc7a64bffacfeeb0141501a5c35d7"><td class="mdescLeft"> </td><td class="mdescRight">Just as <code>free</code> but also checks if the pointer <code>p</code> belongs to our heap. <a href="#ga705dc7a64bffacfeeb0141501a5c35d7">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga705dc7a64bffacfeeb0141501a5c35d7"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:gacff84f226ba9feb2031b8992e5579447"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="group__posix.html#gacff84f226ba9feb2031b8992e5579447">mi_posix_memalign</a> (void **p, size_t alignment, size_t size)</td></tr>
|
||||
<tr class="separator:gacff84f226ba9feb2031b8992e5579447"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
@ -231,6 +232,8 @@ Functions</h2></td></tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Just as <code>free</code> but also checks if the pointer <code>p</code> belongs to our heap. </p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga0d28d5cf61e6bfbb18c63092939fe5c9"></a>
|
||||
|
@ -140,6 +140,9 @@ Macros</h2></td></tr>
|
||||
<tr class="memitem:gaf213d5422ec35e7f6caad827c79bc948"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="group__typed.html#gaf213d5422ec35e7f6caad827c79bc948">mi_heap_reallocn_tp</a>(hp, p, tp, count)</td></tr>
|
||||
<tr class="memdesc:gaf213d5422ec35e7f6caad827c79bc948"><td class="mdescLeft"> </td><td class="mdescRight">Re-allocate to <em>count</em> blocks of type <em>tp</em> in a heap <em>hp</em>. <a href="#gaf213d5422ec35e7f6caad827c79bc948">More...</a><br /></td></tr>
|
||||
<tr class="separator:gaf213d5422ec35e7f6caad827c79bc948"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ga3e50a1600958fcaf1a7f3560c9174f9e"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="group__typed.html#ga3e50a1600958fcaf1a7f3560c9174f9e">mi_heap_recalloc_tp</a>(hp, p, tp, count)</td></tr>
|
||||
<tr class="memdesc:ga3e50a1600958fcaf1a7f3560c9174f9e"><td class="mdescLeft"> </td><td class="mdescRight">Re-allocate to <em>count</em> zero initialized blocks of type <em>tp</em> in a heap <em>hp</em>. <a href="#ga3e50a1600958fcaf1a7f3560c9174f9e">More...</a><br /></td></tr>
|
||||
<tr class="separator:ga3e50a1600958fcaf1a7f3560c9174f9e"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
</table>
|
||||
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
||||
<p>Typed allocation macros. </p>
|
||||
@ -316,6 +319,48 @@ Macros</h2></td></tr>
|
||||
|
||||
<p>Re-allocate to <em>count</em> blocks of type <em>tp</em> in a heap <em>hp</em>. </p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ga3e50a1600958fcaf1a7f3560c9174f9e"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ga3e50a1600958fcaf1a7f3560c9174f9e">◆ </a></span>mi_heap_recalloc_tp</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">#define mi_heap_recalloc_tp</td>
|
||||
<td>(</td>
|
||||
<td class="paramtype"> </td>
|
||||
<td class="paramname">hp, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype"> </td>
|
||||
<td class="paramname">p, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype"> </td>
|
||||
<td class="paramname">tp, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype"> </td>
|
||||
<td class="paramname">count </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>)</td>
|
||||
<td></td><td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Re-allocate to <em>count</em> zero initialized blocks of type <em>tp</em> in a heap <em>hp</em>. </p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="gad6e87e86e994aa14416ae9b5d4c188fe"></a>
|
||||
|
@ -5,6 +5,7 @@ var group__typed =
|
||||
[ "mi_heap_malloc_tp", "group__typed.html#ga653bcb24ac495bc19940ecd6898f9cd7", null ],
|
||||
[ "mi_heap_mallocn_tp", "group__typed.html#ga6b75cb9c4b9c647661d0924552dc6e83", null ],
|
||||
[ "mi_heap_reallocn_tp", "group__typed.html#gaf213d5422ec35e7f6caad827c79bc948", null ],
|
||||
[ "mi_heap_recalloc_tp", "group__typed.html#ga3e50a1600958fcaf1a7f3560c9174f9e", null ],
|
||||
[ "mi_heap_zalloc_tp", "group__typed.html#gad6e87e86e994aa14416ae9b5d4c188fe", null ],
|
||||
[ "mi_malloc_tp", "group__typed.html#ga0619a62c5fd886f1016030abe91f0557", null ],
|
||||
[ "mi_mallocn_tp", "group__typed.html#gae5cb6e0fafc9f23169c5622e077afe8b", null ],
|
||||
|
@ -110,14 +110,15 @@ $(document).ready(function(){initNavTree('index.html','');});
|
||||
<li><b>eager page reset</b>: when a "page" becomes empty (with increased chance due to free list sharding) the memory is marked to the OS as unused ("reset" or "purged") reducing (real) memory pressure and fragmentation, especially in long running programs.</li>
|
||||
<li><b>secure</b>: <em>mimalloc</em> can be build in secure mode, adding guard pages, randomized allocation, encrypted free lists, etc. to protect against various heap vulnerabilities. The performance penalty is only around 3% on average over our benchmarks.</li>
|
||||
<li><b>first-class heaps</b>: efficiently create and use multiple heaps to allocate across different regions. A heap can be destroyed at once instead of deallocating each object separately.</li>
|
||||
<li><b>bounded</b>: it does not suffer from <em>blowup</em> [1], has bounded worst-case allocation times (<em>wcat</em>), bounded space overhead (~0.2% meta-data, with at most 16.7% waste in allocation sizes), and has no internal points of contention using only atomic operations.</li>
|
||||
<li><b>bounded</b>: it does not suffer from <em>blowup</em> [1], has bounded worst-case allocation times (<em>wcat</em>), bounded space overhead (~0.2% meta-data, with at most 12.5% waste in allocation sizes), and has no internal points of contention using only atomic operations.</li>
|
||||
<li><b>fast</b>: In our benchmarks (see <a href="#performance">below</a>), <em>mimalloc</em> always outperforms all other leading allocators (<em>jemalloc</em>, <em>tcmalloc</em>, <em>Hoard</em>, etc), and usually uses less memory (up to 25% more in the worst case). A nice property is that it does consistently well over a wide range of benchmarks.</li>
|
||||
</ul>
|
||||
<p>You can read more on the design of <em>mimalloc</em> in the upcoming technical report which also has detailed benchmark results.</p>
|
||||
<p>You can read more on the design of <em>mimalloc</em> in the <a href="https://www.microsoft.com/en-us/research/publication/mimalloc-free-list-sharding-in-action">technical report</a> which also has detailed benchmark results.</p>
|
||||
<p>Further information:</p>
|
||||
<ul>
|
||||
<li><a class="el" href="build.html">Building</a></li>
|
||||
<li><a class="el" href="using.html">Using the library</a></li>
|
||||
<li><a class="el" href="environment.html">Environment Options</a></li>
|
||||
<li><a class="el" href="overrides.html">Overriding Malloc</a></li>
|
||||
<li><a class="el" href="bench.html">Performance</a></li>
|
||||
<li><a class="el" href="group__malloc.html">Basic Allocation</a></li>
|
||||
|
File diff suppressed because one or more lines are too long
@ -108,10 +108,11 @@ $(document).ready(function(){initNavTree('modules.html','');});
|
||||
<tr id="row_1_"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="group__extended.html" target="_self">Extended Functions</a></td><td class="desc">Extended functionality </td></tr>
|
||||
<tr id="row_2_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="group__aligned.html" target="_self">Aligned Allocation</a></td><td class="desc">Allocating aligned memory blocks </td></tr>
|
||||
<tr id="row_3_"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="group__heap.html" target="_self">Heap Allocation</a></td><td class="desc">First-class heaps that can be destroyed in one go </td></tr>
|
||||
<tr id="row_4_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="group__typed.html" target="_self">Typed Macros</a></td><td class="desc">Typed allocation macros </td></tr>
|
||||
<tr id="row_5_"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="group__analysis.html" target="_self">Heap Introspection</a></td><td class="desc">Inspect the heap at runtime </td></tr>
|
||||
<tr id="row_6_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="group__options.html" target="_self">Runtime Options</a></td><td class="desc">Set runtime behavior </td></tr>
|
||||
<tr id="row_7_"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="group__posix.html" target="_self">Posix</a></td><td class="desc"><code>mi_</code> prefixed implementations of various Posix, Unix, and C++ allocation functions </td></tr>
|
||||
<tr id="row_4_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="group__zeroinit.html" target="_self">Zero initialized re-allocation</a></td><td class="desc">The zero-initialized re-allocations are only valid on memory that was originally allocated with zero initialization too </td></tr>
|
||||
<tr id="row_5_"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="group__typed.html" target="_self">Typed Macros</a></td><td class="desc">Typed allocation macros </td></tr>
|
||||
<tr id="row_6_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="group__analysis.html" target="_self">Heap Introspection</a></td><td class="desc">Inspect the heap at runtime </td></tr>
|
||||
<tr id="row_7_"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="group__options.html" target="_self">Runtime Options</a></td><td class="desc">Set runtime behavior </td></tr>
|
||||
<tr id="row_8_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="group__posix.html" target="_self">Posix</a></td><td class="desc"><code>mi_</code> prefixed implementations of various Posix, Unix, and C++ allocation functions </td></tr>
|
||||
</table>
|
||||
</div><!-- directory -->
|
||||
</div><!-- contents -->
|
||||
|
@ -4,6 +4,7 @@ var modules =
|
||||
[ "Extended Functions", "group__extended.html", "group__extended" ],
|
||||
[ "Aligned Allocation", "group__aligned.html", "group__aligned" ],
|
||||
[ "Heap Allocation", "group__heap.html", "group__heap" ],
|
||||
[ "Zero initialized re-allocation", "group__zeroinit.html", "group__zeroinit" ],
|
||||
[ "Typed Macros", "group__typed.html", "group__typed" ],
|
||||
[ "Heap Introspection", "group__analysis.html", "group__analysis" ],
|
||||
[ "Runtime Options", "group__options.html", "group__options" ],
|
||||
|
@ -26,6 +26,7 @@ var NAVTREE =
|
||||
[ "mi-malloc", "index.html", [
|
||||
[ "Building", "build.html", null ],
|
||||
[ "Using the library", "using.html", null ],
|
||||
[ "Environment Options", "environment.html", null ],
|
||||
[ "Overriding Malloc", "overrides.html", null ],
|
||||
[ "Performance", "bench.html", null ],
|
||||
[ "Modules", "modules.html", "modules" ],
|
||||
|
@ -1,138 +1,163 @@
|
||||
var NAVTREEINDEX0 =
|
||||
{
|
||||
"annotated.html":[5,0],
|
||||
"bench.html":[3],
|
||||
"annotated.html":[6,0],
|
||||
"bench.html":[4],
|
||||
"build.html":[0],
|
||||
"classes.html":[5,1],
|
||||
"functions.html":[5,2,0],
|
||||
"functions_vars.html":[5,2,1],
|
||||
"group__aligned.html":[4,2],
|
||||
"group__aligned.html#ga08647c4593f3b2eef24a919a73eba3a3":[4,2,1],
|
||||
"group__aligned.html#ga0cadbcf5b89a7b6fb171bc8df8734819":[4,2,6],
|
||||
"group__aligned.html#ga4028d1cf4aa4c87c880747044a8322ae":[4,2,4],
|
||||
"group__aligned.html#ga53dddb4724042a90315b94bc268fb4c9":[4,2,0],
|
||||
"group__aligned.html#ga5850da130c936bd77db039dcfbc8295d":[4,2,3],
|
||||
"group__aligned.html#ga5f8c2353766db522565e642fafd8a3f8":[4,2,7],
|
||||
"group__aligned.html#ga68930196751fa2cca9e1fd0d71bade56":[4,2,2],
|
||||
"group__aligned.html#gaf66a9ae6c6f08bd6be6fb6ea771faffb":[4,2,5],
|
||||
"group__analysis.html":[4,5],
|
||||
"group__analysis.html#a332a6c14d736a99699d5453a1cb04b41":[4,5,0,0],
|
||||
"group__analysis.html#ab47526df656d8837ec3e97f11b83f835":[4,5,0,2],
|
||||
"group__analysis.html#ab820302c5cd0df133eb8e51650a008b4":[4,5,0,4],
|
||||
"group__analysis.html#ae0085e6e1cf059a4eb7767e30e9991b8":[4,5,0,1],
|
||||
"group__analysis.html#ae848a3e6840414891035423948ca0383":[4,5,0,3],
|
||||
"group__analysis.html#ga0d67c1789faaa15ff366c024fcaf6377":[4,5,3],
|
||||
"group__analysis.html#ga628c237489c2679af84a4d0d143b3dd5":[4,5,2],
|
||||
"group__analysis.html#ga70c46687dc6e9dc98b232b02646f8bed":[4,5,5],
|
||||
"group__analysis.html#gaa862aa8ed8d57d84cae41fc1022d71af":[4,5,4],
|
||||
"group__analysis.html#gadfa01e2900f0e5d515ad5506b26f6d65":[4,5,1],
|
||||
"group__analysis.html#structmi__heap__area__t":[4,5,0],
|
||||
"group__extended.html":[4,1],
|
||||
"group__extended.html#ga089c859d9eddc5f9b4bd946cd53cebee":[4,1,11],
|
||||
"group__extended.html#ga1ea64283508718d9d645c38efc2f4305":[4,1,0],
|
||||
"group__extended.html#ga220f29f40a44404b0061c15bc1c31152":[4,1,12],
|
||||
"group__extended.html#ga22213691c3ce5ab4d91b24aff1023529":[4,1,1],
|
||||
"group__extended.html#ga24dc9cc6fca8daa2aa30aa8025467ce2":[4,1,5],
|
||||
"group__extended.html#ga421430e2226d7d468529cec457396756":[4,1,2],
|
||||
"group__extended.html#ga490826cbd7c494acc9fe69be23f018ac":[4,1,10],
|
||||
"group__extended.html#ga6bb821ca1b664b452112c0e17b15fcf1":[4,1,6],
|
||||
"group__extended.html#ga7136c2e55cb22c98ecf95d08d6debb99":[4,1,4],
|
||||
"group__extended.html#ga9398517f01a1ec971244aa0db084ea46":[4,1,9],
|
||||
"group__extended.html#ga9883b8a059aed7eb0888a01ec1461161":[4,1,7],
|
||||
"group__extended.html#gac057927cd06c854b45fe7847e921bd47":[4,1,3],
|
||||
"group__extended.html#gac0f4849256aaf677f334690952c6ebbd":[4,1,8],
|
||||
"group__heap.html":[4,3],
|
||||
"group__heap.html#ga00e95ba1e01acac3cfd95bb7a357a6f0":[4,3,18],
|
||||
"group__heap.html#ga08ca6419a5c057a4d965868998eef487":[4,3,3],
|
||||
"group__heap.html#ga139d6b09dbf50c3c2523d0f4d1cfdeb5":[4,3,20],
|
||||
"group__heap.html#ga23acd7680fb0976dde3783254c6c874b":[4,3,10],
|
||||
"group__heap.html#ga2ab1af8d438819b55319c7ef51d1e409":[4,3,4],
|
||||
"group__heap.html#ga34a47cde5a5b38c29f1aa3c5e76943c2":[4,3,0],
|
||||
"group__heap.html#ga45fb43a62776fbebbdf1edd99b527954":[4,3,24],
|
||||
"group__heap.html#ga4a21070eb4e7cce018133c8d5f4b0527":[4,3,16],
|
||||
"group__heap.html#ga4af03a6e2b93fae77424d93f889705c3":[4,3,2],
|
||||
"group__heap.html#ga5d03fbe062ffcf38f0f417fd968357fc":[4,3,6],
|
||||
"group__heap.html#ga766f672ba56f2fbfeb9d9dbb0b7f6b11":[4,3,12],
|
||||
"group__heap.html#ga851da6c43fe0b71c1376cee8aef90db0":[4,3,11],
|
||||
"group__heap.html#ga8db4cbb87314a989a9a187464d6b5e05":[4,3,7],
|
||||
"group__heap.html#ga8e3dbd46650dd26573cf307a2c8f1f5a":[4,3,21],
|
||||
"group__heap.html#ga903104592c8ed53417a3762da6241133":[4,3,22],
|
||||
"group__heap.html#ga9cbed01e42c0647907295de92c3fa296":[4,3,8],
|
||||
"group__heap.html#ga9f9c0844edb9717f4feacd79116b8e0d":[4,3,5],
|
||||
"group__heap.html#gaa450a59c6c7ae5fdbd1c2b80a8329ef0":[4,3,23],
|
||||
"group__heap.html#gaa6702b3c48e9e53e50e81b36f5011d55":[4,3,1],
|
||||
"group__heap.html#gaaef3395f66be48f37bdc8322509c5d81":[4,3,13],
|
||||
"group__heap.html#gab5b87e1805306f70df38789fcfcf6653":[4,3,9],
|
||||
"group__heap.html#gab8631ec88c8d26641b68b5d25dcd4422":[4,3,19],
|
||||
"group__heap.html#gac74e94ad9b0c9b57c1c4d88b8825b7a8":[4,3,17],
|
||||
"group__heap.html#gaf96c788a1bf553fe2d371de9365e047c":[4,3,15],
|
||||
"group__heap.html#gafc603b696bd14cae6da28658f950d98c":[4,3,14],
|
||||
"group__malloc.html":[4,0],
|
||||
"group__malloc.html#ga08cec32dd5bbe7da91c78d19f1b5bebe":[4,0,8],
|
||||
"group__malloc.html#ga0b05e2bf0f73e7401ae08597ff782ac6":[4,0,4],
|
||||
"group__malloc.html#ga23a0fbb452b5dce8e31fab1a1958cacc":[4,0,9],
|
||||
"group__malloc.html#ga3406e8b168bc74c8637b11571a6da83a":[4,0,3],
|
||||
"group__malloc.html#ga61d57b4144ba24fba5c1e9b956d13853":[4,0,7],
|
||||
"group__malloc.html#ga97fedb4f7107c592fd7f0f0a8949a57d":[4,0,0],
|
||||
"group__malloc.html#gaaabf971c2571891433477e2d21a35266":[4,0,11],
|
||||
"group__malloc.html#gaaee66a1d483c3e28f585525fb96707e4":[4,0,1],
|
||||
"group__malloc.html#gac7cffe13f1f458ed16789488bf92b9b2":[4,0,10],
|
||||
"group__malloc.html#gaf11eb497da57bdfb2de65eb191c69db6":[4,0,5],
|
||||
"group__malloc.html#gaf2c7b89c327d1f60f59e68b9ea644d95":[4,0,2],
|
||||
"group__malloc.html#gafdd9d8bb2986e668ba9884f28af38000":[4,0,12],
|
||||
"group__malloc.html#gafe68ac7c5e24a65cd55c9d6b152211a0":[4,0,6],
|
||||
"group__options.html":[4,6],
|
||||
"group__options.html#ga37988264b915a7db92530cc02d5494cb":[4,6,2],
|
||||
"group__options.html#ga6d45a20a3131f18bc351b69763b38ce4":[4,6,1],
|
||||
"group__options.html#ga7e8af195cc81d3fa64ccf2662caa565a":[4,6,4],
|
||||
"group__options.html#ga7ef623e440e6e5545cb08c94e71e4b90":[4,6,6],
|
||||
"group__options.html#gacebe3f6d91b4a50b54eb84e2a1da1b30":[4,6,3],
|
||||
"group__options.html#gaf84921c32375e25754dc2ee6a911fa60":[4,6,5],
|
||||
"group__options.html#gafebf7ed116adb38ae5218bc3ce06884c":[4,6,0],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca083ee20765063fc6d727e11d33cf378f":[4,6,0,3],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca0957ef73b2550764b4840edf48422fda":[4,6,0,0],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca1e8de72c93da7ff22d91e1e27b52ac2b":[4,6,0,4],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca32ce97ece29f69e82579679cf8a307ad":[4,6,0,5],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca4192d491200d0055df0554d4cf65054e":[4,6,0,6],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca5b4357b74be0d87568036c32eb1a2e4a":[4,6,0,11],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca7c8b7bf5281c581bad64f5daa6442777":[4,6,0,2],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cab3a837b5ceee250e14e051dbee2a441b":[4,6,0,10],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cac2157a0cb79cd996c1db7d9f6a090c07":[4,6,0,8],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cac81ee965b130fa81238913a3c239d536":[4,6,0,9],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cada854dd272c66342f18a93ee254a2968":[4,6,0,7],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cafbf4822e5c00732c5984b32a032837f0":[4,6,0,1],
|
||||
"group__posix.html":[4,7],
|
||||
"group__posix.html#ga06d07cf357bbac5c73ba5d0c0c421e17":[4,7,7],
|
||||
"group__posix.html#ga0d28d5cf61e6bfbb18c63092939fe5c9":[4,7,3],
|
||||
"group__posix.html#ga1326d2e4388630b5f81ca7206318b8e5":[4,7,1],
|
||||
"group__posix.html#ga4531c9e775bb3ae12db57c1ba8a5d7de":[4,7,6],
|
||||
"group__posix.html#ga48fad8648a2f1dab9c87ea9448a52088":[4,7,15],
|
||||
"group__posix.html#ga705dc7a64bffacfeeb0141501a5c35d7":[4,7,2],
|
||||
"group__posix.html#ga72e9d7ffb5fe94d69bc722c8506e27bc":[4,7,5],
|
||||
"group__posix.html#ga73baaf5951f5165ba0763d0c06b6a93b":[4,7,16],
|
||||
"group__posix.html#gaab7fa71ea93b96873f5d9883db57d40e":[4,7,8],
|
||||
"group__posix.html#gaad048a9fce3d02c5909cd05c6ec24545":[4,7,9],
|
||||
"group__posix.html#gab5e29558926d934c3f1cae8c815f942c":[4,7,11],
|
||||
"group__posix.html#gacff84f226ba9feb2031b8992e5579447":[4,7,13],
|
||||
"group__posix.html#gad5a69c8fea96aa2b7a7c818c2130090a":[4,7,0],
|
||||
"group__posix.html#gae01389eedab8d67341ff52e2aad80ebb":[4,7,4],
|
||||
"group__posix.html#gaeaded64eda71ed6b1d569d3e723abc4a":[4,7,12],
|
||||
"group__posix.html#gaeb325c39b887d3b90d85d1eb1712fb1e":[4,7,14],
|
||||
"group__posix.html#gaef2c2bdb4f70857902d3c8903ac095f3":[4,7,10],
|
||||
"group__typed.html":[4,4],
|
||||
"group__typed.html#ga0619a62c5fd886f1016030abe91f0557":[4,4,6],
|
||||
"group__typed.html#ga1158b49a55dfa81f58a4426a7578f523":[4,4,8],
|
||||
"group__typed.html#ga4e5d1f1707c90e5f55e023ac5f45fe74":[4,4,1],
|
||||
"group__typed.html#ga653bcb24ac495bc19940ecd6898f9cd7":[4,4,2],
|
||||
"group__typed.html#ga6b75cb9c4b9c647661d0924552dc6e83":[4,4,3],
|
||||
"group__typed.html#gac77a61bdaf680a803785fe307820b48c":[4,4,9],
|
||||
"group__typed.html#gad6e87e86e994aa14416ae9b5d4c188fe":[4,4,5],
|
||||
"group__typed.html#gae5cb6e0fafc9f23169c5622e077afe8b":[4,4,7],
|
||||
"group__typed.html#gae80c47c9d4cab10961fff1a8ac98fc07":[4,4,0],
|
||||
"group__typed.html#gaf213d5422ec35e7f6caad827c79bc948":[4,4,4],
|
||||
"classes.html":[6,1],
|
||||
"environment.html":[2],
|
||||
"functions.html":[6,2,0],
|
||||
"functions_vars.html":[6,2,1],
|
||||
"group__aligned.html":[5,2],
|
||||
"group__aligned.html#ga08647c4593f3b2eef24a919a73eba3a3":[5,2,1],
|
||||
"group__aligned.html#ga0cadbcf5b89a7b6fb171bc8df8734819":[5,2,6],
|
||||
"group__aligned.html#ga4028d1cf4aa4c87c880747044a8322ae":[5,2,4],
|
||||
"group__aligned.html#ga53dddb4724042a90315b94bc268fb4c9":[5,2,0],
|
||||
"group__aligned.html#ga5850da130c936bd77db039dcfbc8295d":[5,2,3],
|
||||
"group__aligned.html#ga5f8c2353766db522565e642fafd8a3f8":[5,2,7],
|
||||
"group__aligned.html#ga68930196751fa2cca9e1fd0d71bade56":[5,2,2],
|
||||
"group__aligned.html#gaf66a9ae6c6f08bd6be6fb6ea771faffb":[5,2,5],
|
||||
"group__analysis.html":[5,6],
|
||||
"group__analysis.html#a332a6c14d736a99699d5453a1cb04b41":[5,6,0,0],
|
||||
"group__analysis.html#ab47526df656d8837ec3e97f11b83f835":[5,6,0,2],
|
||||
"group__analysis.html#ab820302c5cd0df133eb8e51650a008b4":[5,6,0,4],
|
||||
"group__analysis.html#ae0085e6e1cf059a4eb7767e30e9991b8":[5,6,0,1],
|
||||
"group__analysis.html#ae848a3e6840414891035423948ca0383":[5,6,0,3],
|
||||
"group__analysis.html#ga0d67c1789faaa15ff366c024fcaf6377":[5,6,3],
|
||||
"group__analysis.html#ga628c237489c2679af84a4d0d143b3dd5":[5,6,2],
|
||||
"group__analysis.html#ga70c46687dc6e9dc98b232b02646f8bed":[5,6,5],
|
||||
"group__analysis.html#gaa862aa8ed8d57d84cae41fc1022d71af":[5,6,4],
|
||||
"group__analysis.html#gadfa01e2900f0e5d515ad5506b26f6d65":[5,6,1],
|
||||
"group__analysis.html#structmi__heap__area__t":[5,6,0],
|
||||
"group__extended.html":[5,1],
|
||||
"group__extended.html#ga089c859d9eddc5f9b4bd946cd53cebee":[5,1,17],
|
||||
"group__extended.html#ga0ae4581e85453456a0d658b2b98bf7bf":[5,1,14],
|
||||
"group__extended.html#ga1ea64283508718d9d645c38efc2f4305":[5,1,0],
|
||||
"group__extended.html#ga220f29f40a44404b0061c15bc1c31152":[5,1,18],
|
||||
"group__extended.html#ga22213691c3ce5ab4d91b24aff1023529":[5,1,1],
|
||||
"group__extended.html#ga24dc9cc6fca8daa2aa30aa8025467ce2":[5,1,8],
|
||||
"group__extended.html#ga2664f36a2dd557741c429cb799f04641":[5,1,10],
|
||||
"group__extended.html#ga2bed6d40b74591a67f81daea4b4a246f":[5,1,2],
|
||||
"group__extended.html#ga3bb8468b8cfcc6e2a61d98aee85c5f99":[5,1,13],
|
||||
"group__extended.html#ga421430e2226d7d468529cec457396756":[5,1,3],
|
||||
"group__extended.html#ga489670a15d1a257ab4639e645ee4612a":[5,1,16],
|
||||
"group__extended.html#ga5f071b10d4df1c3658e04e7fd67a94e6":[5,1,5],
|
||||
"group__extended.html#ga7136c2e55cb22c98ecf95d08d6debb99":[5,1,7],
|
||||
"group__extended.html#ga84a0c8b401e42eb5b1bce156852f44c5":[5,1,9],
|
||||
"group__extended.html#ga854b1de8cb067c7316286c28b2fcd3d1":[5,1,11],
|
||||
"group__extended.html#ga8ca07ccff283956d71f48272f4fd5c01":[5,1,12],
|
||||
"group__extended.html#gaad25050b19f30cd79397b227e0157a3f":[5,1,6],
|
||||
"group__extended.html#gac057927cd06c854b45fe7847e921bd47":[5,1,4],
|
||||
"group__extended.html#gaf8e73efc2cbca9ebfdfb166983a04c17":[5,1,15],
|
||||
"group__heap.html":[5,3],
|
||||
"group__heap.html#ga00e95ba1e01acac3cfd95bb7a357a6f0":[5,3,20],
|
||||
"group__heap.html#ga08ca6419a5c057a4d965868998eef487":[5,3,3],
|
||||
"group__heap.html#ga139d6b09dbf50c3c2523d0f4d1cfdeb5":[5,3,22],
|
||||
"group__heap.html#ga23acd7680fb0976dde3783254c6c874b":[5,3,11],
|
||||
"group__heap.html#ga2ab1af8d438819b55319c7ef51d1e409":[5,3,5],
|
||||
"group__heap.html#ga34a47cde5a5b38c29f1aa3c5e76943c2":[5,3,0],
|
||||
"group__heap.html#ga45fb43a62776fbebbdf1edd99b527954":[5,3,26],
|
||||
"group__heap.html#ga4a21070eb4e7cce018133c8d5f4b0527":[5,3,18],
|
||||
"group__heap.html#ga4af03a6e2b93fae77424d93f889705c3":[5,3,2],
|
||||
"group__heap.html#ga5d03fbe062ffcf38f0f417fd968357fc":[5,3,7],
|
||||
"group__heap.html#ga766f672ba56f2fbfeb9d9dbb0b7f6b11":[5,3,14],
|
||||
"group__heap.html#ga7922f7495cde30b1984d0e6072419298":[5,3,4],
|
||||
"group__heap.html#ga851da6c43fe0b71c1376cee8aef90db0":[5,3,13],
|
||||
"group__heap.html#ga8db4cbb87314a989a9a187464d6b5e05":[5,3,8],
|
||||
"group__heap.html#ga8e3dbd46650dd26573cf307a2c8f1f5a":[5,3,23],
|
||||
"group__heap.html#ga903104592c8ed53417a3762da6241133":[5,3,24],
|
||||
"group__heap.html#ga9cbed01e42c0647907295de92c3fa296":[5,3,9],
|
||||
"group__heap.html#ga9f9c0844edb9717f4feacd79116b8e0d":[5,3,6],
|
||||
"group__heap.html#gaa1a1c7a1f4da6826b5a25b70ef878368":[5,3,12],
|
||||
"group__heap.html#gaa450a59c6c7ae5fdbd1c2b80a8329ef0":[5,3,25],
|
||||
"group__heap.html#gaa6702b3c48e9e53e50e81b36f5011d55":[5,3,1],
|
||||
"group__heap.html#gaaef3395f66be48f37bdc8322509c5d81":[5,3,15],
|
||||
"group__heap.html#gab5b87e1805306f70df38789fcfcf6653":[5,3,10],
|
||||
"group__heap.html#gab8631ec88c8d26641b68b5d25dcd4422":[5,3,21],
|
||||
"group__heap.html#gac74e94ad9b0c9b57c1c4d88b8825b7a8":[5,3,19],
|
||||
"group__heap.html#gaf96c788a1bf553fe2d371de9365e047c":[5,3,17],
|
||||
"group__heap.html#gafc603b696bd14cae6da28658f950d98c":[5,3,16],
|
||||
"group__malloc.html":[5,0],
|
||||
"group__malloc.html#ga08cec32dd5bbe7da91c78d19f1b5bebe":[5,0,8],
|
||||
"group__malloc.html#ga0b05e2bf0f73e7401ae08597ff782ac6":[5,0,4],
|
||||
"group__malloc.html#ga23a0fbb452b5dce8e31fab1a1958cacc":[5,0,9],
|
||||
"group__malloc.html#ga3406e8b168bc74c8637b11571a6da83a":[5,0,3],
|
||||
"group__malloc.html#ga61d57b4144ba24fba5c1e9b956d13853":[5,0,7],
|
||||
"group__malloc.html#ga97fedb4f7107c592fd7f0f0a8949a57d":[5,0,0],
|
||||
"group__malloc.html#gaaabf971c2571891433477e2d21a35266":[5,0,11],
|
||||
"group__malloc.html#gaaee66a1d483c3e28f585525fb96707e4":[5,0,1],
|
||||
"group__malloc.html#gac7cffe13f1f458ed16789488bf92b9b2":[5,0,10],
|
||||
"group__malloc.html#gaf11eb497da57bdfb2de65eb191c69db6":[5,0,5],
|
||||
"group__malloc.html#gaf2c7b89c327d1f60f59e68b9ea644d95":[5,0,2],
|
||||
"group__malloc.html#gafdd9d8bb2986e668ba9884f28af38000":[5,0,12],
|
||||
"group__malloc.html#gafe68ac7c5e24a65cd55c9d6b152211a0":[5,0,6],
|
||||
"group__options.html":[5,7],
|
||||
"group__options.html#ga37988264b915a7db92530cc02d5494cb":[5,7,2],
|
||||
"group__options.html#ga6d45a20a3131f18bc351b69763b38ce4":[5,7,1],
|
||||
"group__options.html#ga7e8af195cc81d3fa64ccf2662caa565a":[5,7,4],
|
||||
"group__options.html#ga7ef623e440e6e5545cb08c94e71e4b90":[5,7,6],
|
||||
"group__options.html#gacebe3f6d91b4a50b54eb84e2a1da1b30":[5,7,3],
|
||||
"group__options.html#gaf84921c32375e25754dc2ee6a911fa60":[5,7,5],
|
||||
"group__options.html#gafebf7ed116adb38ae5218bc3ce06884c":[5,7,0],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca0957ef73b2550764b4840edf48422fda":[5,7,0,0],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca17a190c25be381142d87e0468c4c068c":[5,7,0,11],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca1e8de72c93da7ff22d91e1e27b52ac2b":[5,7,0,3],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca2ecbe7ef32f5c84de3739aa4f0b805a1":[5,7,0,7],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca32ce97ece29f69e82579679cf8a307ad":[5,7,0,4],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca4192d491200d0055df0554d4cf65054e":[5,7,0,5],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca4b74ae2a69e445de6c2361b73c1d14bf":[5,7,0,13],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca5b4357b74be0d87568036c32eb1a2e4a":[5,7,0,14],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca7c8b7bf5281c581bad64f5daa6442777":[5,7,0,2],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cac2157a0cb79cd996c1db7d9f6a090c07":[5,7,0,9],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cac81ee965b130fa81238913a3c239d536":[5,7,0,10],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884caca7ed041be3b0b9d0b82432c7bf41af2":[5,7,0,6],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cada854dd272c66342f18a93ee254a2968":[5,7,0,8],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cafb121d30d87591850d5410ccc3a95c6d":[5,7,0,12],
|
||||
"group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cafbf4822e5c00732c5984b32a032837f0":[5,7,0,1],
|
||||
"group__posix.html":[5,8],
|
||||
"group__posix.html#ga06d07cf357bbac5c73ba5d0c0c421e17":[5,8,7],
|
||||
"group__posix.html#ga0d28d5cf61e6bfbb18c63092939fe5c9":[5,8,3],
|
||||
"group__posix.html#ga1326d2e4388630b5f81ca7206318b8e5":[5,8,1],
|
||||
"group__posix.html#ga4531c9e775bb3ae12db57c1ba8a5d7de":[5,8,6],
|
||||
"group__posix.html#ga48fad8648a2f1dab9c87ea9448a52088":[5,8,15],
|
||||
"group__posix.html#ga705dc7a64bffacfeeb0141501a5c35d7":[5,8,2],
|
||||
"group__posix.html#ga72e9d7ffb5fe94d69bc722c8506e27bc":[5,8,5],
|
||||
"group__posix.html#ga73baaf5951f5165ba0763d0c06b6a93b":[5,8,16],
|
||||
"group__posix.html#gaab7fa71ea93b96873f5d9883db57d40e":[5,8,8],
|
||||
"group__posix.html#gaad048a9fce3d02c5909cd05c6ec24545":[5,8,9],
|
||||
"group__posix.html#gab5e29558926d934c3f1cae8c815f942c":[5,8,11],
|
||||
"group__posix.html#gacff84f226ba9feb2031b8992e5579447":[5,8,13],
|
||||
"group__posix.html#gad5a69c8fea96aa2b7a7c818c2130090a":[5,8,0],
|
||||
"group__posix.html#gae01389eedab8d67341ff52e2aad80ebb":[5,8,4],
|
||||
"group__posix.html#gaeaded64eda71ed6b1d569d3e723abc4a":[5,8,12],
|
||||
"group__posix.html#gaeb325c39b887d3b90d85d1eb1712fb1e":[5,8,14],
|
||||
"group__posix.html#gaef2c2bdb4f70857902d3c8903ac095f3":[5,8,10],
|
||||
"group__typed.html":[5,5],
|
||||
"group__typed.html#ga0619a62c5fd886f1016030abe91f0557":[5,5,7],
|
||||
"group__typed.html#ga1158b49a55dfa81f58a4426a7578f523":[5,5,9],
|
||||
"group__typed.html#ga3e50a1600958fcaf1a7f3560c9174f9e":[5,5,5],
|
||||
"group__typed.html#ga4e5d1f1707c90e5f55e023ac5f45fe74":[5,5,1],
|
||||
"group__typed.html#ga653bcb24ac495bc19940ecd6898f9cd7":[5,5,2],
|
||||
"group__typed.html#ga6b75cb9c4b9c647661d0924552dc6e83":[5,5,3],
|
||||
"group__typed.html#gac77a61bdaf680a803785fe307820b48c":[5,5,10],
|
||||
"group__typed.html#gad6e87e86e994aa14416ae9b5d4c188fe":[5,5,6],
|
||||
"group__typed.html#gae5cb6e0fafc9f23169c5622e077afe8b":[5,5,8],
|
||||
"group__typed.html#gae80c47c9d4cab10961fff1a8ac98fc07":[5,5,0],
|
||||
"group__typed.html#gaf213d5422ec35e7f6caad827c79bc948":[5,5,4],
|
||||
"group__zeroinit.html":[5,4],
|
||||
"group__zeroinit.html#ga375fa8a611c51905e592d5d467c49664":[5,4,4],
|
||||
"group__zeroinit.html#ga3e7e5c291acf1c7fd7ffd9914a9f945f":[5,4,6],
|
||||
"group__zeroinit.html#ga496452c96f1de8c500be9fddf52edaf7":[5,4,2],
|
||||
"group__zeroinit.html#ga4ff5e92ad73585418a072c9d059e5cf9":[5,4,7],
|
||||
"group__zeroinit.html#ga8648c5fbb22a80f0262859099f06dfbd":[5,4,0],
|
||||
"group__zeroinit.html#ga8c292e142110229a2980b37ab036dbc6":[5,4,8],
|
||||
"group__zeroinit.html#ga9f3f999396c8f77ca5e80e7b40ac29e3":[5,4,1],
|
||||
"group__zeroinit.html#gac90da54fa7e5d10bdc97ce0b51dce2eb":[5,4,5],
|
||||
"group__zeroinit.html#gacd71a7bce96aab38ae6de17af2eb2cf0":[5,4,9],
|
||||
"group__zeroinit.html#gacfad83f14eb5d6a42a497a898e19fc76":[5,4,3],
|
||||
"group__zeroinit.html#gae8b358c417e61d5307da002702b0a8e1":[5,4,10],
|
||||
"index.html":[],
|
||||
"modules.html":[4],
|
||||
"overrides.html":[2],
|
||||
"modules.html":[5],
|
||||
"overrides.html":[3],
|
||||
"pages.html":[],
|
||||
"using.html":[1]
|
||||
};
|
||||
|
@ -118,9 +118,10 @@ $(document).ready(function(){initNavTree('overrides.html','');});
|
||||
<p>Note that certain security restrictions may apply when doing this from the <a href="https://stackoverflow.com/questions/43941322/dyld-insert-libraries-ignored-when-calling-application-through-bash">shell</a>.</p>
|
||||
<p>Note: unfortunately, at this time, dynamic overriding on macOS seems broken but it is actively worked on to fix this (see issue <a href="https://github.com/microsoft/mimalloc/issues/50"><code>#50</code></a>).</p>
|
||||
<h3>Windows</h3>
|
||||
<p>On Windows you need to link your program explicitly with the mimalloc DLL, and use the C-runtime library as a DLL (the <code>/MD</code> or <code>/MDd</code> switch). To ensure the mimalloc DLL gets loaded it is easiest to insert some call to the mimalloc API in the <code>main</code> function, like <code>mi_version()</code> (or use the <code>/INCLUDE:mi_version</code> switch on the linker)</p>
|
||||
<p>Due to the way mimalloc intercepts the standard malloc at runtime, it is best to link to the mimalloc import library first on the command line so it gets loaded right after the universal C runtime DLL (<code>ucrtbase</code>). See the <code>mimalloc-override-test</code> project for an example.</p>
|
||||
<p>Note: the current overriding on Windows works for most programs but some programs still have trouble – the <code>dev-exp</code> branch contains a newer way of overriding that is more robust; try this out if you experience troubles.</p>
|
||||
<p>On Windows you need to link your program explicitly with the mimalloc DLL and use the C-runtime library as a DLL (using the <code>/MD</code> or <code>/MDd</code> switch). Moreover, you need to ensure the <code>mimalloc-redirect.dll</code> (or <code>mimalloc-redirect32.dll</code>) is available in the same folder as the mimalloc DLL at runtime (as it as referred to by the mimalloc DLL). The redirection DLL's ensure all calls to the C runtime malloc API get redirected to mimalloc.</p>
|
||||
<p>To ensure the mimalloc DLL is loaded at run-time it is easiest to insert some call to the mimalloc API in the <code>main</code> function, like <code>mi_version()</code> (or use the <code>/INCLUDE:mi_version</code> switch on the linker). See the <code>mimalloc-override-test</code> project for an example on how to use this.</p>
|
||||
<p>The environment variable <code>MIMALLOC_DISABLE_REDIRECT=1</code> can be used to disable dynamic overriding at run-time. Use <code>MIMALLOC_VERBOSE=1</code> to check if mimalloc successfully redirected.</p>
|
||||
<p>(Note: in principle, it should be possible to patch existing executables that are linked with the dynamic C runtime (<code>ucrtbase.dll</code>) by just putting the mimalloc DLL into the import table (and putting <code>mimalloc-redirect.dll</code> in the same folder) Such patching can be done for example with <a href="https://ntcore.com/?page_id=388">CFF Explorer</a>).</p>
|
||||
<h2>Static override</h2>
|
||||
<p>On Unix systems, you can also statically link with <em>mimalloc</em> to override the standard malloc interface. The recommended way is to link the final program with the <em>mimalloc</em> single object file (<code>mimalloc-override.o</code>). We use an object file instead of a library file as linkers give preference to that over archives to resolve symbols. To ensure that the standard malloc interface resolves to the <em>mimalloc</em> library, link it as the first object file. For example:</p>
|
||||
<div class="fragment"><div class="line">gcc -o myprogram mimalloc-<span class="keyword">override</span>.o myfile1.c ...</div></div><!-- fragment --><h2>List of Overrides:</h2>
|
||||
|
@ -106,8 +106,9 @@ $(document).ready(function(){initNavTree('pages.html','');});
|
||||
<table class="directory">
|
||||
<tr id="row_0_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="build.html" target="_self">Building</a></td><td class="desc"></td></tr>
|
||||
<tr id="row_1_"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="using.html" target="_self">Using the library</a></td><td class="desc"></td></tr>
|
||||
<tr id="row_2_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="overrides.html" target="_self">Overriding Malloc</a></td><td class="desc"></td></tr>
|
||||
<tr id="row_3_"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="bench.html" target="_self">Performance</a></td><td class="desc"></td></tr>
|
||||
<tr id="row_2_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="environment.html" target="_self">Environment Options</a></td><td class="desc"></td></tr>
|
||||
<tr id="row_3_"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="overrides.html" target="_self">Overriding Malloc</a></td><td class="desc"></td></tr>
|
||||
<tr id="row_4_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="bench.html" target="_self">Performance</a></td><td class="desc"></td></tr>
|
||||
</table>
|
||||
</div><!-- directory -->
|
||||
</div><!-- contents -->
|
||||
|
@ -1,4 +1,5 @@
|
||||
var searchData=
|
||||
[
|
||||
['environment_20options',['Environment Options',['../environment.html',1,'']]],
|
||||
['extended_20functions',['Extended Functions',['../group__extended.html',1,'']]]
|
||||
];
|
||||
|
@ -23,6 +23,7 @@ var searchData=
|
||||
['mi_5fheap_5fcalloc_5faligned_5fat',['mi_heap_calloc_aligned_at',['../group__heap.html#ga08ca6419a5c057a4d965868998eef487',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fcalloc_5ftp',['mi_heap_calloc_tp',['../group__typed.html#ga4e5d1f1707c90e5f55e023ac5f45fe74',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fcheck_5fowned',['mi_heap_check_owned',['../group__analysis.html#ga0d67c1789faaa15ff366c024fcaf6377',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fcollect',['mi_heap_collect',['../group__heap.html#ga7922f7495cde30b1984d0e6072419298',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fcontains_5fblock',['mi_heap_contains_block',['../group__analysis.html#gaa862aa8ed8d57d84cae41fc1022d71af',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fdelete',['mi_heap_delete',['../group__heap.html#ga2ab1af8d438819b55319c7ef51d1e409',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fdestroy',['mi_heap_destroy',['../group__heap.html#ga9f9c0844edb9717f4feacd79116b8e0d',1,'mimalloc-doc.h']]],
|
||||
@ -31,6 +32,7 @@ var searchData=
|
||||
['mi_5fheap_5fmalloc',['mi_heap_malloc',['../group__heap.html#ga9cbed01e42c0647907295de92c3fa296',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fmalloc_5faligned',['mi_heap_malloc_aligned',['../group__heap.html#gab5b87e1805306f70df38789fcfcf6653',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fmalloc_5faligned_5fat',['mi_heap_malloc_aligned_at',['../group__heap.html#ga23acd7680fb0976dde3783254c6c874b',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fmalloc_5fsmall',['mi_heap_malloc_small',['../group__heap.html#gaa1a1c7a1f4da6826b5a25b70ef878368',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fmalloc_5ftp',['mi_heap_malloc_tp',['../group__typed.html#ga653bcb24ac495bc19940ecd6898f9cd7',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fmallocn',['mi_heap_mallocn',['../group__heap.html#ga851da6c43fe0b71c1376cee8aef90db0',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fmallocn_5ftp',['mi_heap_mallocn_tp',['../group__typed.html#ga6b75cb9c4b9c647661d0924552dc6e83',1,'mimalloc-doc.h']]],
|
||||
@ -42,6 +44,13 @@ var searchData=
|
||||
['mi_5fheap_5freallocn',['mi_heap_reallocn',['../group__heap.html#gac74e94ad9b0c9b57c1c4d88b8825b7a8',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5freallocn_5ftp',['mi_heap_reallocn_tp',['../group__typed.html#gaf213d5422ec35e7f6caad827c79bc948',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frealpath',['mi_heap_realpath',['../group__heap.html#ga00e95ba1e01acac3cfd95bb7a357a6f0',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frecalloc',['mi_heap_recalloc',['../group__zeroinit.html#ga8648c5fbb22a80f0262859099f06dfbd',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frecalloc_5faligned',['mi_heap_recalloc_aligned',['../group__zeroinit.html#ga9f3f999396c8f77ca5e80e7b40ac29e3',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frecalloc_5faligned_5fat',['mi_heap_recalloc_aligned_at',['../group__zeroinit.html#ga496452c96f1de8c500be9fddf52edaf7',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frecalloc_5ftp',['mi_heap_recalloc_tp',['../group__typed.html#ga3e50a1600958fcaf1a7f3560c9174f9e',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frezalloc',['mi_heap_rezalloc',['../group__zeroinit.html#gacfad83f14eb5d6a42a497a898e19fc76',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frezalloc_5faligned',['mi_heap_rezalloc_aligned',['../group__zeroinit.html#ga375fa8a611c51905e592d5d467c49664',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frezalloc_5faligned_5fat',['mi_heap_rezalloc_aligned_at',['../group__zeroinit.html#gac90da54fa7e5d10bdc97ce0b51dce2eb',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fset_5fdefault',['mi_heap_set_default',['../group__heap.html#gab8631ec88c8d26641b68b5d25dcd4422',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fstrdup',['mi_heap_strdup',['../group__heap.html#ga139d6b09dbf50c3c2523d0f4d1cfdeb5',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fstrndup',['mi_heap_strndup',['../group__heap.html#ga8e3dbd46650dd26573cf307a2c8f1f5a',1,'mimalloc-doc.h']]],
|
||||
@ -51,6 +60,8 @@ var searchData=
|
||||
['mi_5fheap_5fzalloc_5faligned',['mi_heap_zalloc_aligned',['../group__heap.html#gaa450a59c6c7ae5fdbd1c2b80a8329ef0',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fzalloc_5faligned_5fat',['mi_heap_zalloc_aligned_at',['../group__heap.html#ga45fb43a62776fbebbdf1edd99b527954',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fzalloc_5ftp',['mi_heap_zalloc_tp',['../group__typed.html#gad6e87e86e994aa14416ae9b5d4c188fe',1,'mimalloc-doc.h']]],
|
||||
['mi_5fis_5fin_5fheap_5fregion',['mi_is_in_heap_region',['../group__extended.html#ga5f071b10d4df1c3658e04e7fd67a94e6',1,'mimalloc-doc.h']]],
|
||||
['mi_5fis_5fredirected',['mi_is_redirected',['../group__extended.html#gaad25050b19f30cd79397b227e0157a3f',1,'mimalloc-doc.h']]],
|
||||
['mi_5fmalloc',['mi_malloc',['../group__malloc.html#ga3406e8b168bc74c8637b11571a6da83a',1,'mimalloc-doc.h']]],
|
||||
['mi_5fmalloc_5faligned',['mi_malloc_aligned',['../group__aligned.html#ga68930196751fa2cca9e1fd0d71bade56',1,'mimalloc-doc.h']]],
|
||||
['mi_5fmalloc_5faligned_5fat',['mi_malloc_aligned_at',['../group__aligned.html#ga5850da130c936bd77db039dcfbc8295d',1,'mimalloc-doc.h']]],
|
||||
@ -67,22 +78,26 @@ var searchData=
|
||||
['mi_5fnew_5fnothrow',['mi_new_nothrow',['../group__posix.html#gaeaded64eda71ed6b1d569d3e723abc4a',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fcache_5freset',['mi_option_cache_reset',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cac2157a0cb79cd996c1db7d9f6a090c07',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5feager_5fcommit',['mi_option_eager_commit',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca1e8de72c93da7ff22d91e1e27b52ac2b',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5feager_5fcommit_5fdelay',['mi_option_eager_commit_delay',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca17a190c25be381142d87e0468c4c068c',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5feager_5fregion_5fcommit',['mi_option_eager_region_commit',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca32ce97ece29f69e82579679cf8a307ad',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fenable',['mi_option_enable',['../group__options.html#ga6d45a20a3131f18bc351b69763b38ce4',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fenable_5fdefault',['mi_option_enable_default',['../group__options.html#ga37988264b915a7db92530cc02d5494cb',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fenabled',['mi_option_enabled',['../group__options.html#gacebe3f6d91b4a50b54eb84e2a1da1b30',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fget',['mi_option_get',['../group__options.html#ga7e8af195cc81d3fa64ccf2662caa565a',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5flarge_5fos_5fpages',['mi_option_large_os_pages',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca4192d491200d0055df0554d4cf65054e',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fos_5ftag',['mi_option_os_tag',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca4b74ae2a69e445de6c2361b73c1d14bf',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fpage_5freset',['mi_option_page_reset',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cada854dd272c66342f18a93ee254a2968',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5freserve_5fhuge_5fos_5fpages',['mi_option_reserve_huge_os_pages',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884caca7ed041be3b0b9d0b82432c7bf41af2',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5freset_5fdecommits',['mi_option_reset_decommits',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cac81ee965b130fa81238913a3c239d536',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5freset_5fdiscards',['mi_option_reset_discards',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cab3a837b5ceee250e14e051dbee2a441b',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fsecure',['mi_option_secure',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca083ee20765063fc6d727e11d33cf378f',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fsegment_5fcache',['mi_option_segment_cache',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca2ecbe7ef32f5c84de3739aa4f0b805a1',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fsegment_5freset',['mi_option_segment_reset',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cafb121d30d87591850d5410ccc3a95c6d',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fset',['mi_option_set',['../group__options.html#gaf84921c32375e25754dc2ee6a911fa60',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fset_5fdefault',['mi_option_set_default',['../group__options.html#ga7ef623e440e6e5545cb08c94e71e4b90',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fshow_5ferrors',['mi_option_show_errors',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cafbf4822e5c00732c5984b32a032837f0',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fshow_5fstats',['mi_option_show_stats',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca0957ef73b2550764b4840edf48422fda',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5ft',['mi_option_t',['../group__options.html#gafebf7ed116adb38ae5218bc3ce06884c',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fverbose',['mi_option_verbose',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca7c8b7bf5281c581bad64f5daa6442777',1,'mimalloc-doc.h']]],
|
||||
['mi_5foutput_5ffun',['mi_output_fun',['../group__extended.html#ga2bed6d40b74591a67f81daea4b4a246f',1,'mimalloc-doc.h']]],
|
||||
['mi_5fposix_5fmemalign',['mi_posix_memalign',['../group__posix.html#gacff84f226ba9feb2031b8992e5579447',1,'mimalloc-doc.h']]],
|
||||
['mi_5fpvalloc',['mi_pvalloc',['../group__posix.html#gaeb325c39b887d3b90d85d1eb1712fb1e',1,'mimalloc-doc.h']]],
|
||||
['mi_5frealloc',['mi_realloc',['../group__malloc.html#gaf11eb497da57bdfb2de65eb191c69db6',1,'mimalloc-doc.h']]],
|
||||
@ -94,15 +109,23 @@ var searchData=
|
||||
['mi_5freallocn_5ftp',['mi_reallocn_tp',['../group__typed.html#ga1158b49a55dfa81f58a4426a7578f523',1,'mimalloc-doc.h']]],
|
||||
['mi_5frealpath',['mi_realpath',['../group__malloc.html#ga08cec32dd5bbe7da91c78d19f1b5bebe',1,'mimalloc-doc.h']]],
|
||||
['mi_5frecalloc',['mi_recalloc',['../group__malloc.html#ga23a0fbb452b5dce8e31fab1a1958cacc',1,'mimalloc-doc.h']]],
|
||||
['mi_5frecalloc_5faligned',['mi_recalloc_aligned',['../group__zeroinit.html#ga3e7e5c291acf1c7fd7ffd9914a9f945f',1,'mimalloc-doc.h']]],
|
||||
['mi_5frecalloc_5faligned_5fat',['mi_recalloc_aligned_at',['../group__zeroinit.html#ga4ff5e92ad73585418a072c9d059e5cf9',1,'mimalloc-doc.h']]],
|
||||
['mi_5fregister_5fdeferred_5ffree',['mi_register_deferred_free',['../group__extended.html#ga24dc9cc6fca8daa2aa30aa8025467ce2',1,'mimalloc-doc.h']]],
|
||||
['mi_5fregister_5foutput',['mi_register_output',['../group__extended.html#ga84a0c8b401e42eb5b1bce156852f44c5',1,'mimalloc-doc.h']]],
|
||||
['mi_5freserve_5fhuge_5fos_5fpages',['mi_reserve_huge_os_pages',['../group__extended.html#ga2664f36a2dd557741c429cb799f04641',1,'mimalloc-doc.h']]],
|
||||
['mi_5frezalloc',['mi_rezalloc',['../group__zeroinit.html#ga8c292e142110229a2980b37ab036dbc6',1,'mimalloc-doc.h']]],
|
||||
['mi_5frezalloc_5faligned',['mi_rezalloc_aligned',['../group__zeroinit.html#gacd71a7bce96aab38ae6de17af2eb2cf0',1,'mimalloc-doc.h']]],
|
||||
['mi_5frezalloc_5faligned_5fat',['mi_rezalloc_aligned_at',['../group__zeroinit.html#gae8b358c417e61d5307da002702b0a8e1',1,'mimalloc-doc.h']]],
|
||||
['mi_5fsmall_5fsize_5fmax',['MI_SMALL_SIZE_MAX',['../group__extended.html#ga1ea64283508718d9d645c38efc2f4305',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstats_5fprint',['mi_stats_print',['../group__extended.html#ga6bb821ca1b664b452112c0e17b15fcf1',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstats_5freset',['mi_stats_reset',['../group__extended.html#ga9883b8a059aed7eb0888a01ec1461161',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstats_5fmerge',['mi_stats_merge',['../group__extended.html#ga854b1de8cb067c7316286c28b2fcd3d1',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstats_5fprint',['mi_stats_print',['../group__extended.html#ga8ca07ccff283956d71f48272f4fd5c01',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstats_5freset',['mi_stats_reset',['../group__extended.html#ga3bb8468b8cfcc6e2a61d98aee85c5f99',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstrdup',['mi_strdup',['../group__malloc.html#gac7cffe13f1f458ed16789488bf92b9b2',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstrndup',['mi_strndup',['../group__malloc.html#gaaabf971c2571891433477e2d21a35266',1,'mimalloc-doc.h']]],
|
||||
['mi_5fthread_5fdone',['mi_thread_done',['../group__extended.html#gac0f4849256aaf677f334690952c6ebbd',1,'mimalloc-doc.h']]],
|
||||
['mi_5fthread_5finit',['mi_thread_init',['../group__extended.html#ga9398517f01a1ec971244aa0db084ea46',1,'mimalloc-doc.h']]],
|
||||
['mi_5fthread_5fstats_5fprint',['mi_thread_stats_print',['../group__extended.html#ga490826cbd7c494acc9fe69be23f018ac',1,'mimalloc-doc.h']]],
|
||||
['mi_5fthread_5fdone',['mi_thread_done',['../group__extended.html#ga0ae4581e85453456a0d658b2b98bf7bf',1,'mimalloc-doc.h']]],
|
||||
['mi_5fthread_5finit',['mi_thread_init',['../group__extended.html#gaf8e73efc2cbca9ebfdfb166983a04c17',1,'mimalloc-doc.h']]],
|
||||
['mi_5fthread_5fstats_5fprint',['mi_thread_stats_print',['../group__extended.html#ga489670a15d1a257ab4639e645ee4612a',1,'mimalloc-doc.h']]],
|
||||
['mi_5fusable_5fsize',['mi_usable_size',['../group__extended.html#ga089c859d9eddc5f9b4bd946cd53cebee',1,'mimalloc-doc.h']]],
|
||||
['mi_5fvalloc',['mi_valloc',['../group__posix.html#ga73baaf5951f5165ba0763d0c06b6a93b',1,'mimalloc-doc.h']]],
|
||||
['mi_5fzalloc',['mi_zalloc',['../group__malloc.html#gafdd9d8bb2986e668ba9884f28af38000',1,'mimalloc-doc.h']]],
|
||||
|
@ -2,12 +2,15 @@ var searchData=
|
||||
[
|
||||
['mi_5foption_5fcache_5freset',['mi_option_cache_reset',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cac2157a0cb79cd996c1db7d9f6a090c07',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5feager_5fcommit',['mi_option_eager_commit',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca1e8de72c93da7ff22d91e1e27b52ac2b',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5feager_5fcommit_5fdelay',['mi_option_eager_commit_delay',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca17a190c25be381142d87e0468c4c068c',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5feager_5fregion_5fcommit',['mi_option_eager_region_commit',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca32ce97ece29f69e82579679cf8a307ad',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5flarge_5fos_5fpages',['mi_option_large_os_pages',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca4192d491200d0055df0554d4cf65054e',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fos_5ftag',['mi_option_os_tag',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca4b74ae2a69e445de6c2361b73c1d14bf',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fpage_5freset',['mi_option_page_reset',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cada854dd272c66342f18a93ee254a2968',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5freserve_5fhuge_5fos_5fpages',['mi_option_reserve_huge_os_pages',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884caca7ed041be3b0b9d0b82432c7bf41af2',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5freset_5fdecommits',['mi_option_reset_decommits',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cac81ee965b130fa81238913a3c239d536',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5freset_5fdiscards',['mi_option_reset_discards',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cab3a837b5ceee250e14e051dbee2a441b',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fsecure',['mi_option_secure',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca083ee20765063fc6d727e11d33cf378f',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fsegment_5fcache',['mi_option_segment_cache',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca2ecbe7ef32f5c84de3739aa4f0b805a1',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fsegment_5freset',['mi_option_segment_reset',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cafb121d30d87591850d5410ccc3a95c6d',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fshow_5ferrors',['mi_option_show_errors',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884cafbf4822e5c00732c5984b32a032837f0',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fshow_5fstats',['mi_option_show_stats',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca0957ef73b2550764b4840edf48422fda',1,'mimalloc-doc.h']]],
|
||||
['mi_5foption_5fverbose',['mi_option_verbose',['../group__options.html#ggafebf7ed116adb38ae5218bc3ce06884ca7c8b7bf5281c581bad64f5daa6442777',1,'mimalloc-doc.h']]]
|
||||
|
@ -18,6 +18,7 @@ var searchData=
|
||||
['mi_5fheap_5fcalloc_5faligned',['mi_heap_calloc_aligned',['../group__heap.html#ga4af03a6e2b93fae77424d93f889705c3',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fcalloc_5faligned_5fat',['mi_heap_calloc_aligned_at',['../group__heap.html#ga08ca6419a5c057a4d965868998eef487',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fcheck_5fowned',['mi_heap_check_owned',['../group__analysis.html#ga0d67c1789faaa15ff366c024fcaf6377',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fcollect',['mi_heap_collect',['../group__heap.html#ga7922f7495cde30b1984d0e6072419298',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fcontains_5fblock',['mi_heap_contains_block',['../group__analysis.html#gaa862aa8ed8d57d84cae41fc1022d71af',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fdelete',['mi_heap_delete',['../group__heap.html#ga2ab1af8d438819b55319c7ef51d1e409',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fdestroy',['mi_heap_destroy',['../group__heap.html#ga9f9c0844edb9717f4feacd79116b8e0d',1,'mimalloc-doc.h']]],
|
||||
@ -26,6 +27,7 @@ var searchData=
|
||||
['mi_5fheap_5fmalloc',['mi_heap_malloc',['../group__heap.html#ga9cbed01e42c0647907295de92c3fa296',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fmalloc_5faligned',['mi_heap_malloc_aligned',['../group__heap.html#gab5b87e1805306f70df38789fcfcf6653',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fmalloc_5faligned_5fat',['mi_heap_malloc_aligned_at',['../group__heap.html#ga23acd7680fb0976dde3783254c6c874b',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fmalloc_5fsmall',['mi_heap_malloc_small',['../group__heap.html#gaa1a1c7a1f4da6826b5a25b70ef878368',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fmallocn',['mi_heap_mallocn',['../group__heap.html#ga851da6c43fe0b71c1376cee8aef90db0',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fnew',['mi_heap_new',['../group__heap.html#ga766f672ba56f2fbfeb9d9dbb0b7f6b11',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frealloc',['mi_heap_realloc',['../group__heap.html#gaaef3395f66be48f37bdc8322509c5d81',1,'mimalloc-doc.h']]],
|
||||
@ -34,6 +36,12 @@ var searchData=
|
||||
['mi_5fheap_5freallocf',['mi_heap_reallocf',['../group__heap.html#ga4a21070eb4e7cce018133c8d5f4b0527',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5freallocn',['mi_heap_reallocn',['../group__heap.html#gac74e94ad9b0c9b57c1c4d88b8825b7a8',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frealpath',['mi_heap_realpath',['../group__heap.html#ga00e95ba1e01acac3cfd95bb7a357a6f0',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frecalloc',['mi_heap_recalloc',['../group__zeroinit.html#ga8648c5fbb22a80f0262859099f06dfbd',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frecalloc_5faligned',['mi_heap_recalloc_aligned',['../group__zeroinit.html#ga9f3f999396c8f77ca5e80e7b40ac29e3',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frecalloc_5faligned_5fat',['mi_heap_recalloc_aligned_at',['../group__zeroinit.html#ga496452c96f1de8c500be9fddf52edaf7',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frezalloc',['mi_heap_rezalloc',['../group__zeroinit.html#gacfad83f14eb5d6a42a497a898e19fc76',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frezalloc_5faligned',['mi_heap_rezalloc_aligned',['../group__zeroinit.html#ga375fa8a611c51905e592d5d467c49664',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5frezalloc_5faligned_5fat',['mi_heap_rezalloc_aligned_at',['../group__zeroinit.html#gac90da54fa7e5d10bdc97ce0b51dce2eb',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fset_5fdefault',['mi_heap_set_default',['../group__heap.html#gab8631ec88c8d26641b68b5d25dcd4422',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fstrdup',['mi_heap_strdup',['../group__heap.html#ga139d6b09dbf50c3c2523d0f4d1cfdeb5',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fstrndup',['mi_heap_strndup',['../group__heap.html#ga8e3dbd46650dd26573cf307a2c8f1f5a',1,'mimalloc-doc.h']]],
|
||||
@ -41,6 +49,8 @@ var searchData=
|
||||
['mi_5fheap_5fzalloc',['mi_heap_zalloc',['../group__heap.html#ga903104592c8ed53417a3762da6241133',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fzalloc_5faligned',['mi_heap_zalloc_aligned',['../group__heap.html#gaa450a59c6c7ae5fdbd1c2b80a8329ef0',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5fzalloc_5faligned_5fat',['mi_heap_zalloc_aligned_at',['../group__heap.html#ga45fb43a62776fbebbdf1edd99b527954',1,'mimalloc-doc.h']]],
|
||||
['mi_5fis_5fin_5fheap_5fregion',['mi_is_in_heap_region',['../group__extended.html#ga5f071b10d4df1c3658e04e7fd67a94e6',1,'mimalloc-doc.h']]],
|
||||
['mi_5fis_5fredirected',['mi_is_redirected',['../group__extended.html#gaad25050b19f30cd79397b227e0157a3f',1,'mimalloc-doc.h']]],
|
||||
['mi_5fmalloc',['mi_malloc',['../group__malloc.html#ga3406e8b168bc74c8637b11571a6da83a',1,'mimalloc-doc.h']]],
|
||||
['mi_5fmalloc_5faligned',['mi_malloc_aligned',['../group__aligned.html#ga68930196751fa2cca9e1fd0d71bade56',1,'mimalloc-doc.h']]],
|
||||
['mi_5fmalloc_5faligned_5fat',['mi_malloc_aligned_at',['../group__aligned.html#ga5850da130c936bd77db039dcfbc8295d',1,'mimalloc-doc.h']]],
|
||||
@ -69,14 +79,22 @@ var searchData=
|
||||
['mi_5freallocn',['mi_reallocn',['../group__malloc.html#ga61d57b4144ba24fba5c1e9b956d13853',1,'mimalloc-doc.h']]],
|
||||
['mi_5frealpath',['mi_realpath',['../group__malloc.html#ga08cec32dd5bbe7da91c78d19f1b5bebe',1,'mimalloc-doc.h']]],
|
||||
['mi_5frecalloc',['mi_recalloc',['../group__malloc.html#ga23a0fbb452b5dce8e31fab1a1958cacc',1,'mimalloc-doc.h']]],
|
||||
['mi_5frecalloc_5faligned',['mi_recalloc_aligned',['../group__zeroinit.html#ga3e7e5c291acf1c7fd7ffd9914a9f945f',1,'mimalloc-doc.h']]],
|
||||
['mi_5frecalloc_5faligned_5fat',['mi_recalloc_aligned_at',['../group__zeroinit.html#ga4ff5e92ad73585418a072c9d059e5cf9',1,'mimalloc-doc.h']]],
|
||||
['mi_5fregister_5fdeferred_5ffree',['mi_register_deferred_free',['../group__extended.html#ga24dc9cc6fca8daa2aa30aa8025467ce2',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstats_5fprint',['mi_stats_print',['../group__extended.html#ga6bb821ca1b664b452112c0e17b15fcf1',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstats_5freset',['mi_stats_reset',['../group__extended.html#ga9883b8a059aed7eb0888a01ec1461161',1,'mimalloc-doc.h']]],
|
||||
['mi_5fregister_5foutput',['mi_register_output',['../group__extended.html#ga84a0c8b401e42eb5b1bce156852f44c5',1,'mimalloc-doc.h']]],
|
||||
['mi_5freserve_5fhuge_5fos_5fpages',['mi_reserve_huge_os_pages',['../group__extended.html#ga2664f36a2dd557741c429cb799f04641',1,'mimalloc-doc.h']]],
|
||||
['mi_5frezalloc',['mi_rezalloc',['../group__zeroinit.html#ga8c292e142110229a2980b37ab036dbc6',1,'mimalloc-doc.h']]],
|
||||
['mi_5frezalloc_5faligned',['mi_rezalloc_aligned',['../group__zeroinit.html#gacd71a7bce96aab38ae6de17af2eb2cf0',1,'mimalloc-doc.h']]],
|
||||
['mi_5frezalloc_5faligned_5fat',['mi_rezalloc_aligned_at',['../group__zeroinit.html#gae8b358c417e61d5307da002702b0a8e1',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstats_5fmerge',['mi_stats_merge',['../group__extended.html#ga854b1de8cb067c7316286c28b2fcd3d1',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstats_5fprint',['mi_stats_print',['../group__extended.html#ga8ca07ccff283956d71f48272f4fd5c01',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstats_5freset',['mi_stats_reset',['../group__extended.html#ga3bb8468b8cfcc6e2a61d98aee85c5f99',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstrdup',['mi_strdup',['../group__malloc.html#gac7cffe13f1f458ed16789488bf92b9b2',1,'mimalloc-doc.h']]],
|
||||
['mi_5fstrndup',['mi_strndup',['../group__malloc.html#gaaabf971c2571891433477e2d21a35266',1,'mimalloc-doc.h']]],
|
||||
['mi_5fthread_5fdone',['mi_thread_done',['../group__extended.html#gac0f4849256aaf677f334690952c6ebbd',1,'mimalloc-doc.h']]],
|
||||
['mi_5fthread_5finit',['mi_thread_init',['../group__extended.html#ga9398517f01a1ec971244aa0db084ea46',1,'mimalloc-doc.h']]],
|
||||
['mi_5fthread_5fstats_5fprint',['mi_thread_stats_print',['../group__extended.html#ga490826cbd7c494acc9fe69be23f018ac',1,'mimalloc-doc.h']]],
|
||||
['mi_5fthread_5fdone',['mi_thread_done',['../group__extended.html#ga0ae4581e85453456a0d658b2b98bf7bf',1,'mimalloc-doc.h']]],
|
||||
['mi_5fthread_5finit',['mi_thread_init',['../group__extended.html#gaf8e73efc2cbca9ebfdfb166983a04c17',1,'mimalloc-doc.h']]],
|
||||
['mi_5fthread_5fstats_5fprint',['mi_thread_stats_print',['../group__extended.html#ga489670a15d1a257ab4639e645ee4612a',1,'mimalloc-doc.h']]],
|
||||
['mi_5fusable_5fsize',['mi_usable_size',['../group__extended.html#ga089c859d9eddc5f9b4bd946cd53cebee',1,'mimalloc-doc.h']]],
|
||||
['mi_5fvalloc',['mi_valloc',['../group__posix.html#ga73baaf5951f5165ba0763d0c06b6a93b',1,'mimalloc-doc.h']]],
|
||||
['mi_5fzalloc',['mi_zalloc',['../group__malloc.html#gafdd9d8bb2986e668ba9884f28af38000',1,'mimalloc-doc.h']]],
|
||||
|
@ -1,4 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['overriding_20malloc',['Overriding Malloc',['../overrides.html',1,'']]]
|
||||
['environment_20options',['Environment Options',['../environment.html',1,'']]]
|
||||
];
|
||||
|
@ -1,4 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['performance',['Performance',['../bench.html',1,'']]]
|
||||
['overriding_20malloc',['Overriding Malloc',['../overrides.html',1,'']]]
|
||||
];
|
||||
|
@ -1,4 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['using_20the_20library',['Using the library',['../using.html',1,'']]]
|
||||
['performance',['Performance',['../bench.html',1,'']]]
|
||||
];
|
||||
|
@ -1,14 +1,14 @@
|
||||
var indexSectionsWithContent =
|
||||
{
|
||||
0: "_abcehmoprtu",
|
||||
0: "_abcehmoprtuz",
|
||||
1: "m",
|
||||
2: "m",
|
||||
3: "bcru",
|
||||
4: "m",
|
||||
5: "m",
|
||||
6: "_m",
|
||||
7: "abehprt",
|
||||
8: "bopu"
|
||||
7: "abehprtz",
|
||||
8: "beopu"
|
||||
};
|
||||
|
||||
var indexSectionNames =
|
||||
|
@ -2,5 +2,6 @@ var searchData=
|
||||
[
|
||||
['mi_5fblock_5fvisit_5ffun',['mi_block_visit_fun',['../group__analysis.html#gadfa01e2900f0e5d515ad5506b26f6d65',1,'mimalloc-doc.h']]],
|
||||
['mi_5fdeferred_5ffree_5ffun',['mi_deferred_free_fun',['../group__extended.html#ga22213691c3ce5ab4d91b24aff1023529',1,'mimalloc-doc.h']]],
|
||||
['mi_5fheap_5ft',['mi_heap_t',['../group__heap.html#ga34a47cde5a5b38c29f1aa3c5e76943c2',1,'mimalloc-doc.h']]]
|
||||
['mi_5fheap_5ft',['mi_heap_t',['../group__heap.html#ga34a47cde5a5b38c29f1aa3c5e76943c2',1,'mimalloc-doc.h']]],
|
||||
['mi_5foutput_5ffun',['mi_output_fun',['../group__extended.html#ga2bed6d40b74591a67f81daea4b4a246f',1,'mimalloc-doc.h']]]
|
||||
];
|
||||
|
@ -104,16 +104,7 @@ $(document).ready(function(){initNavTree('using.html','');});
|
||||
<div class="contents">
|
||||
<div class="textblock"><p>The preferred usage is including <code><mimalloc.h></code>, linking with the shared- or static library, and using the <code>mi_malloc</code> API exclusively for allocation. For example, </p><div class="fragment"><div class="line">gcc -o myprogram -lmimalloc myfile.c</div></div><!-- fragment --><p>mimalloc uses only safe OS calls (<code>mmap</code> and <code>VirtualAlloc</code>) and can co-exist with other allocators linked to the same program. If you use <code>cmake</code>, you can simply use: </p><div class="fragment"><div class="line">find_package(mimalloc 1.0 REQUIRED)</div></div><!-- fragment --><p> in your <code>CMakeLists.txt</code> to find a locally installed mimalloc. Then use either: </p><div class="fragment"><div class="line">target_link_libraries(myapp PUBLIC mimalloc)</div></div><!-- fragment --><p> to link with the shared (dynamic) library, or: </p><div class="fragment"><div class="line">target_link_libraries(myapp PUBLIC mimalloc-<span class="keyword">static</span>)</div></div><!-- fragment --><p> to link with the static library. See <code>test\CMakeLists.txt</code> for an example.</p>
|
||||
<p>You can pass environment variables to print verbose messages (<code>MIMALLOC_VERBOSE=1</code>) and statistics (<code>MIMALLOC_SHOW_STATS=1</code>) (in the debug version): </p><div class="fragment"><div class="line">> env MIMALLOC_SHOW_STATS=1 ./cfrac 175451865205073170563711388363</div><div class="line"></div><div class="line">175451865205073170563711388363 = 374456281610909315237213 * 468551</div><div class="line"></div><div class="line">heap stats: peak total freed unit</div><div class="line">normal 2: 16.4 kb 17.5 mb 17.5 mb 16 b ok</div><div class="line">normal 3: 16.3 kb 15.2 mb 15.2 mb 24 b ok</div><div class="line">normal 4: 64 b 4.6 kb 4.6 kb 32 b ok</div><div class="line">normal 5: 80 b 118.4 kb 118.4 kb 40 b ok</div><div class="line">normal 6: 48 b 48 b 48 b 48 b ok</div><div class="line">normal 17: 960 b 960 b 960 b 320 b ok</div><div class="line"></div><div class="line">heap stats: peak total freed unit</div><div class="line"> normal: 33.9 kb 32.8 mb 32.8 mb 1 b ok</div><div class="line"> huge: 0 b 0 b 0 b 1 b ok</div><div class="line"> total: 33.9 kb 32.8 mb 32.8 mb 1 b ok</div><div class="line">malloc requested: 32.8 mb</div><div class="line"></div><div class="line"> committed: 58.2 kb 58.2 kb 58.2 kb 1 b ok</div><div class="line"> reserved: 2.0 mb 2.0 mb 2.0 mb 1 b ok</div><div class="line"> reset: 0 b 0 b 0 b 1 b ok</div><div class="line"> segments: 1 1 1</div><div class="line">-abandoned: 0</div><div class="line"> pages: 6 6 6</div><div class="line">-abandoned: 0</div><div class="line"> mmaps: 3</div><div class="line"> mmap fast: 0</div><div class="line"> mmap slow: 1</div><div class="line"> threads: 0</div><div class="line"> elapsed: 2.022s</div><div class="line"> process: user: 1.781s, system: 0.016s, faults: 756, reclaims: 0, rss: 2.7 mb</div></div><!-- fragment --><p>The above model of using the <code>mi_</code> prefixed API is not always possible though in existing programs that already use the standard malloc interface, and another option is to override the standard malloc interface completely and redirect all calls to the <em>mimalloc</em> library instead.</p>
|
||||
<p>See <a class="el" href="overrides.html">Overriding Malloc</a> for more info.</p>
|
||||
<h2>Environment Options</h2>
|
||||
<p>You can set further options either programmatically (using <a href="https://microsoft.github.io/mimalloc/group__options.html"><code>mi_option_set</code></a>), or via environment variables.</p>
|
||||
<ul>
|
||||
<li><code>MIMALLOC_SHOW_STATS=1</code>: show statistics when the program terminates.</li>
|
||||
<li><code>MIMALLOC_VERBOSE=1</code>: show verbose messages.</li>
|
||||
<li><code>MIMALLOC_SHOW_ERRORS=1</code>: show error and warning messages.</li>
|
||||
<li><code>MIMALLOC_LARGE_OS_PAGES=1</code>: use large OS pages when available; for some workloads this can significantly improve performance. Use <code>MIMALLOC_VERBOSE</code> to check if the large OS pages are enabled – usually one needs to explicitly allow large OS pages (as on <a href="https://docs.microsoft.com/en-us/sql/database-engine/configure-windows/enable-the-lock-pages-in-memory-option-windows?view=sql-server-2017">Windows</a> and <a href="https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/5/html/tuning_and_optimizing_red_hat_enterprise_linux_for_oracle_9i_and_10g_databases/sect-oracle_9i_and_10g_tuning_guide-large_memory_optimization_big_pages_and_huge_pages-configuring_huge_pages_in_red_hat_enterprise_linux_4_or_5">Linux</a>).</li>
|
||||
<li><code>MIMALLOC_EAGER_REGION_COMMIT=1</code>: on Windows, commit large (256MiB) regions eagerly. On Windows, these regions show in the working set even though usually just a small part is committed to physical memory. This is why it turned off by default on Windows as it looks not good in the task manager. However, in reality it is always better to turn it on as it improves performance and has no other drawbacks. </li>
|
||||
</ul>
|
||||
<p>See <a class="el" href="overrides.html">Overriding Malloc</a> for more info. </p>
|
||||
</div></div><!-- PageDoc -->
|
||||
</div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
|
Loading…
x
Reference in New Issue
Block a user