| Index: src/isolate.cc
|
| diff --git a/src/isolate.cc b/src/isolate.cc
|
| index 82ea67a0a91e2cbac551d0dd6e5c33fe8e600d33..a824771a3235d7f0c0727c982099d8445a474c12 100644
|
| --- a/src/isolate.cc
|
| +++ b/src/isolate.cc
|
| @@ -50,6 +50,7 @@
|
| #include "src/tracing/tracing-category-observer.h"
|
| #include "src/v8.h"
|
| #include "src/version.h"
|
| +#include "src/visitors.h"
|
| #include "src/vm-state-inl.h"
|
| #include "src/wasm/wasm-module.h"
|
| #include "src/wasm/wasm-objects.h"
|
| @@ -200,8 +201,7 @@ Address Isolate::get_address_from_id(Isolate::AddressId id) {
|
| return isolate_addresses_[id];
|
| }
|
|
|
| -
|
| -char* Isolate::Iterate(ObjectVisitor* v, char* thread_storage) {
|
| +char* Isolate::Iterate(RootVisitor* v, char* thread_storage) {
|
| ThreadLocalTop* thread = reinterpret_cast<ThreadLocalTop*>(thread_storage);
|
| Iterate(v, thread);
|
| return thread_storage + sizeof(ThreadLocalTop);
|
| @@ -213,19 +213,18 @@ void Isolate::IterateThread(ThreadVisitor* v, char* t) {
|
| v->VisitThread(this, thread);
|
| }
|
|
|
| -
|
| -void Isolate::Iterate(ObjectVisitor* v, ThreadLocalTop* thread) {
|
| +void Isolate::Iterate(RootVisitor* v, ThreadLocalTop* thread) {
|
| // Visit the roots from the top for a given thread.
|
| - v->VisitPointer(&thread->pending_exception_);
|
| - v->VisitPointer(&(thread->pending_message_obj_));
|
| - v->VisitPointer(bit_cast<Object**>(&(thread->context_)));
|
| - v->VisitPointer(&thread->scheduled_exception_);
|
| + v->VisitRootPointer(Root::kTop, &thread->pending_exception_);
|
| + v->VisitRootPointer(Root::kTop, &thread->pending_message_obj_);
|
| + v->VisitRootPointer(Root::kTop, bit_cast<Object**>(&(thread->context_)));
|
| + v->VisitRootPointer(Root::kTop, &thread->scheduled_exception_);
|
|
|
| for (v8::TryCatch* block = thread->try_catch_handler();
|
| block != NULL;
|
| block = block->next_) {
|
| - v->VisitPointer(bit_cast<Object**>(&(block->exception_)));
|
| - v->VisitPointer(bit_cast<Object**>(&(block->message_obj_)));
|
| + v->VisitRootPointer(Root::kTop, bit_cast<Object**>(&(block->exception_)));
|
| + v->VisitRootPointer(Root::kTop, bit_cast<Object**>(&(block->message_obj_)));
|
| }
|
|
|
| // Iterate over pointers on native execution stack.
|
| @@ -234,14 +233,12 @@ void Isolate::Iterate(ObjectVisitor* v, ThreadLocalTop* thread) {
|
| }
|
| }
|
|
|
| -
|
| -void Isolate::Iterate(ObjectVisitor* v) {
|
| +void Isolate::Iterate(RootVisitor* v) {
|
| ThreadLocalTop* current_t = thread_local_top();
|
| Iterate(v, current_t);
|
| }
|
|
|
| -
|
| -void Isolate::IterateDeferredHandles(ObjectVisitor* visitor) {
|
| +void Isolate::IterateDeferredHandles(RootVisitor* visitor) {
|
| for (DeferredHandles* deferred = deferred_handles_head_;
|
| deferred != NULL;
|
| deferred = deferred->next_) {
|
|
|