Index: src/arm/debug-arm.cc |
=================================================================== |
--- src/arm/debug-arm.cc (revision 4189) |
+++ src/arm/debug-arm.cc (working copy) |
@@ -46,13 +46,23 @@ |
// add sp, sp, #4 |
// bx lr |
// to a call to the debug break return code. |
+ // #if USE_BLX |
+ // ldr ip, [pc, #0] |
+ // blx ip |
+ // #else |
// mov lr, pc |
// ldr pc, [pc, #-4] |
+ // #endif |
// <debug break return code entry point address> |
// bktp 0 |
CodePatcher patcher(rinfo()->pc(), 4); |
+#ifdef USE_BLX |
+ patcher.masm()->ldr(v8::internal::ip, MemOperand(v8::internal::pc, 0)); |
+ patcher.masm()->blx(v8::internal::ip); |
+#else |
patcher.masm()->mov(v8::internal::lr, v8::internal::pc); |
patcher.masm()->ldr(v8::internal::pc, MemOperand(v8::internal::pc, -4)); |
+#endif |
patcher.Emit(Debug::debug_break_return()->entry()); |
patcher.masm()->bkpt(0); |
} |