Adds a new drmemtrace feature -exit_after_tracing N which exits the process after tracing N memory references. Extends the -trace_after_instr test to include -exit_after_tracing.
We would prefer -detach_after_tracing but we need i#2644 for that and we leave it for future work.
Fixes #2645 (closed)