| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 92 Condition cc, | 92 Condition cc, |
| 93 Label* condition_met, | 93 Label* condition_met, |
| 94 Label::Distance condition_met_distance = Label::kFar); | 94 Label::Distance condition_met_distance = Label::kFar); |
| 95 | 95 |
| 96 void InNewSpace(Register object, | 96 void InNewSpace(Register object, |
| 97 Register scratch, | 97 Register scratch, |
| 98 Condition cc, | 98 Condition cc, |
| 99 Label* condition_met, | 99 Label* condition_met, |
| 100 Label::Distance condition_met_distance = Label::kFar); | 100 Label::Distance condition_met_distance = Label::kFar); |
| 101 | 101 |
| 102 // Check if an object has a given incremental marking colour. Also uses ecx! | 102 // Check if an object has a given incremental marking color. Also uses ecx! |
| 103 // The colour bits are found by splitting the address at the bit offset | 103 // The color bits are found by splitting the address at the bit offset |
| 104 // indicated by the mask: bits that are zero in the mask are used for the | 104 // indicated by the mask: bits that are zero in the mask are used for the |
| 105 // address of the bitmap, and bits that are one in the mask are used for the | 105 // address of the bitmap, and bits that are one in the mask are used for the |
| 106 // index of the bit. | 106 // index of the bit. |
| 107 void HasColour(Register object, | 107 void HasColor(Register object, |
| 108 Register scratch0, | 108 Register scratch0, |
| 109 Register scratch1, | 109 Register scratch1, |
| 110 Label* has_colour, | 110 Label* has_color, |
| 111 Label::Distance has_colour_distance, | 111 Label::Distance has_color_distance, |
| 112 int first_bit, | 112 int first_bit, |
| 113 int second_bit); | 113 int second_bit); |
| 114 | 114 |
| 115 void IsBlack(Register object, | 115 void IsBlack(Register object, |
| 116 Register scratch0, | 116 Register scratch0, |
| 117 Register scratch1, | 117 Register scratch1, |
| 118 Label* is_black, | 118 Label* is_black, |
| 119 Label::Distance is_black_distance = Label::kFar); | 119 Label::Distance is_black_distance = Label::kFar); |
| 120 | 120 |
| 121 // Checks the colour of an object. If the object is already grey or black | 121 // Checks the color of an object. If the object is already grey or black |
| 122 // then we just fall through, since it is already live. If it is white and | 122 // then we just fall through, since it is already live. If it is white and |
| 123 // we can determine that it doesn't need to be scanned, then we just mark it | 123 // we can determine that it doesn't need to be scanned, then we just mark it |
| 124 // black and fall through. For the rest we jump to the label so the | 124 // black and fall through. For the rest we jump to the label so the |
| 125 // incremental marker can fix its assumptions. | 125 // incremental marker can fix its assumptions. |
| 126 void EnsureNotWhite(Register object, | 126 void EnsureNotWhite(Register object, |
| 127 Register scratch1, | 127 Register scratch1, |
| 128 Register scratch2, | 128 Register scratch2, |
| 129 Label* object_is_white_and_not_data, | 129 Label* object_is_white_and_not_data, |
| 130 Label::Distance distance); | 130 Label::Distance distance); |
| 131 | 131 |
| (...skipping 649 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 781 // NULL if gc_allowed. Does not perform a GC if !gc_allowed, and | 781 // NULL if gc_allowed. Does not perform a GC if !gc_allowed, and |
| 782 // possibly returns a failure object indicating an allocation failure. | 782 // possibly returns a failure object indicating an allocation failure. |
| 783 MUST_USE_RESULT MaybeObject* PopHandleScopeHelper(Register saved, | 783 MUST_USE_RESULT MaybeObject* PopHandleScopeHelper(Register saved, |
| 784 Register scratch, | 784 Register scratch, |
| 785 bool gc_allowed); | 785 bool gc_allowed); |
| 786 | 786 |
| 787 // Helper for finding the mark bits for an address. Afterwards, the | 787 // Helper for finding the mark bits for an address. Afterwards, the |
| 788 // bitmap register points at the word with the mark bits and the mask | 788 // bitmap register points at the word with the mark bits and the mask |
| 789 // the position of the first bit. Uses ecx as scratch and leaves addr_reg | 789 // the position of the first bit. Uses ecx as scratch and leaves addr_reg |
| 790 // unchanged. | 790 // unchanged. |
| 791 inline void MarkBits(Register addr_reg, | 791 inline void GetMarkBits(Register addr_reg, |
| 792 Register bitmap_reg, | 792 Register bitmap_reg, |
| 793 Register mask_reg); | 793 Register mask_reg); |
| 794 | 794 |
| 795 // Compute memory operands for safepoint stack slots. | 795 // Compute memory operands for safepoint stack slots. |
| 796 Operand SafepointRegisterSlot(Register reg); | 796 Operand SafepointRegisterSlot(Register reg); |
| 797 static int SafepointRegisterStackIndex(int reg_code); | 797 static int SafepointRegisterStackIndex(int reg_code); |
| 798 | 798 |
| 799 // Needs access to SafepointRegisterStackIndex for optimized frame | 799 // Needs access to SafepointRegisterStackIndex for optimized frame |
| 800 // traversal. | 800 // traversal. |
| 801 friend class OptimizedFrame; | 801 friend class OptimizedFrame; |
| 802 }; | 802 }; |
| 803 | 803 |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 872 } \ | 872 } \ |
| 873 masm-> | 873 masm-> |
| 874 #else | 874 #else |
| 875 #define ACCESS_MASM(masm) masm-> | 875 #define ACCESS_MASM(masm) masm-> |
| 876 #endif | 876 #endif |
| 877 | 877 |
| 878 | 878 |
| 879 } } // namespace v8::internal | 879 } } // namespace v8::internal |
| 880 | 880 |
| 881 #endif // V8_IA32_MACRO_ASSEMBLER_IA32_H_ | 881 #endif // V8_IA32_MACRO_ASSEMBLER_IA32_H_ |
| OLD | NEW |