| Index: runtime/vm/object.h
|
| diff --git a/runtime/vm/object.h b/runtime/vm/object.h
|
| index c5175145f9c47f76577c91c2ab47bd3b531459e4..0f6491243d6b2290c0fca9d0211b0b81cefddd0d 100644
|
| --- a/runtime/vm/object.h
|
| +++ b/runtime/vm/object.h
|
| @@ -3125,10 +3125,19 @@ class Field : public Object {
|
| // Return class id that any non-null value read from this field is guaranteed
|
| // to have or kDynamicCid if such class id is not known.
|
| // Stores to this field must update this information hence the name.
|
| - intptr_t guarded_cid() const { return raw_ptr()->guarded_cid_; }
|
| + intptr_t guarded_cid() const {
|
| +#if defined(DEGUG)
|
| + Thread* thread = Thread::Current();
|
| + ASSERT(!IsOriginal() || thread->IsMutator() || thread->IsAtSafepoint());
|
| +#endif
|
| + return raw_ptr()->guarded_cid_;
|
| + }
|
|
|
| void set_guarded_cid(intptr_t cid) const {
|
| - ASSERT(Thread::Current()->IsMutatorThread());
|
| +#if defined(DEGUG)
|
| + Thread* thread = Thread::Current();
|
| + ASSERT(!IsOriginal() || thread->IsMutator() || thread->IsAtSafepoint());
|
| +#endif
|
| StoreNonPointer(&raw_ptr()->guarded_cid_, cid);
|
| }
|
| static intptr_t guarded_cid_offset() {
|
| @@ -3213,6 +3222,10 @@ class Field : public Object {
|
| // Deoptimize all dependent code objects.
|
| void DeoptimizeDependentCode() const;
|
|
|
| + // Used by background compiler to check consistency of field copy with its
|
| + // original.
|
| + bool IsConsistentWith(const Field& field) const;
|
| +
|
| bool IsUninitialized() const;
|
|
|
| void EvaluateInitializer() const;
|
|
|