333
schangxiang@126.com
2025-09-19 18966e02fb573c7e2bb0c6426ed792b38b910940
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
# Tedious Benchmarks
 
This folder contains a collection of benchmarks for `tedious`.
 
Running all existing benchmarks is easy, just execute the following from
inside the `tedious` root folder:
 
```sh
node benchmarks
```
 
**NOTE:** The benchmarks try to load `tedious` code from `lib`, so make sure
you run `npm run prepublish` first.
 
This will serially execute every available benchmark test in a
seperate Node.js process. Running each benchmark in a separate process
ensures that each benchmark is run with a clean slate.
 
You can also execute a specific benchmarks:
 
```sh
node benchmarks/<type>/<benchmark-name>
```
 
The benchmarks are executed by using the `benchmark` module. Unfortunately,
this module can add a bit of useless noise when trying to collect profiling
information. To reduce this noise, benchmarks can be run in a special "profile"
mode. This will execute the benchmark's code without making use of `benchmark`
library and with a fixed number of iterations.
 
```sh
node benchmarks/<type>/<benchmark-name> --profile
```