diff --git a/js/src/jit/MIR.cpp b/js/src/jit/MIR.cpp index e757498c6..f15de7870 100644 --- a/js/src/jit/MIR.cpp +++ b/js/src/jit/MIR.cpp @@ -5554,8 +5554,10 @@ jit::PropertyWriteNeedsTypeBarrier(TempAllocator& alloc, CompilerConstraintList* bool success = true; for (size_t i = 0; i < types->getObjectCount(); i++) { TypeSet::ObjectKey* key = types->getObject(i); - if (!key || key->unknownProperties()) + if (!key) continue; + if (!key->hasStableClassAndProto(constraints)) + return true; // TI doesn't track TypedArray indexes and should never insert a type // barrier for them. @@ -5607,8 +5609,11 @@ jit::PropertyWriteNeedsTypeBarrier(TempAllocator& alloc, CompilerConstraintList* TypeSet::ObjectKey* excluded = nullptr; for (size_t i = 0; i < types->getObjectCount(); i++) { TypeSet::ObjectKey* key = types->getObject(i); - if (!key || key->unknownProperties()) + if (!key) continue; + if (!key->hasStableClassAndProto(constraints)) + return true; + if (!name && IsAnyTypedArrayClass(key->clasp())) continue; diff --git a/js/src/jit/MIR.h b/js/src/jit/MIR.h index d94ec4c9d..d1d068acc 100644 --- a/js/src/jit/MIR.h +++ b/js/src/jit/MIR.h @@ -9503,10 +9503,6 @@ class MArraySlice return unboxedType_; } - AliasSet getAliasSet() const override { - return AliasSet::Store(AliasSet::BoxedOrUnboxedElements(unboxedType()) | - AliasSet::ObjectFields); - } bool possiblyCalls() const override { return true; }