memTrace, a framework for lightweight memory tracing