Index: runtime/vm/assembler_mips.h |
=================================================================== |
--- runtime/vm/assembler_mips.h (revision 25720) |
+++ runtime/vm/assembler_mips.h (working copy) |
@@ -145,10 +145,11 @@ |
class Assembler : public ValueObject { |
public: |
- Assembler() |
+ explicit Assembler(bool use_far_branches = false) |
: buffer_(), |
object_pool_(GrowableObjectArray::Handle()), |
prologue_offset_(-1), |
+ use_far_branches_(use_far_branches), |
delay_slot_available_(false), |
in_delay_slot_(false), |
comments_() { } |
@@ -169,6 +170,10 @@ |
buffer_.FinalizeInstructions(region); |
} |
+ bool use_far_branches() const { |
+ return FLAG_use_far_branches || use_far_branches_; |
+ } |
+ |
// Set up a stub frame so that the stack traversal code can easily identify |
// a stub frame. |
void EnterStubFrame(bool uses_pp = false); |
@@ -1094,6 +1099,7 @@ |
GrowableObjectArray& object_pool_; // Objects and patchable jump targets. |
int prologue_offset_; |
+ const bool use_far_branches_; |
bool delay_slot_available_; |
bool in_delay_slot_; |
@@ -1194,6 +1200,7 @@ |
func << kCop1FnShift); |
} |
+ int32_t EncodeBranchOffset(int32_t offset, int32_t instr); |
void EmitFarJump(int32_t offset, bool link); |
void EmitFarBranch(Opcode b, Register rs, Register rt, int32_t offset); |