Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fixup! cli: add --trace-atomics-wait flag
  • Loading branch information
addaleax authored May 8, 2020
commit f982160dc4504ccd2467bed06ca44dd0da8d3452
12 changes: 11 additions & 1 deletion doc/api/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -821,7 +821,7 @@ for TLSv1.2, which is not as secure as TLSv1.3.
added: REPLACEME
-->

Print short summaries of calls to `Atomics.wait()` to stderr.
Print short summaries of calls to [`Atomics.wait()`][] to stderr.
The output could look like this:

```text
Expand All @@ -835,6 +835,14 @@ The output could look like this:
[Thread 1] Atomics.wait(0x55d134fe4290 + 4, -1, inf) was woken up by another thread
Comment thread
jasnell marked this conversation as resolved.
Outdated
```

The fields here correspond to:

- The thread id as given by [`worker_threads.threadId`][]
- The base address of the `SharedArrayBuffer` in question, as well as the
byte offset corresponding to the index passed to `Atomics.wait()`
- The expected value that was passed to `Atomics.wait()`
- The timeout passed to `Atomics.wait`

### `--trace-deprecation`
<!-- YAML
added: v0.8.0
Expand Down Expand Up @@ -1494,12 +1502,14 @@ $ node --max-old-space-size=1536 index.js
```

[`--openssl-config`]: #cli_openssl_config_file
[`Atomics.wait()`]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/wait
[`Buffer`]: buffer.html#buffer_class_buffer
[`SlowBuffer`]: buffer.html#buffer_class_slowbuffer
[`process.setUncaughtExceptionCaptureCallback()`]: process.html#process_process_setuncaughtexceptioncapturecallback_fn
[`tls.DEFAULT_MAX_VERSION`]: tls.html#tls_tls_default_max_version
[`tls.DEFAULT_MIN_VERSION`]: tls.html#tls_tls_default_min_version
[`unhandledRejection`]: process.html#process_event_unhandledrejection
[`worker_threads.threadId`]: worker_threads.html##worker_threads_worker_threadid
[Chrome DevTools Protocol]: https://chromedevtools.github.io/devtools-protocol/
[REPL]: repl.html
[ScriptCoverage]: https://chromedevtools.github.io/devtools-protocol/tot/Profiler#type-ScriptCoverage
Expand Down