Exception and suspend count polling on JNI bridge return.
Change-Id: I0e5597fcbdcdb88100b18d63323e7ba8d27f13fe
diff --git a/src/assembler_arm.h b/src/assembler_arm.h
index 3981f4a..acaf870 100644
--- a/src/assembler_arm.h
+++ b/src/assembler_arm.h
@@ -446,6 +446,7 @@
void StoreStackOffsetToThread(ThreadOffset thr_offs, FrameOffset fr_offs,
ManagedRegister scratch);
+ void StoreStackPointerToThread(ThreadOffset thr_offs);
void Move(ManagedRegister dest, ManagedRegister src);
void Copy(FrameOffset dest, FrameOffset src, ManagedRegister scratch,
@@ -464,12 +465,24 @@
void Call(ManagedRegister base, Offset offset, ManagedRegister scratch);
+ // Generate code to check if Thread::Current()->suspend_count_ is non-zero
+ // and branch to a SuspendSlowPath if it is. The SuspendSlowPath will continue
+ // at the next instruction.
+ void SuspendPoll(ManagedRegister scratch, ManagedRegister return_reg,
+ FrameOffset return_save_location, size_t return_size);
+
+ // Generate code to check if Thread::Current()->exception_ is non-null
+ // and branch to a ExceptionSlowPath if it is.
+ void ExceptionPoll(ManagedRegister scratch);
+
// Emit data (e.g. encoded instruction or immediate) to the
// instruction stream.
void Emit(int32_t value);
void Bind(Label* label);
+ void EmitSlowPaths() { buffer_.EmitSlowPaths(this); }
+
size_t CodeSize() const { return buffer_.Size(); }
void FinalizeInstructions(const MemoryRegion& region) {