| 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 #if V8_TARGET_ARCH_IA32 | 5 #if V8_TARGET_ARCH_IA32 |
| 6 | 6 |
| 7 #include "src/codegen.h" | 7 #include "src/codegen.h" |
| 8 #include "src/deoptimizer.h" | 8 #include "src/deoptimizer.h" |
| 9 #include "src/full-codegen/full-codegen.h" | 9 #include "src/full-codegen/full-codegen.h" |
| 10 #include "src/ia32/frames-ia32.h" | 10 #include "src/ia32/frames-ia32.h" |
| (...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 295 __ push(eax); | 295 __ push(eax); |
| 296 __ PrepareCallCFunction(1, ebx); | 296 __ PrepareCallCFunction(1, ebx); |
| 297 __ mov(Operand(esp, 0 * kPointerSize), eax); | 297 __ mov(Operand(esp, 0 * kPointerSize), eax); |
| 298 { | 298 { |
| 299 AllowExternalCallThatCantCauseGC scope(masm()); | 299 AllowExternalCallThatCantCauseGC scope(masm()); |
| 300 __ CallCFunction( | 300 __ CallCFunction( |
| 301 ExternalReference::compute_output_frames_function(isolate()), 1); | 301 ExternalReference::compute_output_frames_function(isolate()), 1); |
| 302 } | 302 } |
| 303 __ pop(eax); | 303 __ pop(eax); |
| 304 | 304 |
| 305 // Replace the current frame with the output frames. | 305 __ mov(esp, Operand(eax, Deoptimizer::caller_frame_top_offset())); |
| 306 |
| 307 // Replace the current (input) frame with the output frames. |
| 306 Label outer_push_loop, inner_push_loop, | 308 Label outer_push_loop, inner_push_loop, |
| 307 outer_loop_header, inner_loop_header; | 309 outer_loop_header, inner_loop_header; |
| 308 // Outer loop state: eax = current FrameDescription**, edx = one past the | 310 // Outer loop state: eax = current FrameDescription**, edx = one past the |
| 309 // last FrameDescription**. | 311 // last FrameDescription**. |
| 310 __ mov(edx, Operand(eax, Deoptimizer::output_count_offset())); | 312 __ mov(edx, Operand(eax, Deoptimizer::output_count_offset())); |
| 311 __ mov(eax, Operand(eax, Deoptimizer::output_offset())); | 313 __ mov(eax, Operand(eax, Deoptimizer::output_offset())); |
| 312 __ lea(edx, Operand(eax, edx, times_4, 0)); | 314 __ lea(edx, Operand(eax, edx, times_4, 0)); |
| 313 __ jmp(&outer_loop_header); | 315 __ jmp(&outer_loop_header); |
| 314 __ bind(&outer_push_loop); | 316 __ bind(&outer_push_loop); |
| 315 // Inner loop state: ebx = current FrameDescription*, ecx = loop index. | 317 // Inner loop state: ebx = current FrameDescription*, ecx = loop index. |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 385 } | 387 } |
| 386 | 388 |
| 387 | 389 |
| 388 #undef __ | 390 #undef __ |
| 389 | 391 |
| 390 | 392 |
| 391 } // namespace internal | 393 } // namespace internal |
| 392 } // namespace v8 | 394 } // namespace v8 |
| 393 | 395 |
| 394 #endif // V8_TARGET_ARCH_IA32 | 396 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |