Revision: 12832
Author: [email protected]
Date: Mon Oct 29 09:27:54 2012
Log: Loosen aligned code target requirement on ARM
Fixes crashes when V8 is built as Thumb code.
[email protected]
Review URL: https://codereview.chromium.org/11343014
http://code.google.com/p/v8/source/detail?r=12832
Modified:
/branches/bleeding_edge/src/arm/assembler-arm-inl.h
=======================================
--- /branches/bleeding_edge/src/arm/assembler-arm-inl.h Thu Oct 18 05:21:42
2012
+++ /branches/bleeding_edge/src/arm/assembler-arm-inl.h Mon Oct 29 09:27:54
2012
@@ -86,8 +86,7 @@
void RelocInfo::set_target_address(Address target, WriteBarrierMode mode) {
ASSERT(IsCodeTarget(rmode_) || rmode_ == RUNTIME_ENTRY);
- Assembler::set_target_address_at(pc_, reinterpret_cast<Address>(
- reinterpret_cast<intptr_t>(target) & ~3));
+ Assembler::set_target_address_at(pc_, target);
if (mode == UPDATE_WRITE_BARRIER && host() != NULL &&
IsCodeTarget(rmode_)) {
Object* target_code = Code::GetCodeFromTargetAddress(target);
host()->GetHeap()->incremental_marking()->RecordWriteIntoCode(
@@ -473,14 +472,12 @@
Address Assembler::target_address_at(Address pc) {
- return reinterpret_cast<Address>(
- reinterpret_cast<intptr_t>(target_pointer_at(pc)) & ~3);
+ return target_pointer_at(pc);
}
void Assembler::set_target_address_at(Address pc, Address target) {
- set_target_pointer_at(pc, reinterpret_cast<Address>(
- reinterpret_cast<intptr_t>(target) & ~3));
+ set_target_pointer_at(pc, target);
}
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev