Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(489)

Side by Side Diff: src/api.cc

Issue 2474163002: [api] Remove EmbedderReachableReferenceReporter (Closed)
Patch Set: Remove old api Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « include/v8-util.h ('k') | src/heap/heap.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/api.h" 5 #include "src/api.h"
6 6
7 #include <string.h> // For memcpy, strlen. 7 #include <string.h> // For memcpy, strlen.
8 #ifdef V8_USE_ADDRESS_SANITIZER 8 #ifdef V8_USE_ADDRESS_SANITIZER
9 #include <sanitizer/asan_interface.h> 9 #include <sanitizer/asan_interface.h>
10 #endif // V8_USE_ADDRESS_SANITIZER 10 #endif // V8_USE_ADDRESS_SANITIZER
(...skipping 794 matching lines...) Expand 10 before | Expand all | Expand 10 after
805 i::Object** V8::CopyPersistent(i::Object** obj) { 805 i::Object** V8::CopyPersistent(i::Object** obj) {
806 i::Handle<i::Object> result = i::GlobalHandles::CopyGlobal(obj); 806 i::Handle<i::Object> result = i::GlobalHandles::CopyGlobal(obj);
807 #ifdef VERIFY_HEAP 807 #ifdef VERIFY_HEAP
808 if (i::FLAG_verify_heap) { 808 if (i::FLAG_verify_heap) {
809 (*obj)->ObjectVerify(); 809 (*obj)->ObjectVerify();
810 } 810 }
811 #endif // VERIFY_HEAP 811 #endif // VERIFY_HEAP
812 return result.location(); 812 return result.location();
813 } 813 }
814 814
815 void V8::RegisterExternallyReferencedObject(i::Object** object,
816 i::Isolate* isolate) {
817 isolate->heap()->RegisterExternallyReferencedObject(object);
818 }
819
815 void V8::MakeWeak(i::Object** location, void* parameter, 820 void V8::MakeWeak(i::Object** location, void* parameter,
816 int internal_field_index1, int internal_field_index2, 821 int internal_field_index1, int internal_field_index2,
817 WeakCallbackInfo<void>::Callback weak_callback) { 822 WeakCallbackInfo<void>::Callback weak_callback) {
818 WeakCallbackType type = WeakCallbackType::kParameter; 823 WeakCallbackType type = WeakCallbackType::kParameter;
819 if (internal_field_index1 == 0) { 824 if (internal_field_index1 == 0) {
820 if (internal_field_index2 == 1) { 825 if (internal_field_index2 == 1) {
821 type = WeakCallbackType::kInternalFields; 826 type = WeakCallbackType::kInternalFields;
822 } else { 827 } else {
823 DCHECK_EQ(internal_field_index2, -1); 828 DCHECK_EQ(internal_field_index2, -1);
824 type = WeakCallbackType::kInternalFields; 829 type = WeakCallbackType::kInternalFields;
(...skipping 8815 matching lines...) Expand 10 before | Expand all | Expand 10 after
9640 Address callback_address = 9645 Address callback_address =
9641 reinterpret_cast<Address>(reinterpret_cast<intptr_t>(callback)); 9646 reinterpret_cast<Address>(reinterpret_cast<intptr_t>(callback));
9642 VMState<EXTERNAL> state(isolate); 9647 VMState<EXTERNAL> state(isolate);
9643 ExternalCallbackScope call_scope(isolate, callback_address); 9648 ExternalCallbackScope call_scope(isolate, callback_address);
9644 callback(info); 9649 callback(info);
9645 } 9650 }
9646 9651
9647 9652
9648 } // namespace internal 9653 } // namespace internal
9649 } // namespace v8 9654 } // namespace v8
OLDNEW
« no previous file with comments | « include/v8-util.h ('k') | src/heap/heap.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698