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_MIPS64 | 7 #if V8_TARGET_ARCH_MIPS64 |
8 | 8 |
9 #include "src/bootstrapper.h" | 9 #include "src/bootstrapper.h" |
10 #include "src/code-stubs.h" | 10 #include "src/code-stubs.h" |
(...skipping 1450 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1461 DCHECK(HasArgsInRegisters()); | 1461 DCHECK(HasArgsInRegisters()); |
1462 // Patch the (relocated) inlined map check. | 1462 // Patch the (relocated) inlined map check. |
1463 | 1463 |
1464 // The offset was stored in a4 safepoint slot. | 1464 // The offset was stored in a4 safepoint slot. |
1465 // (See LCodeGen::DoDeferredLInstanceOfKnownGlobal). | 1465 // (See LCodeGen::DoDeferredLInstanceOfKnownGlobal). |
1466 __ LoadFromSafepointRegisterSlot(scratch, a4); | 1466 __ LoadFromSafepointRegisterSlot(scratch, a4); |
1467 __ Dsubu(inline_site, ra, scratch); | 1467 __ Dsubu(inline_site, ra, scratch); |
1468 // Get the map location in scratch and patch it. | 1468 // Get the map location in scratch and patch it. |
1469 __ GetRelocatedValue(inline_site, scratch, v1); // v1 used as scratch. | 1469 __ GetRelocatedValue(inline_site, scratch, v1); // v1 used as scratch. |
1470 __ sd(map, FieldMemOperand(scratch, Cell::kValueOffset)); | 1470 __ sd(map, FieldMemOperand(scratch, Cell::kValueOffset)); |
| 1471 |
| 1472 __ mov(t0, map); |
| 1473 // Scratch points at the cell payload. Calculate the start of the object. |
| 1474 __ Dsubu(scratch, scratch, Operand(Cell::kValueOffset - 1)); |
| 1475 __ RecordWriteField(scratch, Cell::kValueOffset, t0, function, |
| 1476 kRAHasNotBeenSaved, kDontSaveFPRegs, |
| 1477 OMIT_REMEMBERED_SET, OMIT_SMI_CHECK); |
1471 } | 1478 } |
1472 | 1479 |
1473 // Register mapping: a3 is object map and a4 is function prototype. | 1480 // Register mapping: a3 is object map and a4 is function prototype. |
1474 // Get prototype of object into a2. | 1481 // Get prototype of object into a2. |
1475 __ ld(scratch, FieldMemOperand(map, Map::kPrototypeOffset)); | 1482 __ ld(scratch, FieldMemOperand(map, Map::kPrototypeOffset)); |
1476 | 1483 |
1477 // We don't need map any more. Use it as a scratch register. | 1484 // We don't need map any more. Use it as a scratch register. |
1478 Register scratch2 = map; | 1485 Register scratch2 = map; |
1479 map = no_reg; | 1486 map = no_reg; |
1480 | 1487 |
(...skipping 4062 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5543 kStackUnwindSpace, kInvalidStackOffset, | 5550 kStackUnwindSpace, kInvalidStackOffset, |
5544 MemOperand(fp, 6 * kPointerSize), NULL); | 5551 MemOperand(fp, 6 * kPointerSize), NULL); |
5545 } | 5552 } |
5546 | 5553 |
5547 | 5554 |
5548 #undef __ | 5555 #undef __ |
5549 | 5556 |
5550 } } // namespace v8::internal | 5557 } } // namespace v8::internal |
5551 | 5558 |
5552 #endif // V8_TARGET_ARCH_MIPS64 | 5559 #endif // V8_TARGET_ARCH_MIPS64 |
OLD | NEW |