| OLD | NEW |
| 1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef V8_PPC_MACRO_ASSEMBLER_PPC_H_ | 5 #ifndef V8_PPC_MACRO_ASSEMBLER_PPC_H_ |
| 6 #define V8_PPC_MACRO_ASSEMBLER_PPC_H_ | 6 #define V8_PPC_MACRO_ASSEMBLER_PPC_H_ |
| 7 | 7 |
| 8 #include "src/assembler.h" | 8 #include "src/assembler.h" |
| 9 #include "src/bailout-reason.h" | 9 #include "src/bailout-reason.h" |
| 10 #include "src/frames.h" | 10 #include "src/frames.h" |
| (...skipping 694 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 705 | 705 |
| 706 // FastAllocate is right now only used for folded allocations. It just | 706 // FastAllocate is right now only used for folded allocations. It just |
| 707 // increments the top pointer without checking against limit. This can only | 707 // increments the top pointer without checking against limit. This can only |
| 708 // be done if it was proved earlier that the allocation will succeed. | 708 // be done if it was proved earlier that the allocation will succeed. |
| 709 void FastAllocate(int object_size, Register result, Register scratch1, | 709 void FastAllocate(int object_size, Register result, Register scratch1, |
| 710 Register scratch2, AllocationFlags flags); | 710 Register scratch2, AllocationFlags flags); |
| 711 | 711 |
| 712 void FastAllocate(Register object_size, Register result, Register result_end, | 712 void FastAllocate(Register object_size, Register result, Register result_end, |
| 713 Register scratch, AllocationFlags flags); | 713 Register scratch, AllocationFlags flags); |
| 714 | 714 |
| 715 void AllocateTwoByteString(Register result, Register length, | |
| 716 Register scratch1, Register scratch2, | |
| 717 Register scratch3, Label* gc_required); | |
| 718 void AllocateOneByteString(Register result, Register length, | |
| 719 Register scratch1, Register scratch2, | |
| 720 Register scratch3, Label* gc_required); | |
| 721 void AllocateTwoByteConsString(Register result, Register length, | |
| 722 Register scratch1, Register scratch2, | |
| 723 Label* gc_required); | |
| 724 void AllocateOneByteConsString(Register result, Register length, | |
| 725 Register scratch1, Register scratch2, | |
| 726 Label* gc_required); | |
| 727 void AllocateTwoByteSlicedString(Register result, Register length, | |
| 728 Register scratch1, Register scratch2, | |
| 729 Label* gc_required); | |
| 730 void AllocateOneByteSlicedString(Register result, Register length, | |
| 731 Register scratch1, Register scratch2, | |
| 732 Label* gc_required); | |
| 733 | |
| 734 // Allocates a heap number or jumps to the gc_required label if the young | 715 // Allocates a heap number or jumps to the gc_required label if the young |
| 735 // space is full and a scavenge is needed. All registers are clobbered also | 716 // space is full and a scavenge is needed. All registers are clobbered also |
| 736 // when control continues at the gc_required label. | 717 // when control continues at the gc_required label. |
| 737 void AllocateHeapNumber(Register result, Register scratch1, Register scratch2, | 718 void AllocateHeapNumber(Register result, Register scratch1, Register scratch2, |
| 738 Register heap_number_map, Label* gc_required, | 719 Register heap_number_map, Label* gc_required, |
| 739 MutableMode mode = IMMUTABLE); | 720 MutableMode mode = IMMUTABLE); |
| 740 void AllocateHeapNumberWithValue(Register result, DoubleRegister value, | 721 void AllocateHeapNumberWithValue(Register result, DoubleRegister value, |
| 741 Register scratch1, Register scratch2, | 722 Register scratch1, Register scratch2, |
| 742 Register heap_number_map, | 723 Register heap_number_map, |
| 743 Label* gc_required); | 724 Label* gc_required); |
| (...skipping 653 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1397 Register scratch1, | 1378 Register scratch1, |
| 1398 Register scratch2, | 1379 Register scratch2, |
| 1399 Label* not_flat_one_byte_strings); | 1380 Label* not_flat_one_byte_strings); |
| 1400 | 1381 |
| 1401 // Checks if both instance types are sequential one-byte strings and jumps to | 1382 // Checks if both instance types are sequential one-byte strings and jumps to |
| 1402 // label if either is not. | 1383 // label if either is not. |
| 1403 void JumpIfBothInstanceTypesAreNotSequentialOneByte( | 1384 void JumpIfBothInstanceTypesAreNotSequentialOneByte( |
| 1404 Register first_object_instance_type, Register second_object_instance_type, | 1385 Register first_object_instance_type, Register second_object_instance_type, |
| 1405 Register scratch1, Register scratch2, Label* failure); | 1386 Register scratch1, Register scratch2, Label* failure); |
| 1406 | 1387 |
| 1407 // Check if instance type is sequential one-byte string and jump to label if | |
| 1408 // it is not. | |
| 1409 void JumpIfInstanceTypeIsNotSequentialOneByte(Register type, Register scratch, | |
| 1410 Label* failure); | |
| 1411 | |
| 1412 void JumpIfNotUniqueNameInstanceType(Register reg, Label* not_unique_name); | 1388 void JumpIfNotUniqueNameInstanceType(Register reg, Label* not_unique_name); |
| 1413 | 1389 |
| 1414 void EmitSeqStringSetCharCheck(Register string, Register index, | 1390 void EmitSeqStringSetCharCheck(Register string, Register index, |
| 1415 Register value, uint32_t encoding_mask); | 1391 Register value, uint32_t encoding_mask); |
| 1416 | 1392 |
| 1417 // --------------------------------------------------------------------------- | 1393 // --------------------------------------------------------------------------- |
| 1418 // Patching helpers. | 1394 // Patching helpers. |
| 1419 | 1395 |
| 1420 // Decode offset from constant pool load instruction(s). | 1396 // Decode offset from constant pool load instruction(s). |
| 1421 // Caller must place the instruction word at <location> in <result>. | 1397 // Caller must place the instruction word at <location> in <result>. |
| (...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1602 inline MemOperand NativeContextMemOperand() { | 1578 inline MemOperand NativeContextMemOperand() { |
| 1603 return ContextMemOperand(cp, Context::NATIVE_CONTEXT_INDEX); | 1579 return ContextMemOperand(cp, Context::NATIVE_CONTEXT_INDEX); |
| 1604 } | 1580 } |
| 1605 | 1581 |
| 1606 #define ACCESS_MASM(masm) masm-> | 1582 #define ACCESS_MASM(masm) masm-> |
| 1607 | 1583 |
| 1608 } // namespace internal | 1584 } // namespace internal |
| 1609 } // namespace v8 | 1585 } // namespace v8 |
| 1610 | 1586 |
| 1611 #endif // V8_PPC_MACRO_ASSEMBLER_PPC_H_ | 1587 #endif // V8_PPC_MACRO_ASSEMBLER_PPC_H_ |
| OLD | NEW |