summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Gallacher <tomgallacher23@gmail.com>2019-01-18 16:30:10 +0000
committerAnna Henningsen <anna@addaleax.net>2019-02-08 14:43:18 +0100
commitf265225c19ddd9b63472d5ddcdc9f6ff8edae866 (patch)
tree9cad17105b65900fdc56c38ef2cc8054c35545ca
parentf5b9a782a9a4c6402ec3cc855efd0768595dfe1d (diff)
downloadandroid-node-v8-f265225c19ddd9b63472d5ddcdc9f6ff8edae866.tar.gz
android-node-v8-f265225c19ddd9b63472d5ddcdc9f6ff8edae866.tar.bz2
android-node-v8-f265225c19ddd9b63472d5ddcdc9f6ff8edae866.zip
src: allow --perf-prof-unwinding-info in NODE_OPTIONS
PR-URL: https://github.com/nodejs/node/pull/25565 Reviewed-By: Sam Roberts <vieuxtech@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: James M Snell <jasnell@gmail.com>
-rw-r--r--doc/api/cli.md1
-rw-r--r--src/node_options.cc4
-rw-r--r--test/parallel/test-cli-node-options.js1
3 files changed, 6 insertions, 0 deletions
diff --git a/doc/api/cli.md b/doc/api/cli.md
index 734e80d558..5e817eaa1d 100644
--- a/doc/api/cli.md
+++ b/doc/api/cli.md
@@ -730,6 +730,7 @@ V8 options that are allowed are:
- `--perf-basic-prof`
- `--perf-basic-prof-only-functions`
- `--perf-prof`
+- `--perf-prof-unwinding-info`
- `--stack-trace-limit`
### `NODE_PATH=path[:…]`
diff --git a/src/node_options.cc b/src/node_options.cc
index 7b678e549a..e68487a2bf 100644
--- a/src/node_options.cc
+++ b/src/node_options.cc
@@ -322,6 +322,10 @@ PerIsolateOptionsParser::PerIsolateOptionsParser() {
V8Option{},
kAllowedInEnvironment);
AddOption("--perf-prof", "", V8Option{}, kAllowedInEnvironment);
+ AddOption("--perf-prof-unwinding-info",
+ "",
+ V8Option{},
+ kAllowedInEnvironment);
AddOption("--stack-trace-limit", "", V8Option{}, kAllowedInEnvironment);
#ifdef NODE_REPORT
diff --git a/test/parallel/test-cli-node-options.js b/test/parallel/test-cli-node-options.js
index 1554e80c0b..8f65a8cb7e 100644
--- a/test/parallel/test-cli-node-options.js
+++ b/test/parallel/test-cli-node-options.js
@@ -44,6 +44,7 @@ if (!common.isWindows) {
if (common.isLinux && ['arm', 'x64'].includes(process.arch)) {
// PerfJitLogger is only implemented in Linux.
expect('--perf-prof', 'B\n');
+ expect('--perf-prof-unwinding-info', 'B\n');
}
if (common.hasCrypto) {