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 | 5 |
6 | 6 |
7 #include "src/v8.h" | 7 #include "src/v8.h" |
8 | 8 |
9 #if V8_TARGET_ARCH_MIPS | 9 #if V8_TARGET_ARCH_MIPS |
10 | 10 |
(...skipping 415 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
426 // Decrease generous allocation count. | 426 // Decrease generous allocation count. |
427 __ Subu(t0, t0, Operand(1 << Map::Counter::kShift)); | 427 __ Subu(t0, t0, Operand(1 << Map::Counter::kShift)); |
428 __ Branch(USE_DELAY_SLOT, &allocate, ne, t2, | 428 __ Branch(USE_DELAY_SLOT, &allocate, ne, t2, |
429 Operand(Map::kSlackTrackingCounterEnd)); | 429 Operand(Map::kSlackTrackingCounterEnd)); |
430 __ sw(t0, bit_field3); // In delay slot. | 430 __ sw(t0, bit_field3); // In delay slot. |
431 | 431 |
432 __ Push(a1, a2, a1); // a1 = Constructor. | 432 __ Push(a1, a2, a1); // a1 = Constructor. |
433 __ CallRuntime(Runtime::kFinalizeInstanceSize, 1); | 433 __ CallRuntime(Runtime::kFinalizeInstanceSize, 1); |
434 | 434 |
435 __ Pop(a1, a2); | 435 __ Pop(a1, a2); |
436 // Slack tracking counter is Map::kSlackTrackingCounterEnd after runtime | 436 __ li(t2, Operand(Map::kSlackTrackingCounterEnd - 1)); |
437 // call. | |
438 __ li(t2, Map::kSlackTrackingCounterEnd); | |
439 | 437 |
440 __ bind(&allocate); | 438 __ bind(&allocate); |
441 } | 439 } |
442 | 440 |
443 // Now allocate the JSObject on the heap. | 441 // Now allocate the JSObject on the heap. |
444 // a1: constructor function | 442 // a1: constructor function |
445 // a2: initial map | 443 // a2: initial map |
446 __ lbu(a3, FieldMemOperand(a2, Map::kInstanceSizeOffset)); | 444 __ lbu(a3, FieldMemOperand(a2, Map::kInstanceSizeOffset)); |
447 if (create_memento) { | 445 if (create_memento) { |
448 __ Addu(a3, a3, Operand(AllocationMemento::kSize / kPointerSize)); | 446 __ Addu(a3, a3, Operand(AllocationMemento::kSize / kPointerSize)); |
(...skipping 1360 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1809 __ break_(0xCC); | 1807 __ break_(0xCC); |
1810 } | 1808 } |
1811 } | 1809 } |
1812 | 1810 |
1813 | 1811 |
1814 #undef __ | 1812 #undef __ |
1815 | 1813 |
1816 } } // namespace v8::internal | 1814 } } // namespace v8::internal |
1817 | 1815 |
1818 #endif // V8_TARGET_ARCH_MIPS | 1816 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |