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

Side by Side Diff: src/x64/full-codegen-x64.cc

Issue 595863002: Adding more missing deoptimization points in Turbofan. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebase Created 6 years, 2 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 | Annotate | Revision Log
« no previous file with comments | « src/mips64/full-codegen-mips64.cc ('k') | src/x87/full-codegen-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 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_X64 7 #if V8_TARGET_ARCH_X64
8 8
9 #include "src/code-factory.h" 9 #include "src/code-factory.h"
10 #include "src/code-stubs.h" 10 #include "src/code-stubs.h"
(...skipping 2777 matching lines...) Expand 10 before | Expand all | Expand 10 after
2788 2788
2789 // Push a copy of the function (found below the arguments) and resolve 2789 // Push a copy of the function (found below the arguments) and resolve
2790 // eval. 2790 // eval.
2791 __ Push(Operand(rsp, (arg_count + 1) * kPointerSize)); 2791 __ Push(Operand(rsp, (arg_count + 1) * kPointerSize));
2792 EmitResolvePossiblyDirectEval(arg_count); 2792 EmitResolvePossiblyDirectEval(arg_count);
2793 2793
2794 // The runtime call returns a pair of values in rax (function) and 2794 // The runtime call returns a pair of values in rax (function) and
2795 // rdx (receiver). Touch up the stack with the right values. 2795 // rdx (receiver). Touch up the stack with the right values.
2796 __ movp(Operand(rsp, (arg_count + 0) * kPointerSize), rdx); 2796 __ movp(Operand(rsp, (arg_count + 0) * kPointerSize), rdx);
2797 __ movp(Operand(rsp, (arg_count + 1) * kPointerSize), rax); 2797 __ movp(Operand(rsp, (arg_count + 1) * kPointerSize), rax);
2798
2799 PrepareForBailoutForId(expr->EvalOrLookupId(), NO_REGISTERS);
2798 } 2800 }
2799 // Record source position for debugger. 2801 // Record source position for debugger.
2800 SetSourcePosition(expr->position()); 2802 SetSourcePosition(expr->position());
2801 CallFunctionStub stub(isolate(), arg_count, NO_CALL_FUNCTION_FLAGS); 2803 CallFunctionStub stub(isolate(), arg_count, NO_CALL_FUNCTION_FLAGS);
2802 __ movp(rdi, Operand(rsp, (arg_count + 1) * kPointerSize)); 2804 __ movp(rdi, Operand(rsp, (arg_count + 1) * kPointerSize));
2803 __ CallStub(&stub); 2805 __ CallStub(&stub);
2804 RecordJSReturnSite(expr); 2806 RecordJSReturnSite(expr);
2805 // Restore context register. 2807 // Restore context register.
2806 __ movp(rsi, Operand(rbp, StandardFrameConstants::kContextOffset)); 2808 __ movp(rsi, Operand(rbp, StandardFrameConstants::kContextOffset));
2807 context()->DropAndPlug(1, rax); 2809 context()->DropAndPlug(1, rax);
(...skipping 11 matching lines...) Expand all
2819 EmitDynamicLookupFastCase(proxy, NOT_INSIDE_TYPEOF, &slow, &done); 2821 EmitDynamicLookupFastCase(proxy, NOT_INSIDE_TYPEOF, &slow, &done);
2820 } 2822 }
2821 __ bind(&slow); 2823 __ bind(&slow);
2822 // Call the runtime to find the function to call (returned in rax) and 2824 // Call the runtime to find the function to call (returned in rax) and
2823 // the object holding it (returned in rdx). 2825 // the object holding it (returned in rdx).
2824 __ Push(context_register()); 2826 __ Push(context_register());
2825 __ Push(proxy->name()); 2827 __ Push(proxy->name());
2826 __ CallRuntime(Runtime::kLoadLookupSlot, 2); 2828 __ CallRuntime(Runtime::kLoadLookupSlot, 2);
2827 __ Push(rax); // Function. 2829 __ Push(rax); // Function.
2828 __ Push(rdx); // Receiver. 2830 __ Push(rdx); // Receiver.
2831 PrepareForBailoutForId(expr->EvalOrLookupId(), NO_REGISTERS);
2829 2832
2830 // If fast case code has been generated, emit code to push the function 2833 // If fast case code has been generated, emit code to push the function
2831 // and receiver and have the slow path jump around this code. 2834 // and receiver and have the slow path jump around this code.
2832 if (done.is_linked()) { 2835 if (done.is_linked()) {
2833 Label call; 2836 Label call;
2834 __ jmp(&call, Label::kNear); 2837 __ jmp(&call, Label::kNear);
2835 __ bind(&done); 2838 __ bind(&done);
2836 // Push function. 2839 // Push function.
2837 __ Push(rax); 2840 __ Push(rax);
2838 // The receiver is implicitly the global receiver. Indicate this by 2841 // The receiver is implicitly the global receiver. Indicate this by
(...skipping 2124 matching lines...) Expand 10 before | Expand all | Expand 10 after
4963 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), 4966 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(),
4964 Assembler::target_address_at(call_target_address, 4967 Assembler::target_address_at(call_target_address,
4965 unoptimized_code)); 4968 unoptimized_code));
4966 return OSR_AFTER_STACK_CHECK; 4969 return OSR_AFTER_STACK_CHECK;
4967 } 4970 }
4968 4971
4969 4972
4970 } } // namespace v8::internal 4973 } } // namespace v8::internal
4971 4974
4972 #endif // V8_TARGET_ARCH_X64 4975 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/mips64/full-codegen-mips64.cc ('k') | src/x87/full-codegen-x87.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698