Index: runtime/vm/isolate.cc |
diff --git a/runtime/vm/isolate.cc b/runtime/vm/isolate.cc |
index 14c2392cdaf4aa5329d4d8a20a14170a9ab50367..9e6189fd2109022defdde90301b10ecd2549b900 100644 |
--- a/runtime/vm/isolate.cc |
+++ b/runtime/vm/isolate.cc |
@@ -26,6 +26,7 @@ |
#include "vm/thread.h" |
#include "vm/timer.h" |
#include "vm/visitor.h" |
+#include "vm/object_id_ring.h" |
namespace dart { |
@@ -415,6 +416,7 @@ Isolate::Isolate() |
stacktrace_(NULL), |
stack_frame_index_(-1), |
object_histogram_(NULL), |
+ object_id_ring_(NULL), |
REUSABLE_HANDLE_LIST(REUSABLE_HANDLE_INITIALIZERS) |
reusable_handles_() { |
if (FLAG_print_object_histogram && (Dart::vm_isolate() != NULL)) { |
@@ -1068,6 +1070,17 @@ char* Isolate::GetStatus(const char* request) { |
} |
+void Isolate::set_object_id_ring(ObjectIdRing* ring) { |
+ ASSERT(heap_ != NULL); |
+ object_id_ring_ = ring; |
+ if (ring == NULL) { |
+ heap_->set_object_id_ring_table(NULL, 0); |
+ } else { |
+ heap_->set_object_id_ring_table(ring->table_, ring->capacity_); |
+ } |
+} |
+ |
+ |
template<class T> |
T* Isolate::AllocateReusableHandle() { |
T* handle = reinterpret_cast<T*>(reusable_handles_.AllocateScopedHandle()); |