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 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
144 DCHECK(IsCodeTarget(rmode_) || IsRuntimeEntry(rmode_)); | 144 DCHECK(IsCodeTarget(rmode_) || IsRuntimeEntry(rmode_)); |
145 Assembler::set_target_address_at(isolate_, pc_, host_, target, | 145 Assembler::set_target_address_at(isolate_, pc_, host_, target, |
146 icache_flush_mode); | 146 icache_flush_mode); |
147 if (write_barrier_mode == UPDATE_WRITE_BARRIER && | 147 if (write_barrier_mode == UPDATE_WRITE_BARRIER && |
148 host() != NULL && IsCodeTarget(rmode_)) { | 148 host() != NULL && IsCodeTarget(rmode_)) { |
149 Object* target_code = Code::GetCodeFromTargetAddress(target); | 149 Object* target_code = Code::GetCodeFromTargetAddress(target); |
150 host()->GetHeap()->incremental_marking()->RecordWriteIntoCode( | 150 host()->GetHeap()->incremental_marking()->RecordWriteIntoCode( |
151 host(), this, HeapObject::cast(target_code)); | 151 host(), this, HeapObject::cast(target_code)); |
152 } | 152 } |
153 } | 153 } |
154 | 154 |
balazs.kilvady
2016/03/09 11:00:20
nits: Please try to follow the order of functions
| |
155 void RelocInfo::update_wasm_memory_reference( | |
156 Address reference, ICacheFlushMode icache_flush_mode) { | |
balazs.kilvady
2016/03/09 11:00:20
The original commit contains the right MIPS/MIPS64
| |
157 DCHECK(IsWasmMemoryReference(rmode_)); | |
158 Assembler::set_target_address_at(isolate_, pc_, host_, reference, | |
159 icache_flush_mode); | |
160 } | |
161 | |
162 Address RelocInfo::wasm_memory_reference() { | |
163 DCHECK(IsWasmMemoryReference(rmode_)); | |
164 return Assembler::target_address_at(pc_, host_); | |
165 } | |
155 | 166 |
156 Address Assembler::target_address_from_return_address(Address pc) { | 167 Address Assembler::target_address_from_return_address(Address pc) { |
157 return pc - kCallTargetAddressOffset; | 168 return pc - kCallTargetAddressOffset; |
158 } | 169 } |
159 | 170 |
160 | 171 |
161 void Assembler::set_target_internal_reference_encoded_at(Address pc, | 172 void Assembler::set_target_internal_reference_encoded_at(Address pc, |
162 Address target) { | 173 Address target) { |
163 Instr instr1 = Assembler::instr_at(pc + 0 * Assembler::kInstrSize); | 174 Instr instr1 = Assembler::instr_at(pc + 0 * Assembler::kInstrSize); |
164 Instr instr2 = Assembler::instr_at(pc + 1 * Assembler::kInstrSize); | 175 Instr instr2 = Assembler::instr_at(pc + 1 * Assembler::kInstrSize); |
(...skipping 314 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
479 CheckBuffer(); | 490 CheckBuffer(); |
480 } | 491 } |
481 EmitHelper(x, is_compact_branch); | 492 EmitHelper(x, is_compact_branch); |
482 } | 493 } |
483 | 494 |
484 | 495 |
485 } // namespace internal | 496 } // namespace internal |
486 } // namespace v8 | 497 } // namespace v8 |
487 | 498 |
488 #endif // V8_MIPS_ASSEMBLER_MIPS_INL_H_ | 499 #endif // V8_MIPS_ASSEMBLER_MIPS_INL_H_ |
OLD | NEW |