Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(810)

Side by Side Diff: src/ia32/assembler-ia32-inl.h

Issue 7639020: Perform TODO(gc) cleanup for TODO-lockdown. (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/gc
Patch Set: Created 9 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 return Assembler::kExternalTargetSize; 87 return Assembler::kExternalTargetSize;
88 } 88 }
89 89
90 90
91 void RelocInfo::set_target_address(Address target, Code* code) { 91 void RelocInfo::set_target_address(Address target, Code* code) {
92 Assembler::set_target_address_at(pc_, target); 92 Assembler::set_target_address_at(pc_, target);
93 ASSERT(IsCodeTarget(rmode_) || rmode_ == RUNTIME_ENTRY); 93 ASSERT(IsCodeTarget(rmode_) || rmode_ == RUNTIME_ENTRY);
94 if (code != NULL && IsCodeTarget(rmode_)) { 94 if (code != NULL && IsCodeTarget(rmode_)) {
95 Object* target_code = Code::GetCodeFromTargetAddress(target); 95 Object* target_code = Code::GetCodeFromTargetAddress(target);
96 96
97 // TODO(gc) We are not compacting code space. 97 // TODO(1550) We are passing NULL as a slot because code can never be on
98 // evacuation candidate.
98 code->GetHeap()->incremental_marking()->RecordWrite( 99 code->GetHeap()->incremental_marking()->RecordWrite(
99 code, NULL, HeapObject::cast(target_code)); 100 code, NULL, HeapObject::cast(target_code));
100 } 101 }
101 } 102 }
102 103
103 104
104 Object* RelocInfo::target_object() { 105 Object* RelocInfo::target_object() {
105 ASSERT(IsCodeTarget(rmode_) || rmode_ == EMBEDDED_OBJECT); 106 ASSERT(IsCodeTarget(rmode_) || rmode_ == EMBEDDED_OBJECT);
106 return Memory::Object_at(pc_); 107 return Memory::Object_at(pc_);
107 } 108 }
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
152 return reinterpret_cast<JSGlobalPropertyCell*>(object); 153 return reinterpret_cast<JSGlobalPropertyCell*>(object);
153 } 154 }
154 155
155 156
156 void RelocInfo::set_target_cell(JSGlobalPropertyCell* cell, Code* code) { 157 void RelocInfo::set_target_cell(JSGlobalPropertyCell* cell, Code* code) {
157 ASSERT(rmode_ == RelocInfo::GLOBAL_PROPERTY_CELL); 158 ASSERT(rmode_ == RelocInfo::GLOBAL_PROPERTY_CELL);
158 Address address = cell->address() + JSGlobalPropertyCell::kValueOffset; 159 Address address = cell->address() + JSGlobalPropertyCell::kValueOffset;
159 Memory::Address_at(pc_) = address; 160 Memory::Address_at(pc_) = address;
160 CPU::FlushICache(pc_, sizeof(Address)); 161 CPU::FlushICache(pc_, sizeof(Address));
161 if (code != NULL) { 162 if (code != NULL) {
162 // TODO(gc) We are not compacting cell space. 163 // TODO(1550) We are passing NULL as a slot because code can never be on
164 // evacuation candidate.
163 code->GetHeap()->incremental_marking()->RecordWrite( 165 code->GetHeap()->incremental_marking()->RecordWrite(
164 code, NULL, cell); 166 code, NULL, cell);
165 } 167 }
166 } 168 }
167 169
168 170
169 Address RelocInfo::call_address() { 171 Address RelocInfo::call_address() {
170 ASSERT((IsJSReturn(rmode()) && IsPatchedReturnSequence()) || 172 ASSERT((IsJSReturn(rmode()) && IsPatchedReturnSequence()) ||
171 (IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence())); 173 (IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence()));
172 return Assembler::target_address_at(pc_ + 1); 174 return Assembler::target_address_at(pc_ + 1);
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after
453 455
454 Operand::Operand(int32_t disp, RelocInfo::Mode rmode) { 456 Operand::Operand(int32_t disp, RelocInfo::Mode rmode) {
455 // [disp/r] 457 // [disp/r]
456 set_modrm(0, ebp); 458 set_modrm(0, ebp);
457 set_dispr(disp, rmode); 459 set_dispr(disp, rmode);
458 } 460 }
459 461
460 } } // namespace v8::internal 462 } } // namespace v8::internal
461 463
462 #endif // V8_IA32_ASSEMBLER_IA32_INL_H_ 464 #endif // V8_IA32_ASSEMBLER_IA32_INL_H_
OLDNEW
« no previous file with comments | « src/heap-inl.h ('k') | src/ia32/code-stubs-ia32.cc » ('j') | src/mark-compact.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698