PTIME(1)
π PTIME(1) π
okay so bestie, welcome to ptime β she's a General Commands Manual girlie and her whole entire job is literally just timing a command. iconic behavior, no cap. β¨
πΈ NAME πΈ
ptime β time a command β±οΈ
π SYNOPSIS π
ptime command [arg]...
ptime -p pidlist
β¨ DESCRIPTION β¨
So like, if you don't pass -p, ptime runs the command you gave her with all the args you gave her, and then when that command is done-doing-its-thing, she writes the timing statistics to standard error. that's it, that's the whole vibe. π
If you do pass -p, she switches modes and shows you a snapshot of the accumulated timing statistics for the processes you named. main character energy fr fr.
the good stuff (aka when /proc/[pid]/schedstat is available): the output includes nanosecond-precision scheduling statistics, which is giving precision:
cpuβ on-CPU run timelatβ run-queue wait timeslpβ all other sleep time, computed as real minus cpu minus lat
...plus each component's percentage of real time. π
Now listen, a trailing * means the value came from a lower-precision source β but the percentages stay relative to real, so don't stress. π«Ά
With -p, both real and slp carry a trailing * because the process start time from /proc is recorded in clock ticks (typically 10ms granularity). and the user and sys values always carry a trailing * because they're derived from clock-tick counters when reading from /proc, or from microsecond-precision rusage when timing a command directly. π
heads up bestie: these values may not sum exactly to cpu. it's not a bug, it's just how the math math's. π
π OPTIONS π
-ppidlist β display a snapshot of timing statistics for the specified processes. the pidlist is a list of process IDs separated by commas, whitespace, or any combination of the two (e.g.,"1,2","1, 2","1 2"). slay. β¨
π¦ OPERANDS π¦
- command β the command to execute. go off king. π
- arg β arguments to the command. π
- pidlist β a list of process IDs separated by commas, whitespace, or any combination of the two. A
/proc/pidpath may also be used, which means shell expansions like/proc/*can target all processes on the system. (yes, ALL of them. she's brave like that. π§)
π EXIT STATUS π
okay so exit status tea, let's get into it:
- if the command is invoked successfully,
ptime(1)returns the exit status of the command β - if the command is terminated by a signal,
ptime(1)returns 128 plus the signal number π - if the command is not found,
ptime(1)returns 127 π - if the command is found but cannot be invoked,
ptime(1)returns 126 π - if an error occurs in
ptime(1)itself,ptime(1)returns 1 π«
π FILES π
/proc/pid/*β process information and control files. that's where the lore lives. π
β SEE ALSO β
time(1), proc(5) β go read those too, they're lowkey obsessed with each other.
made with love by ptime 0.2.23, dated September 2026 β that's the version and the date bestie, write it down, periodt. π stay timed, stay iconic, mwah πβ¨
π¦ where this page comes from
- fedora 44: ptools 0.2.23-1.fc44 Β· Apache-2.0 AND MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms