| Index: runtime/vm/assembler_mips.cc
|
| diff --git a/runtime/vm/assembler_mips.cc b/runtime/vm/assembler_mips.cc
|
| index 2c195334618d33e7b0ef3cf5de1fa9f1008258ca..254e96069a350ad13ffaebfd0fe347bc6d982a14 100644
|
| --- a/runtime/vm/assembler_mips.cc
|
| +++ b/runtime/vm/assembler_mips.cc
|
| @@ -478,6 +478,28 @@ void Assembler::LoadObject(Register rd, const Object& object) {
|
| }
|
|
|
|
|
| +void Assembler::LoadUniqueObject(Register rd, const Object& object) {
|
| + ASSERT(!in_delay_slot_);
|
| + // Smis and VM heap objects are never relocated; do not use object pool.
|
| + if (object.IsSmi()) {
|
| + LoadImmediate(rd, reinterpret_cast<int32_t>(object.raw()));
|
| + } else if (object.InVMHeap() || !allow_constant_pool()) {
|
| + // Make sure that class CallPattern is able to decode this load immediate.
|
| + int32_t object_raw = reinterpret_cast<int32_t>(object.raw());
|
| + const uint16_t object_low = Utils::Low16Bits(object_raw);
|
| + const uint16_t object_high = Utils::High16Bits(object_raw);
|
| + lui(rd, Immediate(object_high));
|
| + ori(rd, rd, Immediate(object_low));
|
| + } else {
|
| + // Make sure that class CallPattern is able to decode this load from the
|
| + // object pool.
|
| + const int32_t offset =
|
| + ObjectPool::element_offset(object_pool_wrapper_.AddObject(object));
|
| + LoadWordFromPoolOffset(rd, offset - kHeapObjectTag);
|
| + }
|
| +}
|
| +
|
| +
|
| void Assembler::LoadExternalLabel(Register rd,
|
| const ExternalLabel* label,
|
| Patchability patchable) {
|
|
|