mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 841646 - Part 4: Allow parallel compilation while the SPS Profiler is active. r=jandem
This commit is contained in:
parent
599ba813a7
commit
a1352a9298
@ -1571,14 +1571,9 @@ OffThreadCompilationAvailable(JSContext *cx)
|
||||
// Skip off thread compilation if PC count profiling is enabled, as
|
||||
// CodeGenerator::maybeCreateScriptCounts will not attach script profiles
|
||||
// when running off thread.
|
||||
//
|
||||
// Also skip off thread compilation if the SPS profiler is enabled, as it
|
||||
// stores strings in the spsProfiler data structure, which is not protected
|
||||
// by a lock.
|
||||
return cx->runtime()->canUseParallelIonCompilation()
|
||||
&& cx->runtime()->gcIncrementalState == gc::NO_INCREMENTAL
|
||||
&& !cx->runtime()->profilingScripts
|
||||
&& !cx->runtime()->spsProfiler.enabled();
|
||||
&& !cx->runtime()->profilingScripts;
|
||||
}
|
||||
|
||||
static void
|
||||
@ -1735,8 +1730,7 @@ IonCompile(JSContext *cx, JSScript *script,
|
||||
Maybe<AutoProtectHeapForIonCompilation> protect;
|
||||
if (js_JitOptions.checkThreadSafety &&
|
||||
cx->runtime()->gcIncrementalState == gc::NO_INCREMENTAL &&
|
||||
!cx->runtime()->profilingScripts &&
|
||||
!cx->runtime()->spsProfiler.enabled())
|
||||
!cx->runtime()->profilingScripts)
|
||||
{
|
||||
protect.construct(cx->runtime());
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user