mirror of
https://github.com/uutils/coreutils
synced 2024-12-14 15:22:38 +00:00
shuf: document new benchmark category
This commit is contained in:
parent
352a8a5bd7
commit
f25b2102db
1 changed files with 12 additions and 3 deletions
|
@ -28,11 +28,11 @@ a range of numbers to randomly sample from. An example of a command that works
|
|||
well for testing:
|
||||
|
||||
```shell
|
||||
hyperfine --warmup 10 "target/release/shuf -i 0-10000000"
|
||||
hyperfine --warmup 10 "target/release/shuf -i 0-10000000 > /dev/null"
|
||||
```
|
||||
|
||||
To measure the time taken by shuffling an input file, the following command can
|
||||
be used::
|
||||
be used:
|
||||
|
||||
```shell
|
||||
hyperfine --warmup 10 "target/release/shuf input.txt > /dev/null"
|
||||
|
@ -49,5 +49,14 @@ should be benchmarked separately. In this case, we have to pass the `-n` flag or
|
|||
the command will run forever. An example of a hyperfine command is
|
||||
|
||||
```shell
|
||||
hyperfine --warmup 10 "target/release/shuf -r -n 10000000 -i 0-1000"
|
||||
hyperfine --warmup 10 "target/release/shuf -r -n 10000000 -i 0-1000 > /dev/null"
|
||||
```
|
||||
|
||||
## With huge interval ranges
|
||||
|
||||
When `shuf` runs with huge interval ranges, special care must be taken, so it
|
||||
should be benchmarked separately also. An example of a hyperfine command is
|
||||
|
||||
```shell
|
||||
hyperfine --warmup 10 "target/release/shuf -n 100 -i 1000-2000000000 > /dev/null"
|
||||
```
|
||||
|
|
Loading…
Reference in a new issue