| 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 #if V8_TARGET_ARCH_IA32 | 5 #if V8_TARGET_ARCH_IA32 |
| 6 | 6 |
| 7 #include "src/crankshaft/ia32/lithium-codegen-ia32.h" | 7 #include "src/crankshaft/ia32/lithium-codegen-ia32.h" |
| 8 | 8 |
| 9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
| 10 #include "src/code-factory.h" | 10 #include "src/code-factory.h" |
| (...skipping 2613 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2624 DCHECK(instr->hydrogen()->elements_kind() == FAST_HOLEY_ELEMENTS); | 2624 DCHECK(instr->hydrogen()->elements_kind() == FAST_HOLEY_ELEMENTS); |
| 2625 Label done; | 2625 Label done; |
| 2626 __ cmp(result, factory()->the_hole_value()); | 2626 __ cmp(result, factory()->the_hole_value()); |
| 2627 __ j(not_equal, &done); | 2627 __ j(not_equal, &done); |
| 2628 if (info()->IsStub()) { | 2628 if (info()->IsStub()) { |
| 2629 // A stub can safely convert the hole to undefined only if the array | 2629 // A stub can safely convert the hole to undefined only if the array |
| 2630 // protector cell contains (Smi) Isolate::kArrayProtectorValid. | 2630 // protector cell contains (Smi) Isolate::kArrayProtectorValid. |
| 2631 // Otherwise it needs to bail out. | 2631 // Otherwise it needs to bail out. |
| 2632 __ LoadRoot(result, Heap::kArrayProtectorRootIndex); | 2632 __ LoadRoot(result, Heap::kArrayProtectorRootIndex); |
| 2633 __ cmp(FieldOperand(result, PropertyCell::kValueOffset), | 2633 __ cmp(FieldOperand(result, PropertyCell::kValueOffset), |
| 2634 Immediate(Smi::FromInt(Isolate::kArrayProtectorValid))); | 2634 Immediate(Smi::FromInt(Isolate::kProtectorValid))); |
| 2635 DeoptimizeIf(not_equal, instr, DeoptimizeReason::kHole); | 2635 DeoptimizeIf(not_equal, instr, DeoptimizeReason::kHole); |
| 2636 } | 2636 } |
| 2637 __ mov(result, isolate()->factory()->undefined_value()); | 2637 __ mov(result, isolate()->factory()->undefined_value()); |
| 2638 __ bind(&done); | 2638 __ bind(&done); |
| 2639 } | 2639 } |
| 2640 } | 2640 } |
| 2641 | 2641 |
| 2642 | 2642 |
| 2643 void LCodeGen::DoLoadKeyed(LLoadKeyed* instr) { | 2643 void LCodeGen::DoLoadKeyed(LLoadKeyed* instr) { |
| 2644 if (instr->is_fixed_typed_array()) { | 2644 if (instr->is_fixed_typed_array()) { |
| (...skipping 2505 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5150 __ bind(deferred->exit()); | 5150 __ bind(deferred->exit()); |
| 5151 __ bind(&done); | 5151 __ bind(&done); |
| 5152 } | 5152 } |
| 5153 | 5153 |
| 5154 #undef __ | 5154 #undef __ |
| 5155 | 5155 |
| 5156 } // namespace internal | 5156 } // namespace internal |
| 5157 } // namespace v8 | 5157 } // namespace v8 |
| 5158 | 5158 |
| 5159 #endif // V8_TARGET_ARCH_IA32 | 5159 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |