tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

commit 9ffc93a74c33a792e9ed5574ad6e8c3a1418caf1
parent 69d9edab72b850256b85d3e51f1d15a2b6559407
Author: Nazım Can Altınova <canaltinova@gmail.com>
Date:   Tue, 21 Oct 2025 21:15:35 +0000

Bug 1979114 - Add a new JS sources feature to the profiler r=mstange,profiler-reviewers

I add this feature now, so I can use it in the following patch when we
are retrieving the JS sources from the JS engine.

This feature is currently not on by default until we iron out all the
issues and defails.

Differential Revision: https://phabricator.services.mozilla.com/D259266

Diffstat:
Mdevtools/client/performance-new/shared/utils.js | 6++++++
Mmozglue/baseprofiler/public/BaseProfilerState.h | 5++++-
Mtoolkit/components/extensions/schemas/geckoProfiler.json | 3++-
Mtools/profiler/public/ProfilerState.h | 5++++-
4 files changed, 16 insertions(+), 3 deletions(-)

diff --git a/devtools/client/performance-new/shared/utils.js b/devtools/client/performance-new/shared/utils.js @@ -573,6 +573,12 @@ const featureDescriptions = [ "Include all flow-related markers. These markers show the program flow better but " + "can cause more overhead in some places than normal.", }, + { + name: "JavaScript Sources", + value: "jssources", + title: "Collect JavaScript source code information for profiled scripts.", + experimental: true, + }, ]; module.exports = { diff --git a/mozglue/baseprofiler/public/BaseProfilerState.h b/mozglue/baseprofiler/public/BaseProfilerState.h @@ -254,7 +254,10 @@ class MOZ_RAII AutoProfilerStats { \ MACRO(27, "flows", Flows, \ "Include all flow-related markers. These markers show the program" \ - "better but can cause more overhead in some places than normal.") + "better but can cause more overhead in some places than normal.") \ + \ + MACRO(28, "jssources", JSSources, \ + "Collect JavaScript source code information for profiled scripts.") // *** Synchronize with lists in ProfilerState.h and geckoProfiler.json *** diff --git a/toolkit/components/extensions/schemas/geckoProfiler.json b/toolkit/components/extensions/schemas/geckoProfiler.json @@ -51,7 +51,8 @@ "memory", "tracing", "sandbox", - "flows" + "flows", + "jssources" ] }, { diff --git a/tools/profiler/public/ProfilerState.h b/tools/profiler/public/ProfilerState.h @@ -135,7 +135,10 @@ \ MACRO(27, "flows", Flows, \ "Include all flow-related markers. These markers show the program" \ - "better but can cause more overhead in some places than normal.") + "better but can cause more overhead in some places than normal.") \ + \ + MACRO(28, "jssources", JSSources, \ + "Collect JavaScript source code information for profiled scripts.") // *** Synchronize with lists in BaseProfilerState.h and geckoProfiler.json ***