зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1388110 - Fix slot access intrinsics for objects with > 16 reserved slots r=nbp
This commit is contained in:
Родитель
f07a275693
Коммит
a36e3e0610
|
@ -2890,6 +2890,10 @@ IonBuilder::inlineUnsafeSetReservedSlot(CallInfo& callInfo)
|
|||
return InliningStatus_NotInlined;
|
||||
uint32_t slot = uint32_t(arg->toConstant()->toInt32());
|
||||
|
||||
// Don't inline if it's not a fixed slot.
|
||||
if (slot >= NativeObject::MAX_FIXED_SLOTS)
|
||||
return InliningStatus_NotInlined;
|
||||
|
||||
callInfo.setImplicitlyUsedUnchecked();
|
||||
|
||||
MStoreFixedSlot* store =
|
||||
|
@ -2924,6 +2928,10 @@ IonBuilder::inlineUnsafeGetReservedSlot(CallInfo& callInfo, MIRType knownValueTy
|
|||
return InliningStatus_NotInlined;
|
||||
uint32_t slot = uint32_t(arg->toConstant()->toInt32());
|
||||
|
||||
// Don't inline if it's not a fixed slot.
|
||||
if (slot >= NativeObject::MAX_FIXED_SLOTS)
|
||||
return InliningStatus_NotInlined;
|
||||
|
||||
callInfo.setImplicitlyUsedUnchecked();
|
||||
|
||||
MLoadFixedSlot* load = MLoadFixedSlot::New(alloc(), obj, slot);
|
||||
|
|
Загрузка…
Ссылка в новой задаче