Commit 57fcbc37 authored by kasperl@chromium.org's avatar kasperl@chromium.org

Add I-cache flushing to Code::Relocate. No need to call it

from Heap::CopyCode anymore.


git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@161 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 85a8532a
......@@ -7,3 +7,4 @@ Google Inc.
Rene Rebe <rene@exactcode.de>
Rafal Krypa <rafal@krypa.net>
Jay Freeman <saurik@saurik.com>
......@@ -1530,9 +1530,6 @@ Object* Heap::CreateCode(const CodeDesc& desc,
#ifdef DEBUG
code->Verify();
#endif
CPU::FlushICache(code->instruction_start(), code->instruction_size());
return code;
}
......@@ -1553,9 +1550,6 @@ Object* Heap::CopyCode(Code* code) {
// Relocate the copy.
Code* new_code = Code::cast(result);
new_code->Relocate(new_addr - old_addr);
CPU::FlushICache(new_code->instruction_start(), new_code->instruction_size());
return new_code;
}
......
......@@ -4072,6 +4072,7 @@ void Code::Relocate(int delta) {
for (RelocIterator it(this, RelocInfo::kApplyMask); !it.done(); it.next()) {
it.rinfo()->apply(delta);
}
CPU::FlushICache(instruction_start(), instruction_size());
}
......@@ -4112,6 +4113,7 @@ void Code::CopyFrom(const CodeDesc& desc) {
it.rinfo()->apply(delta);
}
}
CPU::FlushICache(instruction_start(), instruction_size());
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment