Manage PID/TID context automatically

If required for analysis, the PID/TID context will be added.