Detection of available hardware resources. More...
Functions | |
void | hardware_init (void) |
void | hardware_memlimit_set (uint64_t memlimit) |
uint64_t | hardware_memlimit_encoder (void) |
Get the memory usage limit for encoding. By default this is 90 % of RAM. | |
uint64_t | hardware_memlimit_decoder (void) |
Get the memory usage limit for decoding. By default this is 30 % of RAM. | |
Variables | |
size_t | opt_threads |
Detection of available hardware resources.
void hardware_init | ( | void | ) |
Initialize some hardware-specific variables, which are needed by other hardware_* functions.
References hardware_cores().
void hardware_memlimit_set | ( | uint64_t | memlimit | ) |
Set custom memory usage limit. This is used for both encoding and decoding. Zero indicates resetting the limit back to defaults.
References memlimit_custom.
uint64_t hardware_memlimit_encoder | ( | void | ) |
Get the memory usage limit for encoding. By default this is 90 % of RAM.
References memlimit_custom, and memlimit_encoder.
Referenced by message_help().
uint64_t hardware_memlimit_decoder | ( | void | ) |
Get the memory usage limit for decoding. By default this is 30 % of RAM.
References memlimit_custom, and memlimit_decoder.
Referenced by message_help().
size_t opt_threads |
Maximum number of free *coder* threads. This can be set with the --threads=NUM command line option.
Referenced by hardware_cores(), and message_help().