diff --git a/runtime.c b/runtime.c index b8d30ed6..5f577812 100644 --- a/runtime.c +++ b/runtime.c @@ -80,7 +80,7 @@ void Cyc_st_init() { } void Cyc_st_add(char *frame) { - /* add to circ buf */ + // TODO: do not add if (idx - 1) == frame, since that causes recursion to remove older frames Cyc_Stack_Traces[Cyc_Stack_Trace_Idx] = frame; Cyc_Stack_Trace_Idx = (Cyc_Stack_Trace_Idx + 1) % MAX_STACK_TRACES; }