Chromium Code Reviews| OLD | NEW |
|---|---|
| 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_DEBUG_H_ | 5 #ifndef V8_DEBUG_H_ |
| 6 #define V8_DEBUG_H_ | 6 #define V8_DEBUG_H_ |
| 7 | 7 |
| 8 #include "src/allocation.h" | 8 #include "src/allocation.h" |
| 9 #include "src/arguments.h" | 9 #include "src/arguments.h" |
| 10 #include "src/assembler.h" | 10 #include "src/assembler.h" |
| (...skipping 346 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 357 | 357 |
| 358 // This class contains the debugger support. The main purpose is to handle | 358 // This class contains the debugger support. The main purpose is to handle |
| 359 // setting break points in the code. | 359 // setting break points in the code. |
| 360 // | 360 // |
| 361 // This class controls the debug info for all functions which currently have | 361 // This class controls the debug info for all functions which currently have |
| 362 // active breakpoints in them. This debug info is held in the heap root object | 362 // active breakpoints in them. This debug info is held in the heap root object |
| 363 // debug_info which is a FixedArray. Each entry in this list is of class | 363 // debug_info which is a FixedArray. Each entry in this list is of class |
| 364 // DebugInfo. | 364 // DebugInfo. |
| 365 class Debug { | 365 class Debug { |
| 366 public: | 366 public: |
| 367 enum AfterCompileFlags { | |
| 368 NO_AFTER_COMPILE_FLAGS, | |
|
yurys
2014/06/11 11:52:14
It might make sense to do this clean-up in a separ
| |
| 369 SEND_WHEN_DEBUGGING | |
| 370 }; | |
| 371 | |
| 372 // Debug event triggers. | 367 // Debug event triggers. |
| 373 void OnDebugBreak(Handle<Object> break_points_hit, bool auto_continue); | 368 void OnDebugBreak(Handle<Object> break_points_hit, bool auto_continue); |
| 374 void OnException(Handle<Object> exception, bool uncaught); | 369 void OnException(Handle<Object> exception, bool uncaught); |
| 370 void OnCompileError(Handle<Script> script); | |
| 375 void OnBeforeCompile(Handle<Script> script); | 371 void OnBeforeCompile(Handle<Script> script); |
| 376 void OnAfterCompile(Handle<Script> script, | 372 void OnAfterCompile(Handle<Script> script); |
| 377 AfterCompileFlags after_compile_flags); | |
| 378 void OnScriptCollected(int id); | 373 void OnScriptCollected(int id); |
| 379 | 374 |
| 380 // API facing. | 375 // API facing. |
| 381 void SetEventListener(Handle<Object> callback, Handle<Object> data); | 376 void SetEventListener(Handle<Object> callback, Handle<Object> data); |
| 382 void SetMessageHandler(v8::Debug::MessageHandler handler); | 377 void SetMessageHandler(v8::Debug::MessageHandler handler); |
| 383 void EnqueueCommandMessage(Vector<const uint16_t> command, | 378 void EnqueueCommandMessage(Vector<const uint16_t> command, |
| 384 v8::Debug::ClientData* client_data = NULL); | 379 v8::Debug::ClientData* client_data = NULL); |
| 385 // Enqueue a debugger command to the command queue for event listeners. | 380 // Enqueue a debugger command to the command queue for event listeners. |
| 386 void EnqueueDebugCommand(v8::Debug::ClientData* client_data = NULL); | 381 void EnqueueDebugCommand(v8::Debug::ClientData* client_data = NULL); |
| 387 MUST_USE_RESULT MaybeHandle<Object> Call(Handle<JSFunction> fun, | 382 MUST_USE_RESULT MaybeHandle<Object> Call(Handle<JSFunction> fun, |
| (...skipping 376 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 764 // several frames above. | 759 // several frames above. |
| 765 // There is no calling conventions here, because it never actually gets | 760 // There is no calling conventions here, because it never actually gets |
| 766 // called, it only gets returned to. | 761 // called, it only gets returned to. |
| 767 static void GenerateFrameDropperLiveEdit(MacroAssembler* masm); | 762 static void GenerateFrameDropperLiveEdit(MacroAssembler* masm); |
| 768 }; | 763 }; |
| 769 | 764 |
| 770 | 765 |
| 771 } } // namespace v8::internal | 766 } } // namespace v8::internal |
| 772 | 767 |
| 773 #endif // V8_DEBUG_H_ | 768 #endif // V8_DEBUG_H_ |
| OLD | NEW |