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

Side by Side Diff: src/log.h

Issue 2061623002: Introduce JIT code events dispatcher for the isolate. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: rebaseline Created 4 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 | « src/isolate.cc ('k') | src/log.cc » ('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 #ifndef V8_LOG_H_ 5 #ifndef V8_LOG_H_
6 #define V8_LOG_H_ 6 #define V8_LOG_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "src/allocation.h" 10 #include "src/allocation.h"
11 #include "src/base/compiler-specific.h" 11 #include "src/base/compiler-specific.h"
12 #include "src/base/platform/elapsed-timer.h" 12 #include "src/base/platform/elapsed-timer.h"
13 #include "src/base/platform/platform.h" 13 #include "src/base/platform/platform.h"
14 #include "src/code-events.h"
15 #include "src/isolate.h"
14 #include "src/objects.h" 16 #include "src/objects.h"
15 17
16 namespace v8 { 18 namespace v8 {
17 19
18 namespace base { 20 namespace base {
19 class Semaphore; 21 class Semaphore;
20 } 22 }
21 23
22 namespace sampler { 24 namespace sampler {
23 class Sampler; 25 class Sampler;
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 class CpuProfiler; 66 class CpuProfiler;
65 class Isolate; 67 class Isolate;
66 class Log; 68 class Log;
67 class PositionsRecorder; 69 class PositionsRecorder;
68 class Profiler; 70 class Profiler;
69 class Ticker; 71 class Ticker;
70 struct TickSample; 72 struct TickSample;
71 class RuntimeCallTimer; 73 class RuntimeCallTimer;
72 74
73 #undef LOG 75 #undef LOG
74 #define LOG(isolate, Call) \ 76 #define LOG(isolate, Call) \
75 do { \ 77 do { \
76 v8::internal::Logger* logger = \ 78 v8::internal::Logger* logger = (isolate)->logger(); \
77 (isolate)->logger(); \ 79 if (logger->is_logging()) logger->Call; \
78 if (logger->is_logging()) \
79 logger->Call; \
80 } while (false) 80 } while (false)
81 81
82 #define LOG_CODE_EVENT(isolate, Call) \ 82 #define LOG_CODE_EVENT(isolate, Call) \
83 do { \ 83 do { \
84 v8::internal::Logger* logger = \ 84 v8::internal::Logger* logger = (isolate)->logger(); \
85 (isolate)->logger(); \ 85 if (logger->is_logging_code_events()) logger->Call; \
86 if (logger->is_logging_code_events()) \
87 logger->Call; \
88 } while (false) 86 } while (false)
89 87
90 #define LOG_EVENTS_AND_TAGS_LIST(V) \
91 V(CODE_CREATION_EVENT, "code-creation") \
92 V(CODE_DISABLE_OPT_EVENT, "code-disable-optimization") \
93 V(CODE_MOVE_EVENT, "code-move") \
94 V(CODE_DELETE_EVENT, "code-delete") \
95 V(CODE_MOVING_GC, "code-moving-gc") \
96 V(SHARED_FUNC_MOVE_EVENT, "sfi-move") \
97 V(SNAPSHOT_CODE_NAME_EVENT, "snapshot-code-name") \
98 V(TICK_EVENT, "tick") \
99 V(REPEAT_META_EVENT, "repeat") \
100 V(BUILTIN_TAG, "Builtin") \
101 V(CALL_DEBUG_BREAK_TAG, "CallDebugBreak") \
102 V(CALL_DEBUG_PREPARE_STEP_IN_TAG, "CallDebugPrepareStepIn") \
103 V(CALL_INITIALIZE_TAG, "CallInitialize") \
104 V(CALL_MEGAMORPHIC_TAG, "CallMegamorphic") \
105 V(CALL_MISS_TAG, "CallMiss") \
106 V(CALL_NORMAL_TAG, "CallNormal") \
107 V(LOAD_INITIALIZE_TAG, "LoadInitialize") \
108 V(LOAD_MEGAMORPHIC_TAG, "LoadMegamorphic") \
109 V(STORE_INITIALIZE_TAG, "StoreInitialize") \
110 V(STORE_GENERIC_TAG, "StoreGeneric") \
111 V(STORE_MEGAMORPHIC_TAG, "StoreMegamorphic") \
112 V(KEYED_CALL_DEBUG_BREAK_TAG, "KeyedCallDebugBreak") \
113 V(KEYED_CALL_DEBUG_PREPARE_STEP_IN_TAG, "KeyedCallDebugPrepareStepIn") \
114 V(KEYED_CALL_INITIALIZE_TAG, "KeyedCallInitialize") \
115 V(KEYED_CALL_MEGAMORPHIC_TAG, "KeyedCallMegamorphic") \
116 V(KEYED_CALL_MISS_TAG, "KeyedCallMiss") \
117 V(KEYED_CALL_NORMAL_TAG, "KeyedCallNormal") \
118 V(CALLBACK_TAG, "Callback") \
119 V(EVAL_TAG, "Eval") \
120 V(FUNCTION_TAG, "Function") \
121 V(HANDLER_TAG, "Handler") \
122 V(BYTECODE_HANDLER_TAG, "BytecodeHandler") \
123 V(KEYED_LOAD_IC_TAG, "KeyedLoadIC") \
124 V(KEYED_LOAD_POLYMORPHIC_IC_TAG, "KeyedLoadPolymorphicIC") \
125 V(KEYED_EXTERNAL_ARRAY_LOAD_IC_TAG, "KeyedExternalArrayLoadIC") \
126 V(KEYED_STORE_IC_TAG, "KeyedStoreIC") \
127 V(KEYED_STORE_POLYMORPHIC_IC_TAG, "KeyedStorePolymorphicIC") \
128 V(KEYED_EXTERNAL_ARRAY_STORE_IC_TAG, "KeyedExternalArrayStoreIC") \
129 V(LAZY_COMPILE_TAG, "LazyCompile") \
130 V(CALL_IC_TAG, "CallIC") \
131 V(LOAD_IC_TAG, "LoadIC") \
132 V(LOAD_GLOBAL_IC_TAG, "LoadGlobalIC") \
133 V(LOAD_POLYMORPHIC_IC_TAG, "LoadPolymorphicIC") \
134 V(REG_EXP_TAG, "RegExp") \
135 V(SCRIPT_TAG, "Script") \
136 V(STORE_IC_TAG, "StoreIC") \
137 V(STORE_POLYMORPHIC_IC_TAG, "StorePolymorphicIC") \
138 V(STUB_TAG, "Stub") \
139 V(NATIVE_FUNCTION_TAG, "Function") \
140 V(NATIVE_LAZY_COMPILE_TAG, "LazyCompile") \
141 V(NATIVE_SCRIPT_TAG, "Script")
142 // Note that 'NATIVE_' cases for functions and scripts are mapped onto
143 // original tags when writing to the log.
144
145
146 class JitLogger; 88 class JitLogger;
147 class PerfBasicLogger; 89 class PerfBasicLogger;
148 class LowLevelLogger; 90 class LowLevelLogger;
149 class PerfJitLogger; 91 class PerfJitLogger;
150 92
151 class Logger { 93 class Logger : public CodeEventListener {
152 public: 94 public:
153 enum StartEnd { START = 0, END = 1 }; 95 enum StartEnd { START = 0, END = 1 };
154 96
155 #define DECLARE_ENUM(enum_item, ignore) enum_item,
156 enum LogEventsAndTags {
157 LOG_EVENTS_AND_TAGS_LIST(DECLARE_ENUM)
158 NUMBER_OF_LOG_EVENTS
159 };
160 #undef DECLARE_ENUM
161
162 // Acquires resources for logging if the right flags are set. 97 // Acquires resources for logging if the right flags are set.
163 bool SetUp(Isolate* isolate); 98 bool SetUp(Isolate* isolate);
164 99
165 // Sets the current code event handler. 100 // Sets the current code event handler.
166 void SetCodeEventHandler(uint32_t options, 101 void SetCodeEventHandler(uint32_t options,
167 JitCodeEventHandler event_handler); 102 JitCodeEventHandler event_handler);
168 103
169 sampler::Sampler* sampler(); 104 sampler::Sampler* sampler();
170 105
171 // Frees resources acquired in SetUp. 106 // Frees resources acquired in SetUp.
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
205 140
206 // ==== Events logged by --log-api. ==== 141 // ==== Events logged by --log-api. ====
207 void ApiSecurityCheck(); 142 void ApiSecurityCheck();
208 void ApiNamedPropertyAccess(const char* tag, JSObject* holder, Object* name); 143 void ApiNamedPropertyAccess(const char* tag, JSObject* holder, Object* name);
209 void ApiIndexedPropertyAccess(const char* tag, 144 void ApiIndexedPropertyAccess(const char* tag,
210 JSObject* holder, 145 JSObject* holder,
211 uint32_t index); 146 uint32_t index);
212 void ApiObjectAccess(const char* tag, JSObject* obj); 147 void ApiObjectAccess(const char* tag, JSObject* obj);
213 void ApiEntryCall(const char* name); 148 void ApiEntryCall(const char* name);
214 149
215
216 // ==== Events logged by --log-code. ==== 150 // ==== Events logged by --log-code. ====
217 void addCodeEventListener(CodeEventListener* listener); 151 void addCodeEventListener(CodeEventListener* listener);
218 void removeCodeEventListener(CodeEventListener* listener); 152 void removeCodeEventListener(CodeEventListener* listener);
219 bool hasCodeEventListener(CodeEventListener* listener);
220
221 153
222 // Emits a code event for a callback function. 154 // Emits a code event for a callback function.
223 void CallbackEvent(Name* name, Address entry_point); 155 void CallbackEvent(Name* name, Address entry_point);
224 void GetterCallbackEvent(Name* name, Address entry_point); 156 void GetterCallbackEvent(Name* name, Address entry_point);
225 void SetterCallbackEvent(Name* name, Address entry_point); 157 void SetterCallbackEvent(Name* name, Address entry_point);
226 // Emits a code create event. 158 // Emits a code create event.
227 void CodeCreateEvent(LogEventsAndTags tag, AbstractCode* code, 159 void CodeCreateEvent(CodeEventListener::LogEventsAndTags tag,
228 const char* source); 160 AbstractCode* code, const char* source);
229 void CodeCreateEvent(LogEventsAndTags tag, AbstractCode* code, Name* name); 161 void CodeCreateEvent(CodeEventListener::LogEventsAndTags tag,
230 void CodeCreateEvent(LogEventsAndTags tag, AbstractCode* code, 162 AbstractCode* code, Name* name);
231 SharedFunctionInfo* shared, Name* name); 163 void CodeCreateEvent(CodeEventListener::LogEventsAndTags tag,
232 void CodeCreateEvent(LogEventsAndTags tag, AbstractCode* code, 164 AbstractCode* code, SharedFunctionInfo* shared,
233 SharedFunctionInfo* shared, Name* source, int line, 165 Name* name);
234 int column); 166 void CodeCreateEvent(CodeEventListener::LogEventsAndTags tag,
235 void CodeCreateEvent(LogEventsAndTags tag, AbstractCode* code, 167 AbstractCode* code, SharedFunctionInfo* shared,
236 int args_count); 168 Name* source, int line, int column);
169 void CodeCreateEvent(CodeEventListener::LogEventsAndTags tag,
170 AbstractCode* code, int args_count);
237 // Emits a code deoptimization event. 171 // Emits a code deoptimization event.
238 void CodeDisableOptEvent(AbstractCode* code, SharedFunctionInfo* shared); 172 void CodeDisableOptEvent(AbstractCode* code, SharedFunctionInfo* shared);
239 void CodeMovingGCEvent(); 173 void CodeMovingGCEvent();
240 // Emits a code create event for a RegExp. 174 // Emits a code create event for a RegExp.
241 void RegExpCodeCreateEvent(AbstractCode* code, String* source); 175 void RegExpCodeCreateEvent(AbstractCode* code, String* source);
242 // Emits a code move event. 176 // Emits a code move event.
243 void CodeMoveEvent(AbstractCode* from, Address to); 177 void CodeMoveEvent(AbstractCode* from, Address to);
244 // Emits a code line info add event with Postion type. 178 // Emits a code line info add event with Postion type.
245 void CodeLinePosInfoAddPositionEvent(void* jit_handler_data, 179 void CodeLinePosInfoAddPositionEvent(void* jit_handler_data,
246 int pc_offset, 180 int pc_offset,
247 int position); 181 int position);
248 // Emits a code line info add event with StatementPostion type. 182 // Emits a code line info add event with StatementPostion type.
249 void CodeLinePosInfoAddStatementPositionEvent(void* jit_handler_data, 183 void CodeLinePosInfoAddStatementPositionEvent(void* jit_handler_data,
250 int pc_offset, 184 int pc_offset,
251 int position); 185 int position);
252 // Emits a code line info start to record event 186 // Emits a code line info start to record event
253 void CodeStartLinePosInfoRecordEvent(PositionsRecorder* pos_recorder); 187 void CodeStartLinePosInfoRecordEvent(PositionsRecorder* pos_recorder);
254 // Emits a code line info finish record event. 188 // Emits a code line info finish record event.
255 // It's the callee's responsibility to dispose the parameter jit_handler_data. 189 // It's the callee's responsibility to dispose the parameter jit_handler_data.
256 void CodeEndLinePosInfoRecordEvent(AbstractCode* code, 190 void CodeEndLinePosInfoRecordEvent(AbstractCode* code,
257 void* jit_handler_data); 191 void* jit_handler_data);
258 192
259 void SharedFunctionInfoMoveEvent(Address from, Address to); 193 void SharedFunctionInfoMoveEvent(Address from, Address to);
260 194
261 void CodeNameEvent(Address addr, int pos, const char* code_name); 195 void CodeNameEvent(Address addr, int pos, const char* code_name);
262 196
197 void CodeDeoptEvent(Code* code, Address pc, int fp_to_sp_delta);
198
263 // ==== Events logged by --log-gc. ==== 199 // ==== Events logged by --log-gc. ====
264 // Heap sampling events: start, end, and individual types. 200 // Heap sampling events: start, end, and individual types.
265 void HeapSampleBeginEvent(const char* space, const char* kind); 201 void HeapSampleBeginEvent(const char* space, const char* kind);
266 void HeapSampleEndEvent(const char* space, const char* kind); 202 void HeapSampleEndEvent(const char* space, const char* kind);
267 void HeapSampleItemEvent(const char* type, int number, int bytes); 203 void HeapSampleItemEvent(const char* type, int number, int bytes);
268 void HeapSampleJSConstructorEvent(const char* constructor, 204 void HeapSampleJSConstructorEvent(const char* constructor,
269 int number, int bytes); 205 int number, int bytes);
270 void HeapSampleJSRetainersEvent(const char* constructor, 206 void HeapSampleJSRetainersEvent(const char* constructor,
271 const char* event); 207 const char* event);
272 void HeapSampleJSProducerEvent(const char* constructor, 208 void HeapSampleJSProducerEvent(const char* constructor,
273 Address* stack); 209 Address* stack);
274 void HeapSampleStats(const char* space, const char* kind, 210 void HeapSampleStats(const char* space, const char* kind,
275 intptr_t capacity, intptr_t used); 211 intptr_t capacity, intptr_t used);
276 212
277 void SharedLibraryEvent(const std::string& library_path, uintptr_t start, 213 void SharedLibraryEvent(const std::string& library_path, uintptr_t start,
278 uintptr_t end, intptr_t aslr_slide); 214 uintptr_t end, intptr_t aslr_slide);
279 215
280 void CodeDeoptEvent(Code* code, Address pc, int fp_to_sp_delta);
281 void CurrentTimeEvent(); 216 void CurrentTimeEvent();
282 217
283 void TimerEvent(StartEnd se, const char* name); 218 void TimerEvent(StartEnd se, const char* name);
284 219
285 static void EnterExternal(Isolate* isolate); 220 static void EnterExternal(Isolate* isolate);
286 static void LeaveExternal(Isolate* isolate); 221 static void LeaveExternal(Isolate* isolate);
287 222
288 static void DefaultEventLoggerSentinel(const char* name, int event) {} 223 static void DefaultEventLoggerSentinel(const char* name, int event) {}
289 224
290 INLINE(static void CallEventLogger(Isolate* isolate, const char* name, 225 INLINE(static void CallEventLogger(Isolate* isolate, const char* name,
(...skipping 21 matching lines...) Expand all
312 // Logs all compiled functions found in the heap. 247 // Logs all compiled functions found in the heap.
313 void LogCompiledFunctions(); 248 void LogCompiledFunctions();
314 // Logs all accessor callbacks found in the heap. 249 // Logs all accessor callbacks found in the heap.
315 void LogAccessorCallbacks(); 250 void LogAccessorCallbacks();
316 // Used for logging stubs found in the snapshot. 251 // Used for logging stubs found in the snapshot.
317 void LogCodeObjects(); 252 void LogCodeObjects();
318 // Used for logging bytecode handlers found in the snapshot. 253 // Used for logging bytecode handlers found in the snapshot.
319 void LogBytecodeHandlers(); 254 void LogBytecodeHandlers();
320 255
321 // Converts tag to a corresponding NATIVE_... if the script is native. 256 // Converts tag to a corresponding NATIVE_... if the script is native.
322 INLINE(static LogEventsAndTags ToNativeByScript(LogEventsAndTags, Script*)); 257 INLINE(static CodeEventListener::LogEventsAndTags ToNativeByScript(
258 CodeEventListener::LogEventsAndTags, Script*));
323 259
324 // Profiler's sampling interval (in milliseconds). 260 // Profiler's sampling interval (in milliseconds).
325 #if defined(ANDROID) 261 #if defined(ANDROID)
326 // Phones and tablets have processors that are much slower than desktop 262 // Phones and tablets have processors that are much slower than desktop
327 // and laptop computers for which current heuristics are tuned. 263 // and laptop computers for which current heuristics are tuned.
328 static const int kSamplingIntervalMs = 5; 264 static const int kSamplingIntervalMs = 5;
329 #else 265 #else
330 static const int kSamplingIntervalMs = 1; 266 static const int kSamplingIntervalMs = 1;
331 #endif 267 #endif
332 268
333 // Callback from Log, stops profiling in case of insufficient resources. 269 // Callback from Log, stops profiling in case of insufficient resources.
334 void LogFailure(); 270 void LogFailure();
335 271
336 private: 272 private:
337 explicit Logger(Isolate* isolate); 273 explicit Logger(Isolate* isolate);
338 ~Logger(); 274 ~Logger();
339 275
340 // Emits the profiler's first message. 276 // Emits the profiler's first message.
341 void ProfilerBeginEvent(); 277 void ProfilerBeginEvent();
342 278
343 // Emits callback event messages. 279 // Emits callback event messages.
344 void CallbackEventInternal(const char* prefix, 280 void CallbackEventInternal(const char* prefix,
345 Name* name, 281 Name* name,
346 Address entry_point); 282 Address entry_point);
347 283
348 // Internal configurable move event. 284 // Internal configurable move event.
349 void MoveEventInternal(LogEventsAndTags event, Address from, Address to); 285 void MoveEventInternal(CodeEventListener::LogEventsAndTags event,
286 Address from, Address to);
350 287
351 // Used for logging stubs found in the snapshot. 288 // Used for logging stubs found in the snapshot.
352 void LogCodeObject(Object* code_object); 289 void LogCodeObject(Object* code_object);
353 290
354 // Helper method. It resets name_buffer_ and add tag name into it. 291 // Helper method. It resets name_buffer_ and add tag name into it.
355 void InitNameBuffer(LogEventsAndTags tag); 292 void InitNameBuffer(CodeEventListener::LogEventsAndTags tag);
356 293
357 // Emits a profiler tick event. Used by the profiler thread. 294 // Emits a profiler tick event. Used by the profiler thread.
358 void TickEvent(TickSample* sample, bool overflow); 295 void TickEvent(TickSample* sample, bool overflow);
359 void RuntimeCallTimerEvent(); 296 void RuntimeCallTimerEvent();
360 297
361 PRINTF_FORMAT(2, 3) void ApiEvent(const char* format, ...); 298 PRINTF_FORMAT(2, 3) void ApiEvent(const char* format, ...);
362 299
363 // Logs a StringEvent regardless of whether FLAG_log is true. 300 // Logs a StringEvent regardless of whether FLAG_log is true.
364 void UncheckedStringEvent(const char* name, const char* value); 301 void UncheckedStringEvent(const char* name, const char* value);
365 302
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
457 394
458 protected: 395 protected:
459 // Currently jit_handler_data_ is used to store JITHandler-specific data 396 // Currently jit_handler_data_ is used to store JITHandler-specific data
460 // over the lifetime of a PositionsRecorder 397 // over the lifetime of a PositionsRecorder
461 void* jit_handler_data_; 398 void* jit_handler_data_;
462 399
463 private: 400 private:
464 DISALLOW_COPY_AND_ASSIGN(PositionsRecorder); 401 DISALLOW_COPY_AND_ASSIGN(PositionsRecorder);
465 }; 402 };
466 403
467 class CodeEventListener {
468 public:
469 virtual ~CodeEventListener() {}
470
471 virtual void CodeCreateEvent(Logger::LogEventsAndTags tag, AbstractCode* code,
472 const char* comment) = 0;
473 virtual void CodeCreateEvent(Logger::LogEventsAndTags tag, AbstractCode* code,
474 Name* name) = 0;
475 virtual void CodeCreateEvent(Logger::LogEventsAndTags tag, AbstractCode* code,
476 SharedFunctionInfo* shared, Name* name) = 0;
477 virtual void CodeCreateEvent(Logger::LogEventsAndTags tag, AbstractCode* code,
478 SharedFunctionInfo* shared, Name* source,
479 int line, int column) = 0;
480 virtual void CodeCreateEvent(Logger::LogEventsAndTags tag, AbstractCode* code,
481 int args_count) = 0;
482 virtual void CallbackEvent(Name* name, Address entry_point) = 0;
483 virtual void GetterCallbackEvent(Name* name, Address entry_point) = 0;
484 virtual void SetterCallbackEvent(Name* name, Address entry_point) = 0;
485 virtual void RegExpCodeCreateEvent(AbstractCode* code, String* source) = 0;
486 virtual void CodeMoveEvent(AbstractCode* from, Address to) = 0;
487 virtual void SharedFunctionInfoMoveEvent(Address from, Address to) = 0;
488 virtual void CodeMovingGCEvent() = 0;
489 virtual void CodeDisableOptEvent(AbstractCode* code,
490 SharedFunctionInfo* shared) = 0;
491 };
492
493
494 class CodeEventLogger : public CodeEventListener { 404 class CodeEventLogger : public CodeEventListener {
495 public: 405 public:
496 CodeEventLogger(); 406 CodeEventLogger();
497 ~CodeEventLogger() override; 407 ~CodeEventLogger() override;
498 408
499 void CodeCreateEvent(Logger::LogEventsAndTags tag, AbstractCode* code, 409 void CodeCreateEvent(LogEventsAndTags tag, AbstractCode* code,
500 const char* comment) override; 410 const char* comment) override;
501 void CodeCreateEvent(Logger::LogEventsAndTags tag, AbstractCode* code, 411 void CodeCreateEvent(LogEventsAndTags tag, AbstractCode* code,
502 Name* name) override; 412 Name* name) override;
503 void CodeCreateEvent(Logger::LogEventsAndTags tag, AbstractCode* code, 413 void CodeCreateEvent(LogEventsAndTags tag, AbstractCode* code,
504 int args_count) override; 414 int args_count) override;
505 void CodeCreateEvent(Logger::LogEventsAndTags tag, AbstractCode* code, 415 void CodeCreateEvent(LogEventsAndTags tag, AbstractCode* code,
506 SharedFunctionInfo* shared, Name* name) override; 416 SharedFunctionInfo* shared, Name* name) override;
507 void CodeCreateEvent(Logger::LogEventsAndTags tag, AbstractCode* code, 417 void CodeCreateEvent(LogEventsAndTags tag, AbstractCode* code,
508 SharedFunctionInfo* shared, Name* source, int line, 418 SharedFunctionInfo* shared, Name* source, int line,
509 int column) override; 419 int column) override;
510 void RegExpCodeCreateEvent(AbstractCode* code, String* source) override; 420 void RegExpCodeCreateEvent(AbstractCode* code, String* source) override;
511 421
512 void CallbackEvent(Name* name, Address entry_point) override {} 422 void CallbackEvent(Name* name, Address entry_point) override {}
513 void GetterCallbackEvent(Name* name, Address entry_point) override {} 423 void GetterCallbackEvent(Name* name, Address entry_point) override {}
514 void SetterCallbackEvent(Name* name, Address entry_point) override {} 424 void SetterCallbackEvent(Name* name, Address entry_point) override {}
515 void SharedFunctionInfoMoveEvent(Address from, Address to) override {} 425 void SharedFunctionInfoMoveEvent(Address from, Address to) override {}
516 void CodeMovingGCEvent() override {} 426 void CodeMovingGCEvent() override {}
427 void CodeDeoptEvent(Code* code, Address pc, int fp_to_sp_delta) override {}
517 428
518 private: 429 private:
519 class NameBuffer; 430 class NameBuffer;
520 431
521 virtual void LogRecordedBuffer(AbstractCode* code, SharedFunctionInfo* shared, 432 virtual void LogRecordedBuffer(AbstractCode* code, SharedFunctionInfo* shared,
522 const char* name, int length) = 0; 433 const char* name, int length) = 0;
523 434
524 NameBuffer* name_buffer_; 435 NameBuffer* name_buffer_;
525 }; 436 };
526 437
527 438
528 } // namespace internal 439 } // namespace internal
529 } // namespace v8 440 } // namespace v8
530 441
531 442
532 #endif // V8_LOG_H_ 443 #endif // V8_LOG_H_
OLDNEW
« no previous file with comments | « src/isolate.cc ('k') | src/log.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698