Skip to content

Commit 2274d0c

Browse files
thisalihassanmarco-ippolito
authored andcommittedMay 3, 2024
benchmark: inherit stdio/stderr instead of pipe
PR-URL: #52456 Fixes: #52233 Refs: nodejs/performance#161 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Raz Luvaton <rluvaton@gmail.com>
1 parent 0300598 commit 2274d0c

File tree

2 files changed

+2
-8
lines changed

2 files changed

+2
-8
lines changed
 

‎benchmark/compare.js

+1-4
Original file line numberDiff line numberDiff line change
@@ -83,11 +83,8 @@ if (showProgress) {
8383
const spawnArgs = ['-c', cpuCore, cli.optional[job.binary], resolvedPath, ...cli.optional.set];
8484
child = spawn('taskset', spawnArgs, {
8585
env: process.env,
86-
stdio: ['inherit', 'pipe', 'pipe', 'ipc'],
86+
stdio: ['inherit', 'inherit', 'inherit', 'ipc'],
8787
});
88-
89-
child.stdout.pipe(process.stdout);
90-
child.stderr.pipe(process.stderr);
9188
} else {
9289
child = fork(resolvedPath, cli.optional.set, {
9390
execPath: cli.optional[job.binary],

‎benchmark/run.js

+1-4
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,8 @@ if (format === 'csv') {
5454
let child;
5555
if (cpuCore !== null) {
5656
child = spawn('taskset', ['-c', cpuCore, 'node', scriptPath, ...args], {
57-
stdio: ['inherit', 'pipe', 'pipe', 'ipc'],
57+
stdio: ['inherit', 'inherit', 'inherit', 'ipc'],
5858
});
59-
60-
child.stdout.pipe(process.stdout);
61-
child.stderr.pipe(process.stderr);
6259
} else {
6360
child = fork(
6461
scriptPath,

0 commit comments

Comments
 (0)
Please sign in to comment.