Chromium Code Reviews| Index: src/bootstrapper.cc |
| =================================================================== |
| --- src/bootstrapper.cc (revision 719) |
| +++ src/bootstrapper.cc (working copy) |
| @@ -205,11 +205,20 @@ |
| Code* code = Code::cast(code_[i]); |
| Address pc = code->instruction_start() + pc_[i]; |
| bool is_pc_relative = Bootstrapper::FixupFlagsIsPCRelative::decode(flags); |
| - if (is_pc_relative) { |
| + bool use_code_object = Bootstrapper::FixupFlagsUseCodeObject::decode(flags); |
| + |
| + if (use_code_object) { |
| + if (is_pc_relative) { |
| + Assembler::set_target_address_at( |
| + pc, reinterpret_cast<Address>(f->code())); |
| + } else { |
| + *reinterpret_cast<Object**>(pc) = f->code(); |
| + } |
| + } else { |
| + ASSERT(is_pc_relative); |
|
iposva
2008/11/10 22:38:57
Please add a comment why this assert is necessary.
Feng Qian
2008/11/11 18:36:40
As we discussed, current IA32 and ARM can only hav
|
| Assembler::set_target_address_at(pc, f->code()->instruction_start()); |
| - } else { |
| - *reinterpret_cast<Object**>(pc) = f->code(); |
| } |
| + |
| LOG(StringEvent("resolved", name)); |
| } |
| Clear(); |