| 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/crankshaft/arm/lithium-codegen-arm.h" | 5 #include "src/crankshaft/arm/lithium-codegen-arm.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/arm/lithium-gap-resolver-arm.h" | 10 #include "src/crankshaft/arm/lithium-gap-resolver-arm.h" |
| (...skipping 5164 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5175 | 5175 |
| 5176 void LCodeGen::DoTypeof(LTypeof* instr) { | 5176 void LCodeGen::DoTypeof(LTypeof* instr) { |
| 5177 DCHECK(ToRegister(instr->value()).is(r3)); | 5177 DCHECK(ToRegister(instr->value()).is(r3)); |
| 5178 DCHECK(ToRegister(instr->result()).is(r0)); | 5178 DCHECK(ToRegister(instr->result()).is(r0)); |
| 5179 Label end, do_call; | 5179 Label end, do_call; |
| 5180 Register value_register = ToRegister(instr->value()); | 5180 Register value_register = ToRegister(instr->value()); |
| 5181 __ JumpIfNotSmi(value_register, &do_call); | 5181 __ JumpIfNotSmi(value_register, &do_call); |
| 5182 __ mov(r0, Operand(isolate()->factory()->number_string())); | 5182 __ mov(r0, Operand(isolate()->factory()->number_string())); |
| 5183 __ jmp(&end); | 5183 __ jmp(&end); |
| 5184 __ bind(&do_call); | 5184 __ bind(&do_call); |
| 5185 TypeofStub stub(isolate()); | 5185 Callable callable = CodeFactory::Typeof(isolate()); |
| 5186 CallCode(stub.GetCode(), RelocInfo::CODE_TARGET, instr); | 5186 CallCode(callable.code(), RelocInfo::CODE_TARGET, instr); |
| 5187 __ bind(&end); | 5187 __ bind(&end); |
| 5188 } | 5188 } |
| 5189 | 5189 |
| 5190 | 5190 |
| 5191 void LCodeGen::DoTypeofIsAndBranch(LTypeofIsAndBranch* instr) { | 5191 void LCodeGen::DoTypeofIsAndBranch(LTypeofIsAndBranch* instr) { |
| 5192 Register input = ToRegister(instr->value()); | 5192 Register input = ToRegister(instr->value()); |
| 5193 | 5193 |
| 5194 Condition final_branch_condition = EmitTypeofIs(instr->TrueLabel(chunk_), | 5194 Condition final_branch_condition = EmitTypeofIs(instr->TrueLabel(chunk_), |
| 5195 instr->FalseLabel(chunk_), | 5195 instr->FalseLabel(chunk_), |
| 5196 input, | 5196 input, |
| (...skipping 331 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5528 __ ldr(result, FieldMemOperand(scratch, | 5528 __ ldr(result, FieldMemOperand(scratch, |
| 5529 FixedArray::kHeaderSize - kPointerSize)); | 5529 FixedArray::kHeaderSize - kPointerSize)); |
| 5530 __ bind(deferred->exit()); | 5530 __ bind(deferred->exit()); |
| 5531 __ bind(&done); | 5531 __ bind(&done); |
| 5532 } | 5532 } |
| 5533 | 5533 |
| 5534 #undef __ | 5534 #undef __ |
| 5535 | 5535 |
| 5536 } // namespace internal | 5536 } // namespace internal |
| 5537 } // namespace v8 | 5537 } // namespace v8 |
| OLD | NEW |