time: Accuracy

1 
1 1.5 Accuracy
1 ============
1 
1 The elapsed time is not collected atomically with the execution of the
1 program; as a result, in bizarre circumstances (if the 'time' command
1 gets stopped or swapped out in between when the program being timed
1 exits and when 'time' calculates how long it took to run), it could be
1 much larger than the actual execution time.
1 
1    When the running time of a command is very nearly zero, some values
1 (e.g., the percentage of CPU used) may be reported as either zero (which
1 is wrong) or a question mark.
1 
1    Most information shown by 'time' is derived from the 'wait3' system
1 call.  The numbers are only as good as those returned by 'wait3'.  Many
1 systems do not measure all of the resources that 'time' can report on;
1 those resources are reported as zero.  The systems that measure most or
1 all of the resources are based on 4.2 or 4.3BSD. Later BSD releases use
1 different memory management code that measures fewer resources.
1 
1    On systems that do not have a 'wait3' call that returns status
1 information, the 'times' system call is used instead.  It provides much
1 less information than 'wait3', so on those systems 'time' reports most
1 of the resources as zero.
1 
1    The '%I' and '%O' values are allegedly only "real" input and output
1 and do not include those supplied by caching devices.  The meaning of
1 "real" I/O reported by '%I' and '%O' may be muddled for workstations,
1 especially diskless ones.
1