Index: src/arm/macro-assembler-arm.cc |
diff --git a/src/arm/macro-assembler-arm.cc b/src/arm/macro-assembler-arm.cc |
index 158476ecdb241699dcf1a9feecb82929d76bfc64..7f6c60d2af60103b3fa0edf8e0a212ea5415bfb7 100644 |
--- a/src/arm/macro-assembler-arm.cc |
+++ b/src/arm/macro-assembler-arm.cc |
@@ -2222,12 +2222,28 @@ void MacroAssembler::CallApiFunctionAndReturn(ExternalReference function, |
add(r6, r6, Operand(1)); |
str(r6, MemOperand(r7, kLevelOffset)); |
+ if (FLAG_log_timer_events) { |
+ FrameScope frame(this, StackFrame::MANUAL); |
+ PushSafepointRegisters(); |
+ PrepareCallCFunction(0, r0); |
+ CallCFunction(ExternalReference::log_enter_external_function(isolate()), 0); |
+ PopSafepointRegisters(); |
+ } |
+ |
// Native call returns to the DirectCEntry stub which redirects to the |
// return address pushed on stack (could have moved after GC). |
// DirectCEntry stub itself is generated early and never moves. |
DirectCEntryStub stub; |
stub.GenerateCall(this, function); |
+ if (FLAG_log_timer_events) { |
+ FrameScope frame(this, StackFrame::MANUAL); |
+ PushSafepointRegisters(); |
+ PrepareCallCFunction(0, r0); |
+ CallCFunction(ExternalReference::log_leave_external_function(isolate()), 0); |
+ PopSafepointRegisters(); |
+ } |
+ |
Label promote_scheduled_exception; |
Label delete_allocated_handles; |
Label leave_exit_frame; |