about summary refs log tree commit diff stats
path: root/026call.cc
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2017-05-29 00:02:59 -0700
committerKartik K. Agaram <vc@akkartik.com>2017-05-29 00:02:59 -0700
commitf1c8df7dd054fbf0f9cd011d08e031dece74fbe2 (patch)
treedca8c4d3fb8d908a6bd7bfbc522b3f0d9c88f1d8 /026call.cc
parentb2f699e14f02ba503c7a70afc3e9b749ac61f3d7 (diff)
downloadmu-f1c8df7dd054fbf0f9cd011d08e031dece74fbe2.tar.gz
3889 - profile refcount updates by recipe
We're currently spending 50% of our time in `mu edit` performing refcount
updates.
Diffstat (limited to '026call.cc')
-rw-r--r--026call.cc7
1 files changed, 4 insertions, 3 deletions
diff --git a/026call.cc b/026call.cc
index 15e44d35..e813004d 100644
--- a/026call.cc
+++ b/026call.cc
@@ -119,12 +119,13 @@ default: {
       trace(9999, "trace") << "incrementing callstack depth to " << Trace_stream->callstack_depth << end();
       assert(Trace_stream->callstack_depth < 9000);  // 9998-101 plus cushion
     }
-    const instruction& call_instruction = current_instruction();
-    Current_routine->calls.push_front(call(current_instruction().operation));
-    finish_call_housekeeping(call_instruction, ingredients);
+    const call& caller_frame = current_call();
+    Current_routine->calls.push_front(call(to_instruction(caller_frame).operation));
+    finish_call_housekeeping(to_instruction(caller_frame), ingredients);
     // not done with caller
     write_products = false;
     fall_through_to_next_instruction = false;
+    // End Non-primitive Call(caller_frame)
   }
 }
 :(code)