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_X64 | 5 #if V8_TARGET_ARCH_X64 |
6 | 6 |
7 #include "src/code-factory.h" | 7 #include "src/code-factory.h" |
8 #include "src/code-stubs.h" | 8 #include "src/code-stubs.h" |
9 #include "src/codegen.h" | 9 #include "src/codegen.h" |
10 #include "src/debug/debug.h" | 10 #include "src/debug/debug.h" |
(...skipping 4863 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4874 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); | 4874 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); |
4875 if (expr->op() == Token::EQ_STRICT) { | 4875 if (expr->op() == Token::EQ_STRICT) { |
4876 Heap::RootListIndex nil_value = nil == kNullValue ? | 4876 Heap::RootListIndex nil_value = nil == kNullValue ? |
4877 Heap::kNullValueRootIndex : | 4877 Heap::kNullValueRootIndex : |
4878 Heap::kUndefinedValueRootIndex; | 4878 Heap::kUndefinedValueRootIndex; |
4879 __ CompareRoot(rax, nil_value); | 4879 __ CompareRoot(rax, nil_value); |
4880 Split(equal, if_true, if_false, fall_through); | 4880 Split(equal, if_true, if_false, fall_through); |
4881 } else { | 4881 } else { |
4882 Handle<Code> ic = CompareNilICStub::GetUninitialized(isolate(), nil); | 4882 Handle<Code> ic = CompareNilICStub::GetUninitialized(isolate(), nil); |
4883 CallIC(ic, expr->CompareOperationFeedbackId()); | 4883 CallIC(ic, expr->CompareOperationFeedbackId()); |
4884 __ testp(rax, rax); | 4884 __ CompareRoot(rax, Heap::kTrueValueRootIndex); |
4885 Split(not_zero, if_true, if_false, fall_through); | 4885 Split(equal, if_true, if_false, fall_through); |
4886 } | 4886 } |
4887 context()->Plug(if_true, if_false); | 4887 context()->Plug(if_true, if_false); |
4888 } | 4888 } |
4889 | 4889 |
4890 | 4890 |
4891 void FullCodeGenerator::VisitThisFunction(ThisFunction* expr) { | 4891 void FullCodeGenerator::VisitThisFunction(ThisFunction* expr) { |
4892 __ movp(rax, Operand(rbp, JavaScriptFrameConstants::kFunctionOffset)); | 4892 __ movp(rax, Operand(rbp, JavaScriptFrameConstants::kFunctionOffset)); |
4893 context()->Plug(rax); | 4893 context()->Plug(rax); |
4894 } | 4894 } |
4895 | 4895 |
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5076 Assembler::target_address_at(call_target_address, | 5076 Assembler::target_address_at(call_target_address, |
5077 unoptimized_code)); | 5077 unoptimized_code)); |
5078 return OSR_AFTER_STACK_CHECK; | 5078 return OSR_AFTER_STACK_CHECK; |
5079 } | 5079 } |
5080 | 5080 |
5081 | 5081 |
5082 } // namespace internal | 5082 } // namespace internal |
5083 } // namespace v8 | 5083 } // namespace v8 |
5084 | 5084 |
5085 #endif // V8_TARGET_ARCH_X64 | 5085 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |