зеркало из https://github.com/mozilla/gecko-dev.git
Only inline scripts which have already been analyzed, bug 687125. r=dvander
This commit is contained in:
Родитель
b1df0ef43b
Коммит
15ecf1e097
|
@ -312,6 +312,17 @@ mjit::Compiler::scanInlineCalls(uint32 index, uint32 depth)
|
|||
}
|
||||
JSScript *script = fun->script();
|
||||
|
||||
/*
|
||||
* Don't inline calls to scripts which haven't been analyzed.
|
||||
* We need to analyze the inlined scripts to compile them, and
|
||||
* doing so can change type information we have queried already
|
||||
* in making inlining decisions.
|
||||
*/
|
||||
if (!script->hasAnalysis() || !script->analysis()->ranInference()) {
|
||||
okay = false;
|
||||
break;
|
||||
}
|
||||
|
||||
/*
|
||||
* The outer and inner scripts must have the same scope. This only
|
||||
* allows us to inline calls between non-inner functions. Also
|
||||
|
|
Загрузка…
Ссылка в новой задаче