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 #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 5166 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5177 // Check for undetectable objects => false. | 5177 // Check for undetectable objects => false. |
5178 __ CmpObjectType(rax, FIRST_NONSTRING_TYPE, rdx); | 5178 __ CmpObjectType(rax, FIRST_NONSTRING_TYPE, rdx); |
5179 __ j(above_equal, if_false); | 5179 __ j(above_equal, if_false); |
5180 __ testb(FieldOperand(rdx, Map::kBitFieldOffset), | 5180 __ testb(FieldOperand(rdx, Map::kBitFieldOffset), |
5181 Immediate(1 << Map::kIsUndetectable)); | 5181 Immediate(1 << Map::kIsUndetectable)); |
5182 Split(zero, if_true, if_false, fall_through); | 5182 Split(zero, if_true, if_false, fall_through); |
5183 } else if (String::Equals(check, factory->symbol_string())) { | 5183 } else if (String::Equals(check, factory->symbol_string())) { |
5184 __ JumpIfSmi(rax, if_false); | 5184 __ JumpIfSmi(rax, if_false); |
5185 __ CmpObjectType(rax, SYMBOL_TYPE, rdx); | 5185 __ CmpObjectType(rax, SYMBOL_TYPE, rdx); |
5186 Split(equal, if_true, if_false, fall_through); | 5186 Split(equal, if_true, if_false, fall_through); |
5187 } else if (String::Equals(check, factory->float32x4_string())) { | |
5188 __ JumpIfSmi(rax, if_false); | |
5189 __ CmpObjectType(rax, FLOAT32X4_TYPE, rdx); | |
5190 Split(equal, if_true, if_false, fall_through); | |
5191 } else if (String::Equals(check, factory->boolean_string())) { | 5187 } else if (String::Equals(check, factory->boolean_string())) { |
5192 __ CompareRoot(rax, Heap::kTrueValueRootIndex); | 5188 __ CompareRoot(rax, Heap::kTrueValueRootIndex); |
5193 __ j(equal, if_true); | 5189 __ j(equal, if_true); |
5194 __ CompareRoot(rax, Heap::kFalseValueRootIndex); | 5190 __ CompareRoot(rax, Heap::kFalseValueRootIndex); |
5195 Split(equal, if_true, if_false, fall_through); | 5191 Split(equal, if_true, if_false, fall_through); |
5196 } else if (String::Equals(check, factory->undefined_string())) { | 5192 } else if (String::Equals(check, factory->undefined_string())) { |
5197 __ CompareRoot(rax, Heap::kUndefinedValueRootIndex); | 5193 __ CompareRoot(rax, Heap::kUndefinedValueRootIndex); |
5198 __ j(equal, if_true); | 5194 __ j(equal, if_true); |
5199 __ JumpIfSmi(rax, if_false); | 5195 __ JumpIfSmi(rax, if_false); |
5200 // Check for undetectable objects => true. | 5196 // Check for undetectable objects => true. |
(...skipping 316 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5517 Assembler::target_address_at(call_target_address, | 5513 Assembler::target_address_at(call_target_address, |
5518 unoptimized_code)); | 5514 unoptimized_code)); |
5519 return OSR_AFTER_STACK_CHECK; | 5515 return OSR_AFTER_STACK_CHECK; |
5520 } | 5516 } |
5521 | 5517 |
5522 | 5518 |
5523 } // namespace internal | 5519 } // namespace internal |
5524 } // namespace v8 | 5520 } // namespace v8 |
5525 | 5521 |
5526 #endif // V8_TARGET_ARCH_X64 | 5522 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |