Index: src/mips/assembler-mips.cc |
diff --git a/src/mips/assembler-mips.cc b/src/mips/assembler-mips.cc |
index 7e0be710aa43dc3651fdbe923d6182f7d49a5e5f..621a20a43974b06d249bc6519fa2069998811882 100644 |
--- a/src/mips/assembler-mips.cc |
+++ b/src/mips/assembler-mips.cc |
@@ -2166,7 +2166,9 @@ void Assembler::QuietNaN(HeapObject* object) { |
// There is an optimization below, which emits a nop when the address |
// fits in just 16 bits. This is unlikely to help, and should be benchmarked, |
// and possibly removed. |
-void Assembler::set_target_address_at(Address pc, Address target) { |
+void Assembler::set_target_address_at(Address pc, |
+ Address target, |
+ ICacheFlushMode icache_flush_mode) { |
Instr instr2 = instr_at(pc + kInstrSize); |
uint32_t rt_code = GetRtField(instr2); |
uint32_t* p = reinterpret_cast<uint32_t*>(pc); |
@@ -2260,7 +2262,9 @@ void Assembler::set_target_address_at(Address pc, Address target) { |
patched_jump = true; |
} |
- CPU::FlushICache(pc, (patched_jump ? 3 : 2) * sizeof(int32_t)); |
+ if (icache_flush_mode != SKIP_ICACHE_FLUSH) { |
+ CPU::FlushICache(pc, (patched_jump ? 3 : 2) * sizeof(int32_t)); |
+ } |
} |