зеркало из https://github.com/mozilla/gecko-dev.git
Bug 977674: IonMonkey - Only clear recompiling flag if sequentially compiling, r=jandem
This commit is contained in:
Родитель
6d51c5621f
Коммит
3e6918c03f
|
@ -0,0 +1,39 @@
|
|||
|
||||
function testReduce() {
|
||||
function sum(a, b) {
|
||||
var r = a + b;
|
||||
}
|
||||
var array = build(8 * 0X0aaec , function() { return 1; });
|
||||
var parResult = array.reducePar(sum);
|
||||
}
|
||||
for (var ix = 0; ix < 3; ++ix) {
|
||||
testReduce();
|
||||
}
|
||||
function build(n, f) {
|
||||
var result = [];
|
||||
for (var i = 0; i < n; i++)
|
||||
result.push(f(i));
|
||||
return result;
|
||||
}
|
||||
function seq_scan(array, f) {
|
||||
for (var i = 1; i < array.length; i++) {
|
||||
}
|
||||
}
|
||||
function assertAlmostEq(v1, v2) {
|
||||
if (e1 instanceof Array && e2 instanceof Array) {
|
||||
for (prop in e1) {
|
||||
if (e1.hasOwnProperty(prop)) { }
|
||||
}
|
||||
}
|
||||
}
|
||||
function assertEqArray(a, b) {
|
||||
for (var i = 0, l = a.length; i < l; i++) {
|
||||
try { } catch (e) { }
|
||||
}
|
||||
}
|
||||
function assertParallelExecWillRecover(opFunction) {
|
||||
assertParallelExecSucceeds(
|
||||
function(m) {},
|
||||
function(r) {}
|
||||
);
|
||||
}
|
|
@ -506,8 +506,9 @@ jit::FinishOffThreadBuilder(IonBuilder *builder)
|
|||
{
|
||||
ExecutionMode executionMode = builder->info().executionMode();
|
||||
|
||||
// Clear the recompiling flag if it would have failed.
|
||||
if (builder->script()->hasIonScript())
|
||||
// Clear the recompiling flag of the old ionScript, since we continue to
|
||||
// use the old ionScript if recompiling fails.
|
||||
if (executionMode == SequentialExecution && builder->script()->hasIonScript())
|
||||
builder->script()->ionScript()->clearRecompiling();
|
||||
|
||||
// Clean up if compilation did not succeed.
|
||||
|
|
Загрузка…
Ссылка в новой задаче