precord-0.7.8 is not a library.
precord
Command line tool for recording process or system performance data.
Installation
Install with cargo
:
cargo install precord
Usage
precord -p 1203 -o result.svg
Options
precord -h
-c / --category
- categories for recording, possible values:cpu
- CPU usage of processmem
- Memory usage of processalloc
- Allocation of processgpu
- GPU usage of processvram
- VRAM usage of processfps
- Frame rate of processnet_in/net_out
- Network recv/send of processdisk_read/disk_write
- Disk read/write of processkobject
- Kernel object count of processthread
- Thread count of processsys_cpu
- CPU usage of systemsys_cpu_freq
- CPU frequency of systemsys_cpu_temp
- CPU temperature of systemsys_gpu
- GPU usage of systemsys_power
- Power usage of system
-p / --process
- ID of processes--name
- Name of processes-o / --output
- Specify the output file, possible extensions:.svg
.html
.json
.csv
-i / --interval
- Interval for recording-n
- Count for recording--time
- Time limit for recording, e.g.,--time 1h30m59s
-r / --recurse-children
- Flag to recurse child processes--skip
- Number of skip records--gpu-calc
- Gpu calculation, possible values:max
sum
Command Mode
Type :
during recording will enter the command mode, and press Esc
will back to recording. The supported commands are:
w
- Write(Save) outputq
- Exitwq
- Combination ofw
andq
time
- modify time limit for recording
Sub Commands
thread-list <PID>
- List threads and cpu usage
precord-core
A library for retrieving process and system performance data.
use ;
use thread;
use Duration;
Supported Platforms
macOS | Windows | Linux | |
---|---|---|---|
cpu | :white_check_mark: | :white_check_mark: | :white_check_mark: |
mem | :white_check_mark: | :white_check_mark: | :white_check_mark: |
alloc | :white_check_mark: | ||
gpu | :white_check_mark: | ||
vram | :white_check_mark: | ||
fps | :white_check_mark: | :white_check_mark: | |
net_in/net_out | :white_check_mark: | :white_check_mark: | |
disk_read/disk_write | :white_check_mark: | ||
kobject | :white_check_mark: | :white_check_mark: | |
thread | :white_check_mark: | :white_check_mark: | |
sys_cpu | :white_check_mark: | :white_check_mark: | :white_check_mark: |
sys_cpu_freq | :white_check_mark: | :white_check_mark: | :white_check_mark: |
sys_cpu_temp | :white_check_mark: | :white_check_mark: | |
sys_gpu | :white_check_mark: | :white_check_mark: | |
sys_power | :white_check_mark: | :white_check_mark: |
Privileges
macOS | Windows | Linux | |
---|---|---|---|
cpu | |||
mem | |||
alloc | |||
gpu | |||
vram | |||
fps | Administrator + get-task-allow | Administrator | |
net_in/net_out | Administrator | ||
disk_read/disk_write | |||
kobject | |||
thread | |||
sys_cpu | |||
sys_cpu_freq | Administrator | ||
sys_cpu_temp | |||
sys_gpu | |||
sys_power | |||
system processes(WindowServer, dwm.exe, etc.) | Administrator | Administrator |
TODO
Related projects
- Rust
- Go
- Python