OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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/crankshaft/ppc/lithium-codegen-ppc.h" | 5 #include "src/crankshaft/ppc/lithium-codegen-ppc.h" |
6 | 6 |
7 #include "src/base/bits.h" | 7 #include "src/base/bits.h" |
8 #include "src/code-factory.h" | 8 #include "src/code-factory.h" |
9 #include "src/code-stubs.h" | 9 #include "src/code-stubs.h" |
10 #include "src/crankshaft/hydrogen-osr.h" | 10 #include "src/crankshaft/hydrogen-osr.h" |
(...skipping 5460 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5471 __ CompareObjectType(input, scratch, no_reg, SYMBOL_TYPE); | 5471 __ CompareObjectType(input, scratch, no_reg, SYMBOL_TYPE); |
5472 final_branch_condition = eq; | 5472 final_branch_condition = eq; |
5473 | 5473 |
5474 } else if (String::Equals(type_name, factory->boolean_string())) { | 5474 } else if (String::Equals(type_name, factory->boolean_string())) { |
5475 __ CompareRoot(input, Heap::kTrueValueRootIndex); | 5475 __ CompareRoot(input, Heap::kTrueValueRootIndex); |
5476 __ beq(true_label); | 5476 __ beq(true_label); |
5477 __ CompareRoot(input, Heap::kFalseValueRootIndex); | 5477 __ CompareRoot(input, Heap::kFalseValueRootIndex); |
5478 final_branch_condition = eq; | 5478 final_branch_condition = eq; |
5479 | 5479 |
5480 } else if (String::Equals(type_name, factory->undefined_string())) { | 5480 } else if (String::Equals(type_name, factory->undefined_string())) { |
5481 __ CompareRoot(input, Heap::kUndefinedValueRootIndex); | 5481 __ CompareRoot(input, Heap::kNullValueRootIndex); |
5482 __ beq(true_label); | 5482 __ beq(false_label); |
5483 __ JumpIfSmi(input, false_label); | 5483 __ JumpIfSmi(input, false_label); |
5484 // Check for undetectable objects => true. | 5484 // Check for undetectable objects => true. |
5485 __ LoadP(scratch, FieldMemOperand(input, HeapObject::kMapOffset)); | 5485 __ LoadP(scratch, FieldMemOperand(input, HeapObject::kMapOffset)); |
5486 __ lbz(scratch, FieldMemOperand(scratch, Map::kBitFieldOffset)); | 5486 __ lbz(scratch, FieldMemOperand(scratch, Map::kBitFieldOffset)); |
5487 __ ExtractBit(r0, scratch, Map::kIsUndetectable); | 5487 __ ExtractBit(r0, scratch, Map::kIsUndetectable); |
5488 __ cmpi(r0, Operand::Zero()); | 5488 __ cmpi(r0, Operand::Zero()); |
5489 final_branch_condition = ne; | 5489 final_branch_condition = ne; |
5490 | 5490 |
5491 } else if (String::Equals(type_name, factory->function_string())) { | 5491 } else if (String::Equals(type_name, factory->function_string())) { |
5492 __ JumpIfSmi(input, false_label); | 5492 __ JumpIfSmi(input, false_label); |
(...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5781 __ Push(scope_info); | 5781 __ Push(scope_info); |
5782 __ push(ToRegister(instr->function())); | 5782 __ push(ToRegister(instr->function())); |
5783 CallRuntime(Runtime::kPushBlockContext, instr); | 5783 CallRuntime(Runtime::kPushBlockContext, instr); |
5784 RecordSafepoint(Safepoint::kNoLazyDeopt); | 5784 RecordSafepoint(Safepoint::kNoLazyDeopt); |
5785 } | 5785 } |
5786 | 5786 |
5787 | 5787 |
5788 #undef __ | 5788 #undef __ |
5789 } // namespace internal | 5789 } // namespace internal |
5790 } // namespace v8 | 5790 } // namespace v8 |
OLD | NEW |