How to monitor thread scheduling and the criticality of tasks?