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

Side by Side Diff: src/debug/debug.cc

Issue 1894263002: [Debugger] Fix StepNext over function with caught exception (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 8 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 | test/cctest/test-debug.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 #include "src/debug/debug.h" 5 #include "src/debug/debug.h"
6 6
7 #include "src/api.h" 7 #include "src/api.h"
8 #include "src/arguments.h" 8 #include "src/arguments.h"
9 #include "src/bootstrapper.h" 9 #include "src/bootstrapper.h"
10 #include "src/code-stubs.h" 10 #include "src/code-stubs.h"
(...skipping 938 matching lines...) Expand 10 before | Expand all | Expand 10 after
949 ClearOneShot(); 949 ClearOneShot();
950 950
951 // Iterate through the JavaScript stack looking for handlers. 951 // Iterate through the JavaScript stack looking for handlers.
952 JavaScriptFrameIterator it(isolate_); 952 JavaScriptFrameIterator it(isolate_);
953 while (!it.done()) { 953 while (!it.done()) {
954 JavaScriptFrame* frame = it.frame(); 954 JavaScriptFrame* frame = it.frame();
955 if (frame->LookupExceptionHandlerInTable(nullptr, nullptr) > 0) break; 955 if (frame->LookupExceptionHandlerInTable(nullptr, nullptr) > 0) break;
956 it.Advance(); 956 it.Advance();
957 } 957 }
958 958
959 if (last_step_action() == StepNext) {
960 while (!it.done()) {
961 Address current_fp = it.frame()->UnpaddedFP();
962 if (current_fp >= thread_local_.target_fp_) break;
963 it.Advance();
964 }
965 }
966
959 // Find the closest Javascript frame we can flood with one-shots. 967 // Find the closest Javascript frame we can flood with one-shots.
960 while (!it.done() && 968 while (!it.done() &&
961 !it.frame()->function()->shared()->IsSubjectToDebugging()) { 969 !it.frame()->function()->shared()->IsSubjectToDebugging()) {
962 it.Advance(); 970 it.Advance();
963 } 971 }
964 972
965 if (it.done()) return; // No suitable Javascript catch handler. 973 if (it.done()) return; // No suitable Javascript catch handler.
966 974
967 FloodWithOneShot(Handle<JSFunction>(it.frame()->function())); 975 FloodWithOneShot(Handle<JSFunction>(it.frame()->function()));
968 } 976 }
(...skipping 1607 matching lines...) Expand 10 before | Expand all | Expand 10 after
2576 } 2584 }
2577 2585
2578 2586
2579 void LockingCommandMessageQueue::Clear() { 2587 void LockingCommandMessageQueue::Clear() {
2580 base::LockGuard<base::Mutex> lock_guard(&mutex_); 2588 base::LockGuard<base::Mutex> lock_guard(&mutex_);
2581 queue_.Clear(); 2589 queue_.Clear();
2582 } 2590 }
2583 2591
2584 } // namespace internal 2592 } // namespace internal
2585 } // namespace v8 2593 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | test/cctest/test-debug.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698