diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:34:42 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:34:42 +0000 |
commit | da4c7e7ed675c3bf405668739c3012d140856109 (patch) | |
tree | cdd868dba063fecba609a1d819de271f0d51b23e /xpcom/build/XPCOMInit.cpp | |
parent | Adding upstream version 125.0.3. (diff) | |
download | firefox-da4c7e7ed675c3bf405668739c3012d140856109.tar.xz firefox-da4c7e7ed675c3bf405668739c3012d140856109.zip |
Adding upstream version 126.0.upstream/126.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'xpcom/build/XPCOMInit.cpp')
-rw-r--r-- | xpcom/build/XPCOMInit.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/xpcom/build/XPCOMInit.cpp b/xpcom/build/XPCOMInit.cpp index 4d6572a501..6275ca9c53 100644 --- a/xpcom/build/XPCOMInit.cpp +++ b/xpcom/build/XPCOMInit.cpp @@ -233,6 +233,11 @@ static void InitializeJS() { JS::SetAVXEnabled(mozilla::StaticPrefs::javascript_options_wasm_simd_avx()); #endif + if (XRE_IsParentProcess() && + mozilla::StaticPrefs::javascript_options_main_process_disable_jit()) { + JS::DisableJitBackend(); + } + // Set all JS::Prefs. SET_JS_PREFS_FROM_BROWSER_PREFS; @@ -320,6 +325,8 @@ NS_InitXPCOM(nsIServiceManager** aResult, nsIFile* aBinDirectory, if (NS_WARN_IF(NS_FAILED(rv))) { return rv; } + + // Initialise the profiler AUTO_PROFILER_INIT2; // Set up the timer globals/timer thread @@ -459,6 +466,11 @@ NS_InitXPCOM(nsIServiceManager** aResult, nsIFile* aBinDirectory, // to the directory service. nsDirectoryService::gService->RegisterCategoryProviders(); + // Now that both the profiler and directory services have been started + // we can find the download directory, where the profiler can write + // profiles if necessary + profiler_lookup_download_directory(); + // Init mozilla::SharedThreadPool (which needs the service manager). mozilla::SharedThreadPool::InitStatics(); |