mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 22:01:30 +00:00
Bug 1199143 - Inline heavyweight functions. r=shu
This commit is contained in:
parent
3324bb898f
commit
3ef7347013
@ -150,7 +150,6 @@ namespace JS {
|
||||
_(CantInlineClassConstructor) \
|
||||
_(CantInlineDisabledIon) \
|
||||
_(CantInlineTooManyArgs) \
|
||||
_(CantInlineHeavyweight) \
|
||||
_(CantInlineNeedsArgsObj) \
|
||||
_(CantInlineDebuggee) \
|
||||
_(CantInlineUnknownProps) \
|
||||
|
@ -25,13 +25,14 @@ withJitOptions(Opts_Ion2NoOffthreadCompilation, function () {
|
||||
}
|
||||
};
|
||||
|
||||
g.eval("" + function f(d, x) { "use strict"; g(d, x); });
|
||||
g.eval("" + function f(d, x) {
|
||||
"use strict";
|
||||
eval("g(d, x)"); // `eval` to avoid inlining g.
|
||||
});
|
||||
|
||||
g.eval("" + function g(d, x) {
|
||||
"use strict";
|
||||
for (var i = 0; i < 200; i++);
|
||||
// Hack to prevent inlining.
|
||||
function inner() { i = 42; };
|
||||
toggle(d);
|
||||
});
|
||||
|
||||
|
@ -524,11 +524,6 @@ IonBuilder::canInlineTarget(JSFunction* target, CallInfo& callInfo)
|
||||
return DontInline(inlineScript, "Common inlining path");
|
||||
}
|
||||
|
||||
if (target->isHeavyweight()) {
|
||||
trackOptimizationOutcome(TrackedOutcome::CantInlineHeavyweight);
|
||||
return DontInline(inlineScript, "Heavyweight function");
|
||||
}
|
||||
|
||||
if (inlineScript->uninlineable()) {
|
||||
trackOptimizationOutcome(TrackedOutcome::CantInlineGeneric);
|
||||
return DontInline(inlineScript, "Uninlineable script");
|
||||
|
Loading…
Reference in New Issue
Block a user