39 #ifdef MYTHREAD_ENABLED
63 bool set_compress,
bool set_decompress,
bool is_percentage)
67 assert(new_memlimit <= 100);
74 #if SIZE_MAX == UINT32_MAX
_Use_decl_annotations_ int __cdecl printf(const char *const _Format,...)
void hardware_memlimit_set(uint64_t new_memlimit, bool set_compress, bool set_decompress, bool is_percentage)
void hardware_threads_set(uint32_t n)
Set the maximum number of worker threads.
static uint64_t total_ram
Total amount of physical RAM.
static uint64_t memlimit_compress
Memory usage limit for compression.
uint32_t hardware_threads_get(void)
Get the maximum number of worker threads.
void hardware_memlimit_show(void)
Display the amount of RAM and memory usage limits and exit.
static uint32_t threads_max
static void memlimit_show(const char *str, uint64_t value)
Helper for hardware_memlimit_show() to print one human-readable info line.
static uint64_t memlimit_decompress
Memory usage limit for decompression.
uint64_t hardware_memlimit_get(enum operation_mode mode)
Get the current memory usage limit for compression or decompression.
assert(limit<=UINT32_MAX/2)
enum message_verbosity message_verbosity_get(void)
Get the current verbosity level.
Common includes, definitions, and prototypes.
const char * uint64_to_str(uint64_t value, uint32_t slot)
Convert uint64_t to a string.
uint64_t round_up_to_mib(uint64_t n)
Round an integer up to the next full MiB and convert to MiB.