From a1b352dfc68d501a385240cdb7f45a96cf9e3358 Mon Sep 17 00:00:00 2001
From: Lukas Larsson <lukas.larsson@erlang-solutions.com>
Date: Wed, 30 Mar 2016 10:22:28 +0200
Subject: erts: Add comment about future trace optimizations

---
 erts/emulator/beam/erl_trace.c | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/erts/emulator/beam/erl_trace.c b/erts/emulator/beam/erl_trace.c
index 3027e34968..cd3c14e213 100644
--- a/erts/emulator/beam/erl_trace.c
+++ b/erts/emulator/beam/erl_trace.c
@@ -20,6 +20,19 @@
 
 /*
  * Support functions for tracing.
+ *
+ * Ideas for future speed improvements in tracing framework:
+ *  * Move ErtsTracerNif into ErtsTracer
+ *     + Removes need for locking
+ *     + Removes hash lookup overhead
+ *     + Use a refc on the ErtsTracerNif to know when it can
+ *       be freed. We don't want to allocate a separate
+ *       ErtsTracerNif for each module used.
+ *  * Optimize GenericBp for cache locality by reusing equivalent
+ *    GenericBp and GenericBpData in multiple tracer points.
+ *     + Possibly we want to use specialized instructions for different
+ *       types of trace so that the knowledge of which struct is used
+ *       can be in the instruction.
  */
 
 #ifdef HAVE_CONFIG_H
-- 
cgit v1.2.3