Index: src/arm/full-codegen-arm.cc |
diff --git a/src/arm/full-codegen-arm.cc b/src/arm/full-codegen-arm.cc |
index 2a5887a953c8124ae817f6c464dcc4d95392f0b8..a3d85f6295a6479d567ec77ea50dd987ba03834a 100644 |
--- a/src/arm/full-codegen-arm.cc |
+++ b/src/arm/full-codegen-arm.cc |
@@ -4508,6 +4508,28 @@ void FullCodeGenerator::ExitFinallyBlock() { |
} |
+void FullCodeGenerator::SavePendingMessage() { |
+ ASSERT(!result_register().is(r1)); |
+ // Store pending message while executing finally block upon exception. |
+ ExternalReference pending_message_obj = |
+ ExternalReference::address_of_pending_message_obj(isolate()); |
+ __ mov(ip, Operand(pending_message_obj)); |
+ __ ldr(r1, MemOperand(ip)); |
+ __ push(r1); |
+} |
+ |
+ |
+void FullCodeGenerator::RestorePendingMessage() { |
+ ASSERT(!result_register().is(r1)); |
+ // Restore pending message if cleared by executing the finally block. |
+ __ pop(r1); |
+ ExternalReference pending_message_obj = |
+ ExternalReference::address_of_pending_message_obj(isolate()); |
+ __ mov(ip, Operand(pending_message_obj)); |
+ __ str(r1, MemOperand(ip)); |
+} |
+ |
+ |
#undef __ |
#define __ ACCESS_MASM(masm()) |