rok commented on code in PR #13516: URL: https://github.com/apache/arrow/pull/13516#discussion_r966344579
########## cpp/src/arrow/memory_pool.h: ########## @@ -175,6 +175,48 @@ ARROW_EXPORT Status jemalloc_memory_pool(MemoryPool** out); ARROW_EXPORT Status jemalloc_set_decay_ms(int ms); +/// \brief Get basic allocation statistics from jemalloc +Status jemalloc_get_stat(const char* name, size_t* out); + +/// \brief The mallctl() function provides a general interface for introspecting the +/// memory allocator, as well as setting modifiable parameters and triggering actions. +/// The period-separated name argument specifies a location in a tree-structured +/// namespace; see the MALLCTL NAMESPACE section in jemalloc project documentation for +/// more information on the tree contents. To read a value, pass a pointer via oldp to +/// adequate space to contain the value, and a pointer to its length via oldlenp; +/// otherwise pass NULL and NULL. Similarly, to write a value, pass a pointer to the +/// value via newp, and its length via newlen; otherwise pass NULL and 0. +/// +ARROW_EXPORT Status jemalloc_mallctl(const char* name, void* oldp, size_t* oldlenp, + void* newp, size_t newlen); + +/// \brief The malloc_stats_print() function writes summary statistics via the write_cb Review Comment: Reduced and referenced the jemalloc docs for flags. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
