Showing results for 
Search instead for 
Did you mean: 

Ways to monitor a heavy application without it crashing.

With reference to this link: is clear that all modules in program will be monitored irrespective whether really needed.
Problem Statement:-
1. My aim is to be able to check for thread stalling in my multi-threaded application. I debugged my way to a potential thread stall case (which took over a month). My expectation from vtune is to be able to find same problem in short period. Thus equipping us with other potential such problems.
2. My application is heavy; has to process packets real time; there are 10 threads running (4 processor CPU), 2 of these threads perform device read and device write respectively. I have kept the input packet rate to minimum, packet content processing is negligible.
3. When I use attach to process method of running vtune analyzer, my application gets killed with setI2C error in driver. The same application executable on running independently runs properly. Introduction of vtune analyzer kills it.
4. I was wondering if it is possible to analyse selected modules alone so as to reduce overhead. But as above link states it is not possible. I have tried unselecting collect spin and signal options, it does not work.
5. Is there any other way in which I will be able to run my application and keep vtune attached to it for sometime atleast?. Wondering if we can use cpu_affinity or some other settings which help to do this.
0 Kudos
2 Replies

If you have heavy program- my opinions are:

1. You can launch this program manually (I'm not sure if your application will spawn other process, and what process should be monitored)

2. Create a new vtune project, select right running process to be profiled (attatch-to-process)

3.Run Concurrency Analysis to know wait-time, spin-timeof each thread, and timelinepane tells youthe threads' "state"(Active or Wait) and transition of two threads.

4. In order toidentify issues on big waits, use LocksAndWaits to know wait-time and wait-count of "objectives", including sync-obj, IO waits, etc.

Regards, Peter

For huge application, especially a service application - using attach-to-process mode is better than launching an application.