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 #if V8_TARGET_ARCH_MIPS | 7 #if V8_TARGET_ARCH_MIPS |
8 | 8 |
9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
10 #include "src/bootstrapper.h" | 10 #include "src/bootstrapper.h" |
(...skipping 5333 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5344 Operand(PropertyDetails::PropertyCellTypeField::encode( | 5344 Operand(PropertyDetails::PropertyCellTypeField::encode( |
5345 PropertyCellType::kMutable) | | 5345 PropertyCellType::kMutable) | |
5346 PropertyDetails::KindField::encode(kData))); | 5346 PropertyDetails::KindField::encode(kData))); |
5347 __ JumpIfSmi(value_reg, &fast_smi_case); | 5347 __ JumpIfSmi(value_reg, &fast_smi_case); |
5348 __ bind(&fast_heapobject_case); | 5348 __ bind(&fast_heapobject_case); |
5349 __ sw(value_reg, FieldMemOperand(cell_reg, PropertyCell::kValueOffset)); | 5349 __ sw(value_reg, FieldMemOperand(cell_reg, PropertyCell::kValueOffset)); |
5350 __ RecordWriteField(cell_reg, PropertyCell::kValueOffset, value_reg, | 5350 __ RecordWriteField(cell_reg, PropertyCell::kValueOffset, value_reg, |
5351 cell_details_reg, kRAHasNotBeenSaved, kDontSaveFPRegs, | 5351 cell_details_reg, kRAHasNotBeenSaved, kDontSaveFPRegs, |
5352 EMIT_REMEMBERED_SET, OMIT_SMI_CHECK); | 5352 EMIT_REMEMBERED_SET, OMIT_SMI_CHECK); |
5353 // RecordWriteField clobbers the value register, so we need to reload. | 5353 // RecordWriteField clobbers the value register, so we need to reload. |
| 5354 __ Ret(USE_DELAY_SLOT); |
5354 __ lw(value_reg, FieldMemOperand(cell_reg, PropertyCell::kValueOffset)); | 5355 __ lw(value_reg, FieldMemOperand(cell_reg, PropertyCell::kValueOffset)); |
5355 __ Ret(); | |
5356 __ bind(¬_mutable_data); | 5356 __ bind(¬_mutable_data); |
5357 | 5357 |
5358 // Check if PropertyCell value matches the new value (relevant for Constant, | 5358 // Check if PropertyCell value matches the new value (relevant for Constant, |
5359 // ConstantType and Undefined cells). | 5359 // ConstantType and Undefined cells). |
5360 Label not_same_value; | 5360 Label not_same_value; |
5361 __ lw(at, FieldMemOperand(cell_reg, PropertyCell::kValueOffset)); | 5361 __ lw(at, FieldMemOperand(cell_reg, PropertyCell::kValueOffset)); |
5362 __ Branch(¬_same_value, ne, value_reg, Operand(at)); | 5362 __ Branch(¬_same_value, ne, value_reg, Operand(at)); |
5363 if (FLAG_debug_code) { | 5363 if (FLAG_debug_code) { |
5364 Label done; | 5364 Label done; |
5365 // This can only be true for Constant, ConstantType and Undefined cells, | 5365 // This can only be true for Constant, ConstantType and Undefined cells, |
(...skipping 353 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5719 MemOperand(fp, 6 * kPointerSize), NULL); | 5719 MemOperand(fp, 6 * kPointerSize), NULL); |
5720 } | 5720 } |
5721 | 5721 |
5722 | 5722 |
5723 #undef __ | 5723 #undef __ |
5724 | 5724 |
5725 } // namespace internal | 5725 } // namespace internal |
5726 } // namespace v8 | 5726 } // namespace v8 |
5727 | 5727 |
5728 #endif // V8_TARGET_ARCH_MIPS | 5728 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |