Skip to content

Commit

Permalink
test(NODE-5692): new benchmarks using bson-bench (#636)
Browse files Browse the repository at this point in the history
  • Loading branch information
W-A-James authored Nov 20, 2023
1 parent 77fac2a commit a382485
Show file tree
Hide file tree
Showing 134 changed files with 198,913 additions and 652 deletions.
38 changes: 31 additions & 7 deletions .evergreen/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,15 +94,24 @@ functions:
PROJECT_DIRECTORY: ${PROJECT_DIRECTORY}
args:
- .evergreen/run-bundling-test.sh
run benchmarks:
run granular benchmarks:
- command: subprocess.exec
type: test
params:
working_dir: src
binary: bash
add_expansions_to_env: true
args:
- .evergreen/run-benchmarks.sh
- .evergreen/run-granular-benchmarks.sh
run spec benchmarks:
- command: subprocess.exec
type: test
params:
working_dir: src
binary: bash
add_expansions_to_env: true
args:
- .evergreen/run-spec-benchmarks.sh
tasks:
- name: node-tests-v16
tags: ["node"]
Expand Down Expand Up @@ -211,7 +220,7 @@ tasks:
vars:
TS_VERSION: "next"
TRY_COMPILING_LIBRARY: "false"
- name: run-benchmarks-node-18
- name: run-granular-benchmarks-node-18
commands:
- func: fetch source
vars:
Expand All @@ -220,12 +229,26 @@ tasks:
- func: install dependencies
vars:
NPM_VERSION: 9
- func: run benchmarks
- func: run granular benchmarks
vars:
WEB: false
WARMUP: 1000
ITERATIONS: 1000
- command: perf.send
params:
file: src/test/bench/etc/resultsCollected.json
- name: run-spec-benchmarks-node-18
commands:
- func: fetch source
vars:
# This needs to stay pinned at Node v18.16.0 for consistency across perf runs.
NODE_LTS_VERSION: v18.16.0
- func: install dependencies
vars:
NPM_VERSION: 9
- func: run spec benchmarks
- command: perf.send
params:
file: src/benchmarks.json
file: src/bsonBench.json
- name: check-eslint-plugin
commands:
- func: fetch source
Expand All @@ -252,4 +275,5 @@ buildvariants:
display_name: RHEL 9.0 perf
run_on: rhel90-dbx-perf-large
tasks:
- run-benchmarks-node-18
- run-granular-benchmarks-node-18
- run-spec-benchmarks-node-18
8 changes: 8 additions & 0 deletions .evergreen/run-granular-benchmarks.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/usr/bin/env bash

source "${PROJECT_DIRECTORY}/.evergreen/init-node-and-npm-env.sh"
set -o xtrace
WARMUP=$WARMUP
ITERATIONS=$ITERATIONS

WARMUP=$WARMUP ITERATIONS=$ITERATIONS npm run check:granular-bench
2 changes: 1 addition & 1 deletion .evergreen/run-benchmarks.sh → .evergreen/run-spec-benchmarks.sh
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@

source "${PROJECT_DIRECTORY}/.evergreen/init-node-and-npm-env.sh"

npm run check:bench
npm run check:spec-bench
6 changes: 0 additions & 6 deletions etc/benchmarks/bson_versions.json

This file was deleted.

52 changes: 0 additions & 52 deletions etc/benchmarks/convert_to_csv.sh

This file was deleted.

11 changes: 0 additions & 11 deletions etc/benchmarks/install_bson_versions.sh

This file was deleted.

152 changes: 0 additions & 152 deletions etc/benchmarks/lib_runner.mjs

This file was deleted.

Loading

0 comments on commit a382485

Please sign in to comment.