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 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
147 } | 147 } |
148 if (write_barrier_mode == UPDATE_WRITE_BARRIER && | 148 if (write_barrier_mode == UPDATE_WRITE_BARRIER && |
149 host() != NULL && | 149 host() != NULL && |
150 target->IsHeapObject()) { | 150 target->IsHeapObject()) { |
151 host()->GetHeap()->incremental_marking()->RecordWrite( | 151 host()->GetHeap()->incremental_marking()->RecordWrite( |
152 host(), &Memory::Object_at(pc_), HeapObject::cast(target)); | 152 host(), &Memory::Object_at(pc_), HeapObject::cast(target)); |
153 } | 153 } |
154 } | 154 } |
155 | 155 |
156 | 156 |
157 Address RelocInfo::target_reference() { | 157 Address RelocInfo::target_external_reference() { |
158 DCHECK(rmode_ == RelocInfo::EXTERNAL_REFERENCE); | 158 DCHECK(rmode_ == RelocInfo::EXTERNAL_REFERENCE); |
159 return Memory::Address_at(pc_); | 159 return Memory::Address_at(pc_); |
160 } | 160 } |
161 | 161 |
162 | 162 |
| 163 Address RelocInfo::target_internal_reference() { |
| 164 DCHECK(rmode_ == INTERNAL_REFERENCE); |
| 165 return Memory::Address_at(pc_); |
| 166 } |
| 167 |
| 168 |
| 169 void RelocInfo::set_target_internal_reference(Address target) { |
| 170 DCHECK(rmode_ == INTERNAL_REFERENCE); |
| 171 Memory::Address_at(pc_) = target; |
| 172 } |
| 173 |
| 174 |
163 Address RelocInfo::target_runtime_entry(Assembler* origin) { | 175 Address RelocInfo::target_runtime_entry(Assembler* origin) { |
164 DCHECK(IsRuntimeEntry(rmode_)); | 176 DCHECK(IsRuntimeEntry(rmode_)); |
165 return reinterpret_cast<Address>(*reinterpret_cast<int32_t*>(pc_)); | 177 return reinterpret_cast<Address>(*reinterpret_cast<int32_t*>(pc_)); |
166 } | 178 } |
167 | 179 |
168 | 180 |
169 void RelocInfo::set_target_runtime_entry(Address target, | 181 void RelocInfo::set_target_runtime_entry(Address target, |
170 WriteBarrierMode write_barrier_mode, | 182 WriteBarrierMode write_barrier_mode, |
171 ICacheFlushMode icache_flush_mode) { | 183 ICacheFlushMode icache_flush_mode) { |
172 DCHECK(IsRuntimeEntry(rmode_)); | 184 DCHECK(IsRuntimeEntry(rmode_)); |
(...skipping 394 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
567 | 579 |
568 | 580 |
569 Operand::Operand(Immediate imm) { | 581 Operand::Operand(Immediate imm) { |
570 // [disp/r] | 582 // [disp/r] |
571 set_modrm(0, ebp); | 583 set_modrm(0, ebp); |
572 set_dispr(imm.x_, imm.rmode_); | 584 set_dispr(imm.x_, imm.rmode_); |
573 } | 585 } |
574 } } // namespace v8::internal | 586 } } // namespace v8::internal |
575 | 587 |
576 #endif // V8_IA32_ASSEMBLER_IA32_INL_H_ | 588 #endif // V8_IA32_ASSEMBLER_IA32_INL_H_ |
OLD | NEW |