OLD | NEW |
1 // Copyright (c) 1994-2006 Sun Microsystems Inc. | 1 // Copyright (c) 1994-2006 Sun Microsystems Inc. |
2 // All Rights Reserved. | 2 // All Rights Reserved. |
3 // | 3 // |
4 // Redistribution and use in source and binary forms, with or without | 4 // Redistribution and use in source and binary forms, with or without |
5 // modification, are permitted provided that the following conditions are | 5 // modification, are permitted provided that the following conditions are |
6 // met: | 6 // met: |
7 // | 7 // |
8 // - Redistributions of source code must retain the above copyright notice, | 8 // - Redistributions of source code must retain the above copyright notice, |
9 // this list of conditions and the following disclaimer. | 9 // this list of conditions and the following disclaimer. |
10 // | 10 // |
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
218 } | 218 } |
219 | 219 |
220 | 220 |
221 template<typename StaticVisitor> | 221 template<typename StaticVisitor> |
222 void RelocInfo::Visit(Heap* heap) { | 222 void RelocInfo::Visit(Heap* heap) { |
223 RelocInfo::Mode mode = rmode(); | 223 RelocInfo::Mode mode = rmode(); |
224 if (mode == RelocInfo::EMBEDDED_OBJECT) { | 224 if (mode == RelocInfo::EMBEDDED_OBJECT) { |
225 StaticVisitor::VisitPointer(heap, target_object_address()); | 225 StaticVisitor::VisitPointer(heap, target_object_address()); |
226 CPU::FlushICache(pc_, sizeof(Address)); | 226 CPU::FlushICache(pc_, sizeof(Address)); |
227 } else if (RelocInfo::IsCodeTarget(mode)) { | 227 } else if (RelocInfo::IsCodeTarget(mode)) { |
228 StaticVisitor::VisitCodeTarget(this); | 228 StaticVisitor::VisitCodeTarget(heap, this); |
229 } else if (mode == RelocInfo::GLOBAL_PROPERTY_CELL) { | 229 } else if (mode == RelocInfo::GLOBAL_PROPERTY_CELL) { |
230 StaticVisitor::VisitGlobalPropertyCell(this); | 230 StaticVisitor::VisitGlobalPropertyCell(heap, this); |
231 } else if (mode == RelocInfo::EXTERNAL_REFERENCE) { | 231 } else if (mode == RelocInfo::EXTERNAL_REFERENCE) { |
232 StaticVisitor::VisitExternalReference(target_reference_address()); | 232 StaticVisitor::VisitExternalReference(target_reference_address()); |
233 CPU::FlushICache(pc_, sizeof(Address)); | 233 CPU::FlushICache(pc_, sizeof(Address)); |
234 #ifdef ENABLE_DEBUGGER_SUPPORT | 234 #ifdef ENABLE_DEBUGGER_SUPPORT |
235 } else if (heap->isolate()->debug()->has_break_points() && | 235 } else if (heap->isolate()->debug()->has_break_points() && |
236 ((RelocInfo::IsJSReturn(mode) && | 236 ((RelocInfo::IsJSReturn(mode) && |
237 IsPatchedReturnSequence()) || | 237 IsPatchedReturnSequence()) || |
238 (RelocInfo::IsDebugBreakSlot(mode) && | 238 (RelocInfo::IsDebugBreakSlot(mode) && |
239 IsPatchedDebugBreakSlotSequence()))) { | 239 IsPatchedDebugBreakSlotSequence()))) { |
240 StaticVisitor::VisitDebugTarget(this); | 240 StaticVisitor::VisitDebugTarget(heap, this); |
241 #endif | 241 #endif |
242 } else if (mode == RelocInfo::RUNTIME_ENTRY) { | 242 } else if (mode == RelocInfo::RUNTIME_ENTRY) { |
243 StaticVisitor::VisitRuntimeEntry(this); | 243 StaticVisitor::VisitRuntimeEntry(this); |
244 } | 244 } |
245 } | 245 } |
246 | 246 |
247 | 247 |
248 | 248 |
249 Immediate::Immediate(int x) { | 249 Immediate::Immediate(int x) { |
250 x_ = x; | 250 x_ = x; |
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
421 | 421 |
422 Operand::Operand(int32_t disp, RelocInfo::Mode rmode) { | 422 Operand::Operand(int32_t disp, RelocInfo::Mode rmode) { |
423 // [disp/r] | 423 // [disp/r] |
424 set_modrm(0, ebp); | 424 set_modrm(0, ebp); |
425 set_dispr(disp, rmode); | 425 set_dispr(disp, rmode); |
426 } | 426 } |
427 | 427 |
428 } } // namespace v8::internal | 428 } } // namespace v8::internal |
429 | 429 |
430 #endif // V8_IA32_ASSEMBLER_IA32_INL_H_ | 430 #endif // V8_IA32_ASSEMBLER_IA32_INL_H_ |
OLD | NEW |