mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 855037 - JäegerMonkey: Check if there is an helper thread for Ion compilation. r=dvander
This commit is contained in:
parent
118ccf59eb
commit
ddf8f742a1
@ -25,6 +25,7 @@
|
||||
#include "InlineFrameAssembler.h"
|
||||
#include "jscompartment.h"
|
||||
#include "jsopcodeinlines.h"
|
||||
#include "jsworkers.h"
|
||||
|
||||
#include "builtin/RegExp.h"
|
||||
#include "vm/RegExpStatics.h"
|
||||
@ -965,7 +966,7 @@ IonGetsFirstChance(JSContext *cx, JSScript *script, jsbytecode *pc, CompileReque
|
||||
// let JM take over until the PC is reached. Don't do this until the script
|
||||
// reaches a high use count, as if we do this prematurely we may get stuck
|
||||
// in JM code.
|
||||
if (ion::js_IonOptions.parallelCompilation && script->hasIonScript() &&
|
||||
if (OffThreadCompilationEnabled(cx) && script->hasIonScript() &&
|
||||
pc && script->ionScript()->osrPc() && script->ionScript()->osrPc() != pc &&
|
||||
script->getUseCount() >= ion::js_IonOptions.usesBeforeCompile * 2)
|
||||
{
|
||||
@ -4064,7 +4065,7 @@ mjit::Compiler::ionCompileHelper()
|
||||
#endif
|
||||
|
||||
stubcc.linkExitDirect(trigger.inlineJump,
|
||||
ion::js_IonOptions.parallelCompilation
|
||||
OffThreadCompilationEnabled(cx)
|
||||
? secondTest
|
||||
: trigger.stubLabel);
|
||||
|
||||
|
@ -16,6 +16,7 @@
|
||||
#include "jsbool.h"
|
||||
#include "assembler/assembler/MacroAssemblerCodeRef.h"
|
||||
#include "jstypes.h"
|
||||
#include "jsworkers.h"
|
||||
|
||||
#include "gc/Marking.h"
|
||||
#include "ion/AsmJS.h"
|
||||
@ -776,7 +777,7 @@ stubs::TriggerIonCompile(VMFrame &f)
|
||||
{
|
||||
RootedScript script(f.cx, f.script());
|
||||
|
||||
if (ion::js_IonOptions.parallelCompilation && !f.cx->runtime->profilingScripts) {
|
||||
if (OffThreadCompilationEnabled(f.cx) && !f.cx->runtime->profilingScripts) {
|
||||
if (script->hasIonScript()) {
|
||||
/*
|
||||
* Normally TriggerIonCompile is not called if !script->ion, but the
|
||||
|
Loading…
Reference in New Issue
Block a user