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 4707 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4718 DeoptimizeIf(ne, instr, DeoptimizeReason::kNotASmi, cr0); | 4718 DeoptimizeIf(ne, instr, DeoptimizeReason::kNotASmi, cr0); |
4719 } else { | 4719 } else { |
4720 __ SmiUntag(result, input); | 4720 __ SmiUntag(result, input); |
4721 } | 4721 } |
4722 } | 4722 } |
4723 | 4723 |
4724 | 4724 |
4725 void LCodeGen::EmitNumberUntagD(LNumberUntagD* instr, Register input_reg, | 4725 void LCodeGen::EmitNumberUntagD(LNumberUntagD* instr, Register input_reg, |
4726 DoubleRegister result_reg, | 4726 DoubleRegister result_reg, |
4727 NumberUntagDMode mode) { | 4727 NumberUntagDMode mode) { |
4728 bool can_convert_undefined_to_nan = | 4728 bool can_convert_undefined_to_nan = instr->truncating(); |
4729 instr->hydrogen()->can_convert_undefined_to_nan(); | |
4730 bool deoptimize_on_minus_zero = instr->hydrogen()->deoptimize_on_minus_zero(); | 4729 bool deoptimize_on_minus_zero = instr->hydrogen()->deoptimize_on_minus_zero(); |
4731 | 4730 |
4732 Register scratch = scratch0(); | 4731 Register scratch = scratch0(); |
4733 DCHECK(!result_reg.is(double_scratch0())); | 4732 DCHECK(!result_reg.is(double_scratch0())); |
4734 | 4733 |
4735 Label convert, load_smi, done; | 4734 Label convert, load_smi, done; |
4736 | 4735 |
4737 if (mode == NUMBER_CANDIDATE_IS_ANY_TAGGED) { | 4736 if (mode == NUMBER_CANDIDATE_IS_ANY_TAGGED) { |
4738 // Smi check. | 4737 // Smi check. |
4739 __ UntagAndJumpIfSmi(scratch, input_reg, &load_smi); | 4738 __ UntagAndJumpIfSmi(scratch, input_reg, &load_smi); |
(...skipping 921 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5661 __ LoadP(result, | 5660 __ LoadP(result, |
5662 FieldMemOperand(scratch, FixedArray::kHeaderSize - kPointerSize)); | 5661 FieldMemOperand(scratch, FixedArray::kHeaderSize - kPointerSize)); |
5663 __ bind(deferred->exit()); | 5662 __ bind(deferred->exit()); |
5664 __ bind(&done); | 5663 __ bind(&done); |
5665 } | 5664 } |
5666 | 5665 |
5667 #undef __ | 5666 #undef __ |
5668 | 5667 |
5669 } // namespace internal | 5668 } // namespace internal |
5670 } // namespace v8 | 5669 } // namespace v8 |
OLD | NEW |