Index: src/objects-debug.cc |
diff --git a/src/objects-debug.cc b/src/objects-debug.cc |
index e6c231ecc64094ebed85666b5a301fa75f6d4573..a532d5f9336dcd6efef696f796f313d3c1504f42 100644 |
--- a/src/objects-debug.cc |
+++ b/src/objects-debug.cc |
@@ -673,6 +673,7 @@ void Code::CodeVerify() { |
void Code::VerifyEmbeddedObjectsDependency() { |
if (!CanContainWeakObjects()) return; |
+ WeakCell* cell = CachedWeakCell(); |
DisallowHeapAllocation no_gc; |
Isolate* isolate = GetIsolate(); |
HandleScope scope(isolate); |
@@ -683,13 +684,13 @@ void Code::VerifyEmbeddedObjectsDependency() { |
if (obj->IsMap()) { |
Map* map = Map::cast(obj); |
CHECK(map->dependent_code()->Contains(DependentCode::kWeakCodeGroup, |
- this)); |
+ cell)); |
} else if (obj->IsJSObject()) { |
Object* raw_table = GetIsolate()->heap()->weak_object_to_code_table(); |
WeakHashTable* table = WeakHashTable::cast(raw_table); |
Handle<Object> key_obj(obj, isolate); |
- CHECK(DependentCode::cast(table->Lookup(key_obj))->Contains( |
- DependentCode::kWeakCodeGroup, this)); |
+ CHECK(DependentCode::cast(table->Lookup(key_obj)) |
+ ->Contains(DependentCode::kWeakCodeGroup, cell)); |
} |
} |
} |