Skip to main content

Module misc

Module misc 

Source

Re-exportsยง

use anyhow::Result; ๐Ÿ”’
use anyhow::Context; ๐Ÿ”’
use anyhow::anyhow; ๐Ÿ”’
use log::info; ๐Ÿ”’
use log::warn; ๐Ÿ”’
use nix::sys::resource::RLIM_INFINITY; ๐Ÿ”’
use nix::sys::resource::Resource; ๐Ÿ”’
use nix::sys::resource::getrlimit; ๐Ÿ”’
use nix::sys::resource::setrlimit; ๐Ÿ”’
use serde::Deserialize; ๐Ÿ”’
use serde::Deserialize; ๐Ÿ”’
use std::path::Path; ๐Ÿ”’
use std::thread::sleep; ๐Ÿ”’
use std::time::Duration; ๐Ÿ”’
use scx_stats::prelude::*; ๐Ÿ”’

Functionsยง

find_best_split_size
Find the best split size for dividing a total number of items given a range of sizes.
monitor_stats
monitor_stats_sched
Like monitor_stats(), but for the stats server at sched_path, the path the server was given through StatsServer::set_sched_path(). None selects the default server.
normalize_load_metric
read_file_byte
read_file_usize_vec
read_from_file
Read a file and parse its content into the specified type.
try_set_rlimit_infinity