v8/src/inspector
Seth Brenith 3d59a3c2c1 Add option to report discarded allocations in sampling heap profiler
A couple of customers have asked about using devtools to get information
about temporary allocations, with the goal of reducing GC time and/or
peak memory usage. Currently, the sampling heap profiler reports only
objects which are still alive at the end of the profiling session. In
this change, I propose adding configuration options when starting the
sampling heap profiler so that it can optionally include information
about objects which were discarded by the GC before the end of the
profiling session. A user could run the sampling heap profiler in
several different modes depending on their goals:

1. To find memory leaks or determine which functions contribute most to
   steady-state memory consumption, the current default mode is best.
2. To find functions which cause large temporary memory spikes or large
   GC pauses, the user can request data about both live objects and
   those collected by major GC.
3. To tune for minimal GC activity in latency-sensitive applications
   like real-time audio processing, the user can request data about
   every allocation, including objects collected by major or minor GC.
4. I'm not sure why anybody would want data about objects collected by
   minor GC and not objects collected by major GC, but it's also a valid
   flags combination.

Change-Id: If55d5965a1de04fed3ae640a02ca369723f64fdf
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3868522
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Simon Zünd <szuend@chromium.org>
Commit-Queue: Seth Brenith <seth.brenith@microsoft.com>
Cr-Commit-Position: refs/heads/main@{#83202}
2022-09-14 17:39:12 +00:00
..
BUILD.gn Reland "Build cctest while building V8" 2022-06-13 16:05:50 +00:00
custom-preview.cc Reland "[include] Split out v8.h" 2021-08-24 13:08:55 +00:00
custom-preview.h [iwyu] Add missing includes of <memory> for std::unique_ptr 2019-09-13 17:13:36 +00:00
DEPS Add support for source hashing in stack traces. 2022-05-03 00:57:46 +00:00
DIR_METADATA Add DIR_METADATA files to v8. 2020-10-20 22:12:28 +00:00
injected-script.cc Disable command-line API for untrusted inspector clients. 2022-06-01 09:37:58 +00:00
injected-script.h [inspector] Don't trigger window.onerror with side-effects disabled. 2022-05-23 13:50:57 +00:00
inspected-context.cc Add V8Inspector::uniqueDebuggerId method 2022-02-04 18:23:05 +00:00
inspected-context.h Add V8Inspector::uniqueDebuggerId method 2022-02-04 18:23:05 +00:00
inspector_protocol_config.json [bazel] Generate inspector files using @rules_python. 2022-01-10 13:32:28 +00:00
OWNERS Add jarin@ to inspector and debug OWNERS. 2021-10-18 07:27:48 +00:00
remote-object-id.cc [inspector] Prepend isolateId to remoteObjectId 2020-10-18 10:39:57 +00:00
remote-object-id.h [inspector] Prepend isolateId to remoteObjectId 2020-10-18 10:39:57 +00:00
search-util.cc [clang-tidy] Reserve space in vectors before pushing 2021-01-26 13:06:09 +00:00
search-util.h [cleanup] Consistent comments on namespace ends 2020-08-17 10:09:02 +00:00
string-16.cc Roll inspector_protocol to 5221cbfa7f940d56ae8b79bf34c446a56781dd56 2022-01-24 09:16:35 +00:00
string-16.h Roll inspector_protocol to 5221cbfa7f940d56ae8b79bf34c446a56781dd56 2022-01-24 09:16:35 +00:00
string-util.cc Roll inspector_protocol to 5221cbfa7f940d56ae8b79bf34c446a56781dd56 2022-01-24 09:16:35 +00:00
string-util.h Disable command-line API for untrusted inspector clients. 2022-06-01 09:37:58 +00:00
test-interface.cc [inspector] removed kDebugPromiseCollected event 2017-04-20 15:49:02 +00:00
test-interface.h Reland "[include] Split out v8.h" 2021-08-24 13:08:55 +00:00
v8-console-agent-impl.cc [inspector] Decouple Console domain from stack trace capturing. 2021-12-30 10:11:51 +00:00
v8-console-agent-impl.h [cleanup][inspector] Remove DISALLOW_COPY_AND_ASSIGN 2020-11-18 01:12:38 +00:00
v8-console-message.cc [inspector] Consistently format value wrappers in console messages. 2022-05-03 06:41:38 +00:00
v8-console-message.h Reland "[include] Split out v8.h" 2021-08-24 13:08:55 +00:00
v8-console.cc [inspector] Add use counter for async stack tagging API 2022-09-14 16:36:29 +00:00
v8-console.h [inspector] Rename console.scheduleTask to console.createTask 2022-07-27 06:09:27 +00:00
v8-debugger-agent-impl.cc [wasm][devtools] Fix reported function body offsets 2022-07-22 10:08:32 +00:00
v8-debugger-agent-impl.h [wasm] Expose disassembler to DevTools 2022-07-19 17:43:16 +00:00
v8-debugger-id.cc Add V8Inspector::uniqueDebuggerId method 2022-02-04 18:23:05 +00:00
v8-debugger-id.h Add V8Inspector::uniqueDebuggerId method 2022-02-04 18:23:05 +00:00
v8-debugger-script.cc [wasm][devtools] Fix reported function body offsets 2022-07-22 10:08:32 +00:00
v8-debugger-script.h [wasm][devtools] Fix reported function body offsets 2022-07-22 10:08:32 +00:00
v8-debugger.cc [inspector] Introduce instrumentation pause distinction 2022-09-01 05:22:16 +00:00
v8-debugger.h [debug] Implement 'PrepareRestartFrame' 2022-04-29 07:09:19 +00:00
v8-heap-profiler-agent-impl.cc Add option to report discarded allocations in sampling heap profiler 2022-09-14 17:39:12 +00:00
v8-heap-profiler-agent-impl.h Add option to report discarded allocations in sampling heap profiler 2022-09-14 17:39:12 +00:00
v8-inspector-impl.cc Fix uniqueDebuggerId so that it returns debugger id, not the context id 2022-05-31 15:45:58 +00:00
v8-inspector-impl.h [inspector] Implement Async Stack Tagging API v2 2022-07-22 06:28:24 +00:00
v8-inspector-session-impl.cc Enable Profiler domain for the untrusted clients. 2022-09-09 05:03:01 +00:00
v8-inspector-session-impl.h Disable command-line API for untrusted inspector clients. 2022-06-01 09:37:58 +00:00
v8-profiler-agent-impl.cc [base] Remove TimeTicks::HighResolutionNow 2022-02-04 13:27:14 +00:00
v8-profiler-agent-impl.h Revert "[DevTools] Implemented DevTools protocol API to retrieve V8 RunTime Call Stats." 2021-08-16 09:46:43 +00:00
v8-regex.cc Reland "[include] Split out v8.h" 2021-08-24 13:08:55 +00:00
v8-regex.h Reland "[include] Split out v8.h" 2021-08-24 13:08:55 +00:00
v8-runtime-agent-impl.cc [api] Deprecate PersistentValueVector 2022-06-09 08:44:13 +00:00
v8-runtime-agent-impl.h Add WebDriverBiDi serialization to CDP 2022-04-11 15:51:54 +00:00
v8-schema-agent-impl.cc [DevTools] Roll inspector_protocol (V8) 2020-03-20 19:21:22 +00:00
v8-schema-agent-impl.h [cleanup][inspector] Remove DISALLOW_COPY_AND_ASSIGN 2020-11-18 01:12:38 +00:00
v8-stack-trace-impl.cc [debug] Implement stepping out of async functions in the debugger. 2022-02-08 06:32:16 +00:00
v8-stack-trace-impl.h [debug] Implement stepping out of async functions in the debugger. 2022-02-08 06:32:16 +00:00
v8-string-conversions.cc [cleanup][debug][inspector] Remove redundant NOLINT annotations 2021-04-30 11:57:49 +00:00
v8-string-conversions.h [DevTools] Extract UTF8<->UTF16 routines from string-16{.h,.cc}. 2019-05-08 21:20:33 +00:00
v8-value-utils.cc Reland "[include] Split out v8.h" 2021-08-24 13:08:55 +00:00
v8-value-utils.h Reland "[include] Split out v8.h" 2021-08-24 13:08:55 +00:00
v8-webdriver-serializer.cc Fix Date BiDi format 2022-07-11 17:19:43 +00:00
v8-webdriver-serializer.h Follow-up after https://crrev.com/c/3472077 2022-05-02 09:54:03 +00:00
value-mirror.cc [inspector] Fix crash when building preview with a proxy prototype 2022-08-16 13:19:33 +00:00
value-mirror.h Follow-up after https://crrev.com/c/3472077 2022-05-02 09:54:03 +00:00