Home | History | Annotate | Download | only in debug

Lines Matching defs:Debug

5 #include "src/debug/debug.h"
17 #include "src/debug/liveedit.h"
32 #include "include/v8-debug.h"
37 Debug::Debug(Isolate* isolate)
395 void Debug::ThreadInit() {
411 char* Debug::ArchiveDebug(char* storage) {
418 char* Debug::RestoreDebug(char* storage) {
424 int Debug::ArchiveSpacePerThread() { return 0; }
426 void Debug::Iterate(ObjectVisitor* v) {
431 // Globalize the request debug info object and make it weak.
445 bool Debug::Load() {
463 // as debug context. This dependency is gone once we remove
464 // debug context completely.
482 void Debug::Unload() {
494 void Debug::Break(JavaScriptFrame* frame) {
510 // Get the debug info (create it if it does not exist).
514 // Return if we failed to retrieve the debug info.
522 // Find actual break points, if any, and trigger debug break event.
527 // Notify the debug event listeners.
571 // Notify the debug event listeners.
582 Handle<Object> Debug::CheckBreakPoints(Handle<DebugInfo> debug_info,
620 bool Debug::IsMutedAtCurrentLocation(JavaScriptFrame* frame) {
623 // evaluate to false. Aside from not triggering a debug break event at the
649 MaybeHandle<Object> Debug::CallFunction(const char* name, int argc,
663 bool Debug::CheckBreakPoint(Handle<Object> break_point_object) {
671 Handle<Object> break_id = factory->NewNumberFromInt(Debug::break_id());
686 bool Debug::SetBreakPoint(Handle<JSFunction> function,
691 // Make sure the function is compiled and has set up the debug info.
694 // Return if retrieving debug info failed.
717 bool Debug::SetBreakPointForScript(Handle<Script> script,
732 // Make sure the function has set up the debug info.
735 // Return if retrieving debug info failed.
761 int Debug::FindBreakablePosition(Handle<DebugInfo> debug_info,
781 void Debug::ApplyBreakPoints(Handle<DebugInfo> debug_info) {
802 void Debug::ClearBreakPoints(Handle<DebugInfo> debug_info) {
818 void Debug::ClearBreakPoint(Handle<Object> break_point_object) {
839 // Clear out all the debug break code. This is ONLY supposed to be used when
842 void Debug::ClearAllBreakPoints() {
847 // Remove all debug info.
853 void Debug::FloodWithOneShot(Handle<JSFunction> function,
855 // Debug utility functions are not subject to debugging.
860 // deoptimized, because optimized code does not check for debug
865 // Make sure the function is compiled and has set up the debug info.
868 // Return if we failed to retrieve the debug info.
887 void Debug::ChangeBreakOnException(ExceptionBreakType type, bool enable) {
896 bool Debug::IsBreakOnException(ExceptionBreakType type) {
905 void Debug::PrepareStepIn(Handle<JSFunction> function) {
912 void Debug
923 void Debug::PrepareStepOnThrow() {
958 void Debug::PrepareStep(StepAction step_action) {
963 // Get the frame where the execution has stopped and skip the debug frame if
964 // any. The debug frame will only be present if execution was stopped due to
966 // debug frame is not present.
991 // Get the debug info (create it if it does not exist).
996 // Return if ensuring debug info failed.
1055 Handle<Object> Debug::GetSourceBreakLocations(
1099 void Debug::ClearStepping() {
1113 void Debug::ClearOneShot() {
1251 // debug break slots.
1262 bool Debug::PrepareFunctionForBreakPoints(Handle<SharedFunctionInfo> shared) {
1326 // We do not need to replace code to debug bytecode.
1330 // We do not need to recompile to debug bytecode.
1384 bool Debug::GetPossibleBreakpoints(Handle<Script> script, int start_position,
1435 void Debug::RecordAsyncFunction(Handle<JSGeneratorObject> generator_object) {
1497 // While we are at this, also ensure code with debug break slots so that we do
1500 Handle<Object> Debug::FindSharedFunctionInfoInScript(Handle<Script> script,
1519 // We found it if it's already compiled and has debug code.
1524 // be no JSFunction referencing it. We can anticipate creating a debug
1543 // Ensures the debug information is present for shared.
1544 bool Debug::EnsureDebugInfo(Handle<SharedFunctionInfo> shared,
1548 // Return if we already have the debug info for shared.
1557 // To prepare bytecode for debugging, we already need to have the debug
1558 // info (containing the debug copy) upfront, but since we do not recompile,
1566 void Debug::CreateDebugInfo(Handle<SharedFunctionInfo> shared) {
1567 // Create the debug info object.
1570 // Add debug info to the list.
1577 void Debug::RemoveDebugInfoAndClearFromShared(Handle<DebugInfo> debug_info) {
1582 // Run through the debug info objects to find this one and remove it.
1605 void Debug::SetAfterBreakTarget(JavaScriptFrame* frame) {
1613 bool Debug::IsBreakAtReturn(JavaScriptFrame* frame) {
1616 // Get the executing function in which the debug break occurred.
1619 // With no debug info there are no break points, so we can't be at a return.
1628 void Debug::FramesHaveBeenDropped(StackFrame::Id new_break_frame_id,
1637 bool Debug::IsDebugGlobal(JSGlobalObject* global) {
1642 void Debug::ClearMirrorCache() {
1649 Handle<FixedArray> Debug::GetLoadedScripts() {
1672 MaybeHandle<Object> Debug::MakeExecutionState() {
1679 MaybeHandle<Object> Debug::MakeBreakEvent(Handle<Object> break_points_hit) {
1687 MaybeHandle<Object> Debug::MakeExceptionEvent(Handle<Object> exception,
1699 MaybeHandle<Object> Debug::MakeCompileEvent(Handle<Script> script,
1708 MaybeHandle<Object> Debug::MakeAsyncTaskEvent(Handle<String> type,
1718 void Debug::OnThrow(Handle<Object> exception) {
1722 // JavaScript from the debug event handler.
1735 void Debug::OnPromiseReject(Handle<Object> promise, Handle<Object> value) {
1748 void Debug::OnException(Handle<Object> exception, Handle<Object> promise) {
1749 // We cannot generate debug events when JS execution is disallowed.
1750 // TODO(5530): Reenable debug events within DisallowJSScopes once relevant
1794 debug event.
1800 void Debug::OnDebugBreak(Handle<Object> break_points_hit, bool auto_continue) {
1806 #ifdef DEBUG
1808 #endif // DEBUG
1816 // Process debug event.
1823 void Debug::OnCompileError(Handle<Script> script) {
1828 void Debug::OnBeforeCompile(Handle<Script> script) {
1834 void Debug::OnAfterCompile(Handle<Script> script) {
1838 void Debug::OnAsyncTaskEvent(Handle<String> type, Handle<Object> id,
1852 // Process debug event.
1859 void Debug::ProcessDebugEvent(v8::DebugEvent event,
1876 // Notify registered debug event listener. This can be either a C or
1878 // here, if it's only a debug command -- they will be processed later.
1885 void Debug::CallEventCallback(v8::DebugEvent event,
1888 v8::Debug::ClientData* client_data) {
1895 // Invoke the C debug event listener.
1907 // Invoke the JavaScript debug event listener.
1923 void Debug::ProcessCompileEvent(v8::DebugEvent event, Handle<Script> script) {
1947 // Don't call NotifyMessageHandler if already in debug scope to avoid running
1958 // Process debug event.
1964 Handle<Context> Debug::GetDebugContext() {
1973 void Debug::NotifyMessageHandler(v8::DebugEvent event,
1999 // The debug command interrupt flag might have been set when the command was
2005 // Notify the debugger that a debug event has occurred unless auto continue is
2100 // Return from debug event processing if either the VM is put into the
2108 void Debug::SetEventListener(Handle<Object> callback,
2129 void Debug::SetMessageHandler(v8::Debug::MessageHandler handler) {
2141 void Debug::UpdateState() {
2144 // Note that the debug context could have already been loaded to
2156 // Calls the registered debug message handler. This callback is part of the
2158 void Debug::InvokeMessageHandler(MessageImpl message) {
2167 void Debug::EnqueueCommandMessage(Vector<const uint16_t> command,
2168 v8::Debug::ClientData* client_data) {
2178 // Set the debug command break flag to have the command processed.
2183 MaybeHandle<Object> Debug::Call(Handle<Object> fun, Handle<Object> data) {
2203 void Debug::HandleDebugBreak() {
2204 // Ignore debug break during bootstrapping.
2208 // Ignore debug break if debugger is not active.
2242 void Debug::ProcessDebugMessages(bool debug_command_only) {
2252 // Notify the debug event listeners. Indicate auto continue if the break was
2253 // a debug command break.
2257 #ifdef DEBUG
2258 void Debug::PrintBreakLocation() {
2268 PrintF("[debug] break in function '");
2286 PrintF("[debug] %.*s\n", line_end - line_start,
2288 PrintF("[debug] ");
2292 PrintF("[debug] at line %d column %d\n", line, column);
2296 #endif // DEBUG
2298 DebugScope::DebugScope(Debug* debug)
2299 : debug_(debug),
2300 prev_(debug->debugger_entry()),
2327 if (!failed_) isolate()->set_context(*debug->debug_context());
2335 // JavaScript. This can happen if the v8::Debug::Call is used in which
2372 v8::Debug::ClientData* client_data) {
2385 v8::Debug::ClientData* client_data)
2435 // Call toJSONProtocol on the debug event object.
2457 Handle<Context> context = isolate->debug()->debugger_entry()->GetContext();
2475 v8::Debug::ClientData* MessageImpl::GetClientData() const {
2484 v8::Debug::ClientData* client_data)
2517 v8::Debug::ClientData* EventDetailsImpl::GetClientData() const {
2531 v8::Debug::ClientData* data)
2545 v8::Debug::ClientData* data) {