mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-23 12:51:06 +00:00
Backed out 2 changesets (bug 1883457) for causing build bustages on StaticPrefList.yaml CLOSED TREE
Backed out changeset 2dbe5fbe8f16 (bug 1883457) Backed out changeset f608ec3ab50e (bug 1883457)
This commit is contained in:
parent
34e332a374
commit
8bbd9e9ed6
@ -591,14 +591,13 @@ set_define("MOZ_AARCH64_JSCVT", aarch64_jscvt)
|
||||
|
||||
|
||||
@depends(target)
|
||||
def has_apple_fast_wx(target):
|
||||
return target.kernel == "Darwin" and target.cpu == "aarch64"
|
||||
def has_pthread_jit_write_protect_np(target):
|
||||
return target.os == "OSX" and target.cpu == "aarch64"
|
||||
|
||||
|
||||
# On Apple Silicon macOS we use MAP_JIT with pthread_jit_write_protect_np to
|
||||
# implement JIT code write protection, while on iOS we use MAP_JIT with
|
||||
# be_memory_inline_jit_restrict_*.
|
||||
set_define("JS_USE_APPLE_FAST_WX", True, when=has_apple_fast_wx)
|
||||
# On Apple Silicon we use MAP_JIT with pthread_jit_write_protect_np to implement
|
||||
# JIT code write protection.
|
||||
set_define("JS_USE_APPLE_FAST_WX", True, when=has_pthread_jit_write_protect_np)
|
||||
|
||||
|
||||
# CTypes
|
||||
|
@ -447,8 +447,7 @@ void DefaultJitOptions::resetNormalIonWarmUpThreshold() {
|
||||
|
||||
void DefaultJitOptions::maybeSetWriteProtectCode(bool val) {
|
||||
#ifdef JS_USE_APPLE_FAST_WX
|
||||
// On Apple Silicon we always use pthread_jit_write_protect_np, or
|
||||
// be_memory_inline_jit_restrict_*.
|
||||
// On Apple Silicon we always use pthread_jit_write_protect_np.
|
||||
MOZ_ASSERT(!writeProtectCode);
|
||||
#else
|
||||
writeProtectCode = val;
|
||||
|
@ -46,10 +46,6 @@
|
||||
# include <valgrind/valgrind.h>
|
||||
#endif
|
||||
|
||||
#if defined(XP_IOS)
|
||||
# include <BrowserEngineCore/BEMemory.h>
|
||||
#endif
|
||||
|
||||
using namespace js;
|
||||
using namespace js::jit;
|
||||
|
||||
@ -994,19 +990,11 @@ bool js::jit::ReprotectRegion(void* start, size_t size,
|
||||
#ifdef JS_USE_APPLE_FAST_WX
|
||||
void js::jit::AutoMarkJitCodeWritableForThread::markExecutable(
|
||||
bool executable) {
|
||||
# if defined(XP_IOS)
|
||||
if (executable) {
|
||||
be_memory_inline_jit_restrict_rwx_to_rx_with_witness();
|
||||
} else {
|
||||
be_memory_inline_jit_restrict_rwx_to_rw_with_witness();
|
||||
}
|
||||
# else
|
||||
if (__builtin_available(macOS 11.0, *)) {
|
||||
pthread_jit_write_protect_np(executable);
|
||||
} else {
|
||||
MOZ_CRASH("pthread_jit_write_protect_np must be available");
|
||||
}
|
||||
# endif
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -7955,12 +7955,6 @@
|
||||
value: false
|
||||
mirror: always
|
||||
|
||||
# Whether to disable the jit within the main process
|
||||
- name: javascript.options.main_process_disable_jit
|
||||
type: bool
|
||||
value: @IS_IOS@
|
||||
mirror: always
|
||||
|
||||
#---------------------------------------------------------------------------
|
||||
# Prefs starting with "layers."
|
||||
#---------------------------------------------------------------------------
|
||||
|
@ -233,11 +233,6 @@ 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;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user