Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow --perf-prof and --perf-basic-prof in NODE_OPTIONS #17600

Closed
wants to merge 11 commits into from
2 changes: 2 additions & 0 deletions src/node.cc
Original file line number Diff line number Diff line change
Expand Up @@ -3595,6 +3595,8 @@ static void CheckIfAllowedInEnv(const char* exe, bool is_env,
"--force-fips",
"--openssl-config",
"--icu-data-dir",
"--perf-prof",
"--perf-basic-prof",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Move them below the comment and use underscores.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bnoordhuis Thank you for review !
I moved them under v8 options.


// V8 options (define with '_', which allows '-' or '_')
"--abort_on_uncaught_exception",
Expand Down
2 changes: 2 additions & 0 deletions test/parallel/test-cli-node-options.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ expect('--throw-deprecation', 'B\n');
expect('--zero-fill-buffers', 'B\n');
expect('--v8-pool-size=10', 'B\n');
expect('--trace-event-categories node', 'B\n');
expect('--perf-prof', 'B\n');
expect('--perf-basic-prof', 'B\n');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This needs to be wrapped in if (!common.isWindows)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I fixed it. Please re-run CI.


if (common.hasCrypto) {
expect('--use-openssl-ca', 'B\n');
Expand Down