зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1344721 - Eliminate unnecessary null check from Ion post barriers when we know the object is non-null. r=jonco
This commit is contained in:
Родитель
2733271b7f
Коммит
a7b166f847
|
@ -3750,8 +3750,11 @@ CodeGenerator::visitPostWriteBarrierCommonO(LPostBarrierType* lir, OutOfLineCode
|
|||
maybeEmitGlobalBarrierCheck(lir->object(), ool);
|
||||
|
||||
Register valueObj = ToRegister(lir->value());
|
||||
masm.branchTestPtr(Assembler::Zero, valueObj, valueObj, ool->rejoin());
|
||||
masm.branchPtrInNurseryChunk(Assembler::Equal, ToRegister(lir->value()), temp, ool->entry());
|
||||
if (lir->mir()->value()->type() == MIRType::ObjectOrNull)
|
||||
masm.branchTestPtr(Assembler::Zero, valueObj, valueObj, ool->rejoin());
|
||||
else
|
||||
MOZ_ASSERT(lir->mir()->value()->type() == MIRType::Object);
|
||||
masm.branchPtrInNurseryChunk(Assembler::Equal, valueObj, temp, ool->entry());
|
||||
|
||||
masm.bind(ool->rejoin());
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче