summaryrefslogtreecommitdiff
path: root/benchmark
diff options
context:
space:
mode:
Diffstat (limited to 'benchmark')
-rw-r--r--benchmark/common.js4
1 files changed, 4 insertions, 0 deletions
diff --git a/benchmark/common.js b/benchmark/common.js
index b4778d7193..6a3be4fc37 100644
--- a/benchmark/common.js
+++ b/benchmark/common.js
@@ -25,6 +25,10 @@ function Benchmark(fn, configs, options) {
if (options && options.flags) {
this.flags = this.flags.concat(options.flags);
}
+ if (process.env.NODE_BENCHMARK_FLAGS) {
+ const flags = process.env.NODE_BENCHMARK_FLAGS.split(/\s+/);
+ this.flags = this.flags.concat(flags);
+ }
// Holds process.hrtime value
this._time = [0, 0];
// Used to make sure a benchmark only start a timer once