| OLD | NEW |
| 1 | 1 |
| 2 // Copyright (c) 1994-2006 Sun Microsystems Inc. | 2 // Copyright (c) 1994-2006 Sun Microsystems Inc. |
| 3 // All Rights Reserved. | 3 // All Rights Reserved. |
| 4 // | 4 // |
| 5 // Redistribution and use in source and binary forms, with or without | 5 // Redistribution and use in source and binary forms, with or without |
| 6 // modification, are permitted provided that the following conditions are | 6 // modification, are permitted provided that the following conditions are |
| 7 // met: | 7 // met: |
| 8 // | 8 // |
| 9 // - Redistributions of source code must retain the above copyright notice, | 9 // - Redistributions of source code must retain the above copyright notice, |
| 10 // this list of conditions and the following disclaimer. | 10 // this list of conditions and the following disclaimer. |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 131 UNREACHABLE(); | 131 UNREACHABLE(); |
| 132 return NULL; | 132 return NULL; |
| 133 } | 133 } |
| 134 | 134 |
| 135 | 135 |
| 136 int RelocInfo::target_address_size() { | 136 int RelocInfo::target_address_size() { |
| 137 return Assembler::kSpecialTargetSize; | 137 return Assembler::kSpecialTargetSize; |
| 138 } | 138 } |
| 139 | 139 |
| 140 | 140 |
| 141 void RelocInfo::set_target_address(Address target, | |
| 142 WriteBarrierMode write_barrier_mode, | |
| 143 ICacheFlushMode icache_flush_mode) { | |
| 144 DCHECK(IsCodeTarget(rmode_) || IsRuntimeEntry(rmode_)); | |
| 145 Assembler::set_target_address_at(isolate_, pc_, host_, target, | |
| 146 icache_flush_mode); | |
| 147 if (write_barrier_mode == UPDATE_WRITE_BARRIER && | |
| 148 host() != NULL && IsCodeTarget(rmode_)) { | |
| 149 Object* target_code = Code::GetCodeFromTargetAddress(target); | |
| 150 host()->GetHeap()->incremental_marking()->RecordWriteIntoCode( | |
| 151 host(), this, HeapObject::cast(target_code)); | |
| 152 } | |
| 153 } | |
| 154 | |
| 155 Address Assembler::target_address_from_return_address(Address pc) { | 141 Address Assembler::target_address_from_return_address(Address pc) { |
| 156 return pc - kCallTargetAddressOffset; | 142 return pc - kCallTargetAddressOffset; |
| 157 } | 143 } |
| 158 | 144 |
| 159 | 145 |
| 160 void Assembler::set_target_internal_reference_encoded_at(Address pc, | 146 void Assembler::set_target_internal_reference_encoded_at(Address pc, |
| 161 Address target) { | 147 Address target) { |
| 162 Instr instr1 = Assembler::instr_at(pc + 0 * Assembler::kInstrSize); | 148 Instr instr1 = Assembler::instr_at(pc + 0 * Assembler::kInstrSize); |
| 163 Instr instr2 = Assembler::instr_at(pc + 1 * Assembler::kInstrSize); | 149 Instr instr2 = Assembler::instr_at(pc + 1 * Assembler::kInstrSize); |
| 164 DCHECK(Assembler::IsLui(instr1)); | 150 DCHECK(Assembler::IsLui(instr1)); |
| (...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 489 CheckBuffer(); | 475 CheckBuffer(); |
| 490 } | 476 } |
| 491 EmitHelper(x, is_compact_branch); | 477 EmitHelper(x, is_compact_branch); |
| 492 } | 478 } |
| 493 | 479 |
| 494 | 480 |
| 495 } // namespace internal | 481 } // namespace internal |
| 496 } // namespace v8 | 482 } // namespace v8 |
| 497 | 483 |
| 498 #endif // V8_MIPS_ASSEMBLER_MIPS_INL_H_ | 484 #endif // V8_MIPS_ASSEMBLER_MIPS_INL_H_ |
| OLD | NEW |