Revision: 23400
Author:   [email protected]
Date:     Tue Aug 26 13:05:54 2014 UTC
Log:      HeapProfiler: remove obsolete AddImplicitReferences

it hasn't been used since r149579. More than one year ago.

BUG=
[email protected], [email protected]

Review URL: https://codereview.chromium.org/505983002
https://code.google.com/p/v8/source/detail?r=23400

Modified:
 /branches/bleeding_edge/src/global-handles.cc
 /branches/bleeding_edge/src/global-handles.h
 /branches/bleeding_edge/test/cctest/test-mark-compact.cc

=======================================
--- /branches/bleeding_edge/src/global-handles.cc Tue Aug 26 09:19:24 2014 UTC +++ /branches/bleeding_edge/src/global-handles.cc Tue Aug 26 13:05:54 2014 UTC
@@ -843,23 +843,6 @@
                                           RetainedObjectInfo* info) {
   retainer_infos_.Add(ObjectGroupRetainerInfo(id, info));
 }
-
-
-void GlobalHandles::AddImplicitReferences(HeapObject** parent,
-                                          Object*** children,
-                                          size_t length) {
-#ifdef DEBUG
-  DCHECK(!Node::FromLocation(BitCast<Object**>(parent))->is_independent());
-  for (size_t i = 0; i < length; ++i) {
-    DCHECK(!Node::FromLocation(children[i])->is_independent());
-  }
-#endif
-  if (length == 0) return;
-  ImplicitRefGroup* group = new ImplicitRefGroup(parent, length);
-  for (size_t i = 0; i < length; ++i)
-    group->children[i] = children[i];
-  implicit_ref_groups_.Add(group);
-}


 void GlobalHandles::SetReferenceFromGroup(UniqueId id, Object** child) {
=======================================
--- /branches/bleeding_edge/src/global-handles.h Mon Aug 4 11:34:54 2014 UTC +++ /branches/bleeding_edge/src/global-handles.h Tue Aug 26 13:05:54 2014 UTC
@@ -215,13 +215,6 @@
   // handles.
   void SetRetainedObjectInfo(UniqueId id, RetainedObjectInfo* info);

-  // Add an implicit references' group.
-  // Should be only used in GC callback function before a collection.
-  // All groups are destroyed after a mark-compact collection.
-  void AddImplicitReferences(HeapObject** parent,
-                             Object*** children,
-                             size_t length);
-
// Adds an implicit reference from a group to an object. Should be only used // in GC callback function before a collection. All implicit references are
   // destroyed after a mark-compact collection.
=======================================
--- /branches/bleeding_edge/test/cctest/test-mark-compact.cc Tue Aug 26 09:19:24 2014 UTC +++ /branches/bleeding_edge/test/cctest/test-mark-compact.cc Tue Aug 26 13:05:54 2014 UTC
@@ -301,15 +301,13 @@

   {
     Object** g1_objects[] = { g1s1.location(), g1s2.location() };
-    Object** g1_children[] = { g1c1.location() };
     Object** g2_objects[] = { g2s1.location(), g2s2.location() };
-    Object** g2_children[] = { g2c1.location() };
     global_handles->AddObjectGroup(g1_objects, 2, NULL);
-    global_handles->AddImplicitReferences(
-        Handle<HeapObject>::cast(g1s1).location(), g1_children, 1);
+    global_handles->SetReference(Handle<HeapObject>::cast(g1s1).location(),
+                                 g1c1.location());
     global_handles->AddObjectGroup(g2_objects, 2, NULL);
-    global_handles->AddImplicitReferences(
-        Handle<HeapObject>::cast(g2s1).location(), g2_children, 1);
+    global_handles->SetReference(Handle<HeapObject>::cast(g2s1).location(),
+                                 g2c1.location());
   }
   // Do a full GC
   heap->CollectGarbage(OLD_POINTER_SPACE);
@@ -330,15 +328,13 @@
   // Groups are deleted, rebuild groups.
   {
     Object** g1_objects[] = { g1s1.location(), g1s2.location() };
-    Object** g1_children[] = { g1c1.location() };
     Object** g2_objects[] = { g2s1.location(), g2s2.location() };
-    Object** g2_children[] = { g2c1.location() };
     global_handles->AddObjectGroup(g1_objects, 2, NULL);
-    global_handles->AddImplicitReferences(
-        Handle<HeapObject>::cast(g1s1).location(), g1_children, 1);
+    global_handles->SetReference(Handle<HeapObject>::cast(g1s1).location(),
+                                 g1c1.location());
     global_handles->AddObjectGroup(g2_objects, 2, NULL);
-    global_handles->AddImplicitReferences(
-        Handle<HeapObject>::cast(g2s1).location(), g2_children, 1);
+    global_handles->SetReference(Handle<HeapObject>::cast(g2s1).location(),
+                                 g2c1.location());
   }

   heap->CollectGarbage(OLD_POINTER_SPACE);
@@ -389,15 +385,9 @@

   v8::HandleScope handle_scope(CcTest::isolate());

-  Handle<Object> object = global_handles->Create(
-      CcTest::test_heap()->AllocateFixedArray(1).ToObjectChecked());
-
   TestRetainedObjectInfo info;
   global_handles->AddObjectGroup(NULL, 0, &info);
   DCHECK(info.has_been_disposed());
-
-  global_handles->AddImplicitReferences(
-        Handle<HeapObject>::cast(object).location(), NULL, 0);
 }


--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to