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 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 // --------------------------------------------------------------------------- | 70 // --------------------------------------------------------------------------- |
71 // GC Support | 71 // GC Support |
72 enum RememberedSetFinalAction { | 72 enum RememberedSetFinalAction { |
73 kReturnAtEnd, | 73 kReturnAtEnd, |
74 kFallThroughAtEnd | 74 kFallThroughAtEnd |
75 }; | 75 }; |
76 | 76 |
77 // Record in the remembered set the fact that we have a pointer to new space | 77 // Record in the remembered set the fact that we have a pointer to new space |
78 // at the address pointed to by the addr register. Only works if addr is not | 78 // at the address pointed to by the addr register. Only works if addr is not |
79 // in new space. | 79 // in new space. |
80 void RememberedSetHelper(Register addr, | 80 void RememberedSetHelper(Register object, // Used for debug code. |
| 81 Register addr, |
81 Register scratch, | 82 Register scratch, |
82 SaveFPRegsMode save_fp, | 83 SaveFPRegsMode save_fp, |
83 RememberedSetFinalAction and_then); | 84 RememberedSetFinalAction and_then); |
84 | 85 |
85 void CheckPageFlag(Register object, | 86 void CheckPageFlag(Register object, |
86 Register scratch, | 87 Register scratch, |
87 int mask, | 88 int mask, |
88 Condition cc, | 89 Condition cc, |
89 Label* condition_met, | 90 Label* condition_met, |
90 Label::Distance condition_met_distance = Label::kFar); | 91 Label::Distance condition_met_distance = Label::kFar); |
91 | 92 |
92 // Check if object is in new space. Jumps if the object is not in new space. | 93 // Check if object is in new space. Jumps if the object is not in new space. |
93 // The register scratch can be object itself, but it will be clobbered. | 94 // The register scratch can be object itself, but scratch will be clobbered. |
94 void JumpIfNotInNewSpace(Register object, | 95 void JumpIfNotInNewSpace(Register object, |
95 Register scratch, | 96 Register scratch, |
96 Label* branch, | 97 Label* branch, |
97 Label::Distance distance = Label::kFar) { | 98 Label::Distance distance = Label::kFar) { |
98 InNewSpace(object, scratch, zero, branch, distance); | 99 InNewSpace(object, scratch, zero, branch, distance); |
99 } | 100 } |
100 | 101 |
101 // Check if object is in new space. Jumps if the object is in new space. | 102 // Check if object is in new space. Jumps if the object is in new space. |
102 // The register scratch can be object itself, but it will be clobbered. | 103 // The register scratch can be object itself, but it will be clobbered. |
103 void JumpIfInNewSpace(Register object, | 104 void JumpIfInNewSpace(Register object, |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
175 void RecordWriteArray( | 176 void RecordWriteArray( |
176 Register array, | 177 Register array, |
177 Register value, | 178 Register value, |
178 Register index, | 179 Register index, |
179 SaveFPRegsMode save_fp, | 180 SaveFPRegsMode save_fp, |
180 RememberedSetAction remembered_set_action = EMIT_REMEMBERED_SET, | 181 RememberedSetAction remembered_set_action = EMIT_REMEMBERED_SET, |
181 SmiCheck smi_check = INLINE_SMI_CHECK); | 182 SmiCheck smi_check = INLINE_SMI_CHECK); |
182 | 183 |
183 // For page containing |object| mark region covering |address| | 184 // For page containing |object| mark region covering |address| |
184 // dirty. |object| is the object being stored into, |value| is the | 185 // dirty. |object| is the object being stored into, |value| is the |
185 // object being stored. All registers are clobbered by the | 186 // object being stored. The address and value registers are clobbered by the |
186 // operation. RecordWrite filters out smis so it does not update the | 187 // operation. RecordWrite filters out smis so it does not update the |
187 // write barrier if the value is a smi. | 188 // write barrier if the value is a smi. |
188 void RecordWrite( | 189 void RecordWrite( |
189 Register object, | 190 Register object, |
190 Register address, | 191 Register address, |
191 Register value, | 192 Register value, |
192 SaveFPRegsMode save_fp, | 193 SaveFPRegsMode save_fp, |
193 RememberedSetAction remembered_set_action = EMIT_REMEMBERED_SET, | 194 RememberedSetAction remembered_set_action = EMIT_REMEMBERED_SET, |
194 SmiCheck smi_check = INLINE_SMI_CHECK); | 195 SmiCheck smi_check = INLINE_SMI_CHECK); |
195 | 196 |
(...skipping 725 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
921 } \ | 922 } \ |
922 masm-> | 923 masm-> |
923 #else | 924 #else |
924 #define ACCESS_MASM(masm) masm-> | 925 #define ACCESS_MASM(masm) masm-> |
925 #endif | 926 #endif |
926 | 927 |
927 | 928 |
928 } } // namespace v8::internal | 929 } } // namespace v8::internal |
929 | 930 |
930 #endif // V8_IA32_MACRO_ASSEMBLER_IA32_H_ | 931 #endif // V8_IA32_MACRO_ASSEMBLER_IA32_H_ |
OLD | NEW |