Bug 577764 - TM: avoid a dead guard at the end of loop fragments. r=dvander.

This commit is contained in:
Nicholas Nethercote 2010-07-12 11:01:58 +10:00
Родитель f61d3ab570
Коммит 3573f019bc
1 изменённых файлов: 4 добавлений и 4 удалений

Просмотреть файл

@ -4717,17 +4717,17 @@ TraceRecorder::closeLoop(SlotMap& slotMap, VMSideExit* exit)
}
} else {
exit->exitType = LOOP_EXIT;
exit->target = tree;
debug_only_printf(LC_TMTreeVis, "TREEVIS CHANGEEXIT EXIT=%p TYPE=%s\n", (void*)exit,
getExitName(LOOP_EXIT));
JS_ASSERT((fragment == fragment->root) == !!loopLabel);
if (loopLabel) {
lir->insBranch(LIR_j, NULL, loopLabel);
lir->ins1(LIR_livep, lirbuf->state);
fragment->lastIns = lir->ins1(LIR_livep, lirbuf->state);
} else {
fragment->lastIns = lir->insGuard(LIR_x, NULL, createGuardRecord(exit));
}
exit->target = tree;
fragment->lastIns = lir->insGuard(LIR_x, NULL, createGuardRecord(exit));
}
CHECK_STATUS_A(compile());