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

Side by Side Diff: src/api.cc

Issue 16578008: Improved function entry hook coverage (Closed) Base URL: https://chromium.googlesource.com/external/v8.git@post_fix
Patch Set: WIP: Fix X64 implementation. Created 7 years, 6 months 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 | « no previous file | src/bootstrapper.cc » ('j') | src/frames.cc » ('J')
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 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 5129 matching lines...) Expand 10 before | Expand all | Expand 10 after
5140 i::V8::SetEntropySource(source); 5140 i::V8::SetEntropySource(source);
5141 } 5141 }
5142 5142
5143 5143
5144 void v8::V8::SetReturnAddressLocationResolver( 5144 void v8::V8::SetReturnAddressLocationResolver(
5145 ReturnAddressLocationResolver return_address_resolver) { 5145 ReturnAddressLocationResolver return_address_resolver) {
5146 i::V8::SetReturnAddressLocationResolver(return_address_resolver); 5146 i::V8::SetReturnAddressLocationResolver(return_address_resolver);
5147 } 5147 }
5148 5148
5149 5149
5150 bool v8::V8::SetFunctionEntryHook(FunctionEntryHook entry_hook) { 5150 bool v8::V8::SetFunctionEntryHook(FunctionEntryHook entry_hook) {
danno 2013/06/13 15:33:44 API calls should take an Isolate parameter if you
Sigurður Ásgeirsson 2013/06/19 20:51:51 Done.
5151 return i::ProfileEntryHookStub::SetFunctionEntryHook(entry_hook); 5151 i::Isolate* isolate = i::Isolate::Current();
5152
5153 // We don't allow switching from one hook to another, as hooks don't stack.
5154 // This way a second user can at least detect that there's a problem.
5155 if (entry_hook != NULL && isolate->HasFunctionEntryHook())
danno 2013/06/13 15:33:44 Seems like this should be a ASSERT(entry_hook != N
Sigurður Ásgeirsson 2013/06/19 20:51:51 Done.
5156 return false;
5157
5158 isolate->SetFunctionEntryHook(entry_hook);
danno 2013/06/13 15:33:44 It would be great to introduce some checks to make
Sigurður Ásgeirsson 2013/06/19 20:51:51 Done.
5159 return true;
5152 } 5160 }
5153 5161
5154 5162
5155 void v8::V8::SetJitCodeEventHandler( 5163 void v8::V8::SetJitCodeEventHandler(
5156 JitCodeEventOptions options, JitCodeEventHandler event_handler) { 5164 JitCodeEventOptions options, JitCodeEventHandler event_handler) {
5157 i::Isolate* isolate = i::Isolate::Current(); 5165 i::Isolate* isolate = i::Isolate::Current();
5158 // Ensure that logging is initialized for our isolate. 5166 // Ensure that logging is initialized for our isolate.
5159 isolate->InitializeLoggingAndCounters(); 5167 isolate->InitializeLoggingAndCounters();
5160 isolate->logger()->SetCodeEventHandler(options, event_handler); 5168 isolate->logger()->SetCodeEventHandler(options, event_handler);
5161 } 5169 }
(...skipping 2834 matching lines...) Expand 10 before | Expand all | Expand 10 after
7996 8004
7997 v->VisitPointers(blocks_.first(), first_block_limit_); 8005 v->VisitPointers(blocks_.first(), first_block_limit_);
7998 8006
7999 for (int i = 1; i < blocks_.length(); i++) { 8007 for (int i = 1; i < blocks_.length(); i++) {
8000 v->VisitPointers(blocks_[i], &blocks_[i][kHandleBlockSize]); 8008 v->VisitPointers(blocks_[i], &blocks_[i][kHandleBlockSize]);
8001 } 8009 }
8002 } 8010 }
8003 8011
8004 8012
8005 } } // namespace v8::internal 8013 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | src/bootstrapper.cc » ('j') | src/frames.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698