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

Side by Side Diff: src/x87/builtins-x87.cc

Issue 2068603002: [debugger] simplify debug stepping. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fix completion callback 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/x64/macro-assembler-x64.cc ('k') | src/x87/macro-assembler-x87.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 #if V8_TARGET_ARCH_X87 5 #if V8_TARGET_ARCH_X87
6 6
7 #include "src/code-factory.h" 7 #include "src/code-factory.h"
8 #include "src/codegen.h" 8 #include "src/codegen.h"
9 #include "src/deoptimizer.h" 9 #include "src/deoptimizer.h"
10 #include "src/full-codegen/full-codegen.h" 10 #include "src/full-codegen/full-codegen.h"
(...skipping 392 matching lines...) Expand 10 before | Expand all | Expand 10 after
403 // Store resume mode into generator object. 403 // Store resume mode into generator object.
404 __ mov(FieldOperand(ebx, JSGeneratorObject::kResumeModeOffset), edx); 404 __ mov(FieldOperand(ebx, JSGeneratorObject::kResumeModeOffset), edx);
405 405
406 // Load suspended function and context. 406 // Load suspended function and context.
407 __ mov(esi, FieldOperand(ebx, JSGeneratorObject::kContextOffset)); 407 __ mov(esi, FieldOperand(ebx, JSGeneratorObject::kContextOffset));
408 __ mov(edi, FieldOperand(ebx, JSGeneratorObject::kFunctionOffset)); 408 __ mov(edi, FieldOperand(ebx, JSGeneratorObject::kFunctionOffset));
409 409
410 // Flood function if we are stepping. 410 // Flood function if we are stepping.
411 Label prepare_step_in_if_stepping, prepare_step_in_suspended_generator; 411 Label prepare_step_in_if_stepping, prepare_step_in_suspended_generator;
412 Label stepping_prepared; 412 Label stepping_prepared;
413 ExternalReference step_in_enabled = 413 ExternalReference last_step_action =
414 ExternalReference::debug_step_in_enabled_address(masm->isolate()); 414 ExternalReference::debug_last_step_action_address(masm->isolate());
415 __ cmpb(Operand::StaticVariable(step_in_enabled), Immediate(0)); 415 STATIC_ASSERT(StepFrame > StepIn);
416 __ j(not_equal, &prepare_step_in_if_stepping); 416 __ cmpb(Operand::StaticVariable(last_step_action), Immediate(StepIn));
417 __ j(greater_equal, &prepare_step_in_if_stepping);
417 418
418 // Flood function if we need to continue stepping in the suspended generator. 419 // Flood function if we need to continue stepping in the suspended generator.
419 ExternalReference debug_suspended_generator = 420 ExternalReference debug_suspended_generator =
420 ExternalReference::debug_suspended_generator_address(masm->isolate()); 421 ExternalReference::debug_suspended_generator_address(masm->isolate());
421 __ cmp(ebx, Operand::StaticVariable(debug_suspended_generator)); 422 __ cmp(ebx, Operand::StaticVariable(debug_suspended_generator));
422 __ j(equal, &prepare_step_in_suspended_generator); 423 __ j(equal, &prepare_step_in_suspended_generator);
423 __ bind(&stepping_prepared); 424 __ bind(&stepping_prepared);
424 425
425 // Pop return address. 426 // Pop return address.
426 __ PopReturnAddressTo(eax); 427 __ PopReturnAddressTo(eax);
(...skipping 2545 matching lines...) Expand 10 before | Expand all | Expand 10 after
2972 // And "return" to the OSR entry point of the function. 2973 // And "return" to the OSR entry point of the function.
2973 __ ret(0); 2974 __ ret(0);
2974 } 2975 }
2975 2976
2976 2977
2977 #undef __ 2978 #undef __
2978 } // namespace internal 2979 } // namespace internal
2979 } // namespace v8 2980 } // namespace v8
2980 2981
2981 #endif // V8_TARGET_ARCH_X87 2982 #endif // V8_TARGET_ARCH_X87
OLDNEW
« no previous file with comments | « src/x64/macro-assembler-x64.cc ('k') | src/x87/macro-assembler-x87.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698