Skip to content

Commit 1a2762b

Browse files
committed
Update benchmarks with new createChildProcess API
1 parent abbc624 commit 1a2762b

2 files changed

Lines changed: 2 additions & 3 deletions

File tree

benchmark/process_loop.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ node.mixin(require("/utils.js"));
44
function next (i) {
55
if (i <= 0) return;
66

7-
var child = node.createChildProcess("echo hello");
7+
var child = node.createChildProcess("echo", ["hello"]);
88

99
child.addListener("output", function (chunk) {
1010
if (chunk) print(chunk);

benchmark/run.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,8 @@ var benchmarks = [ "static_http_server.js"
99
var benchmark_dir = node.path.dirname(__filename);
1010

1111
function exec (script, callback) {
12-
var command = ARGV[0] + " " + node.path.join(benchmark_dir, script);
1312
var start = new Date();
14-
var child = node.createChildProcess(command);
13+
var child = node.createChildProcess(ARGV[0], [node.path.join(benchmark_dir, script)]);
1514
child.addListener("exit", function (code) {
1615
var elapsed = new Date() - start;
1716
callback(elapsed, code);

0 commit comments

Comments
 (0)