| 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 #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/cpu-profiler.h" | 9 #include "src/cpu-profiler.h" |
| 10 #include "src/hydrogen-osr.h" | 10 #include "src/hydrogen-osr.h" |
| (...skipping 2264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2275 __ bind(¬_string); | 2275 __ bind(¬_string); |
| 2276 } | 2276 } |
| 2277 | 2277 |
| 2278 if (expected.Contains(ToBooleanStub::SYMBOL)) { | 2278 if (expected.Contains(ToBooleanStub::SYMBOL)) { |
| 2279 // Symbol value -> true. | 2279 // Symbol value -> true. |
| 2280 const Register scratch = scratch1(); | 2280 const Register scratch = scratch1(); |
| 2281 __ lbu(scratch, FieldMemOperand(map, Map::kInstanceTypeOffset)); | 2281 __ lbu(scratch, FieldMemOperand(map, Map::kInstanceTypeOffset)); |
| 2282 __ Branch(instr->TrueLabel(chunk_), eq, scratch, Operand(SYMBOL_TYPE)); | 2282 __ Branch(instr->TrueLabel(chunk_), eq, scratch, Operand(SYMBOL_TYPE)); |
| 2283 } | 2283 } |
| 2284 | 2284 |
| 2285 if (expected.Contains(ToBooleanStub::SIMD_VALUE)) { | |
| 2286 // Symbol value -> true. | |
| 2287 const Register scratch = scratch1(); | |
| 2288 __ lbu(scratch, FieldMemOperand(map, Map::kInstanceTypeOffset)); | |
| 2289 __ Branch(instr->TrueLabel(chunk_), eq, scratch, | |
| 2290 Operand(FLOAT32X4_TYPE)); | |
| 2291 } | |
| 2292 | |
| 2293 if (expected.Contains(ToBooleanStub::HEAP_NUMBER)) { | 2285 if (expected.Contains(ToBooleanStub::HEAP_NUMBER)) { |
| 2294 // heap number -> false iff +0, -0, or NaN. | 2286 // heap number -> false iff +0, -0, or NaN. |
| 2295 DoubleRegister dbl_scratch = double_scratch0(); | 2287 DoubleRegister dbl_scratch = double_scratch0(); |
| 2296 Label not_heap_number; | 2288 Label not_heap_number; |
| 2297 __ LoadRoot(at, Heap::kHeapNumberMapRootIndex); | 2289 __ LoadRoot(at, Heap::kHeapNumberMapRootIndex); |
| 2298 __ Branch(¬_heap_number, ne, map, Operand(at)); | 2290 __ Branch(¬_heap_number, ne, map, Operand(at)); |
| 2299 __ ldc1(dbl_scratch, FieldMemOperand(reg, HeapNumber::kValueOffset)); | 2291 __ ldc1(dbl_scratch, FieldMemOperand(reg, HeapNumber::kValueOffset)); |
| 2300 __ BranchF(instr->TrueLabel(chunk_), instr->FalseLabel(chunk_), | 2292 __ BranchF(instr->TrueLabel(chunk_), instr->FalseLabel(chunk_), |
| 2301 ne, dbl_scratch, kDoubleRegZero); | 2293 ne, dbl_scratch, kDoubleRegZero); |
| 2302 // Falls through if dbl_scratch == 0. | 2294 // Falls through if dbl_scratch == 0. |
| (...skipping 3916 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6219 __ Push(at, ToRegister(instr->function())); | 6211 __ Push(at, ToRegister(instr->function())); |
| 6220 CallRuntime(Runtime::kPushBlockContext, 2, instr); | 6212 CallRuntime(Runtime::kPushBlockContext, 2, instr); |
| 6221 RecordSafepoint(Safepoint::kNoLazyDeopt); | 6213 RecordSafepoint(Safepoint::kNoLazyDeopt); |
| 6222 } | 6214 } |
| 6223 | 6215 |
| 6224 | 6216 |
| 6225 #undef __ | 6217 #undef __ |
| 6226 | 6218 |
| 6227 } // namespace internal | 6219 } // namespace internal |
| 6228 } // namespace v8 | 6220 } // namespace v8 |
| OLD | NEW |