summaryrefslogtreecommitdiff
path: root/benchmark-cmd.1.in
blob: 275dc0cfffb39738efc11e0c624540ef01b7cd09 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
.\" Copyright 2011 Lars Wirzenius <liw@liw.fi>
.\" 
.\" This program is free software: you can redistribute it and/or modify
.\" it under the terms of the GNU General Public License as published by
.\" the Free Software Foundation, either version 3 of the License, or
.\" (at your option) any later version.
.\" 
.\" This program is distributed in the hope that it will be useful,
.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
.\" GNU General Public License for more details.
.\" 
.\" You should have received a copy of the GNU General Public License
.\" along with this program.  If not, see <http://www.gnu.org/licenses/>.
.\"
.TH BENCHMARK-CMD 1
.SH NAME
benchmark-cmd \- benchmark shell commands
.SH SYNOPSIS
.SH DESCRIPTION
.B benchmark-cmd
benchmarks one or more Unix shell commands.
It runs some setup commands,
then the actual command,
and then some cleanup commands,
and can do this for several actual commands.
It then reports the timing results for each actual command.
.SH OPTIONS
.SH EXAMPLE
To see whether
.BR ls (1)
or
.BR find (1)
is faster:
.IP
.nf
$ benchmark-cmd --command='ls -lAR $HOME' \\
    --command='find $HOME -ls'
real  user  system  max RSS  elapsed  cmd                    
 (s)   (s)     (s)    (KiB)      (s)                         
 0.4   1.0     1.4     8608      1.4  ls -lAR $HOME
 0.4   0.4     0.8     8400      0.8  find  $HOME -ls