|LTTng and multi-core [message #632645]
||Wed, 13 October 2010 13:20
| Russell Klein
Registered: October 2010
I am trying to find a race condition in my system using LTTng. I am running an application with 42 threads. There is a lot of locking and and memory contention between the threads. It is running on an 8 core system (Freescale P4080). I am running on a Linux 2.6.30 base. I have patched it with LTTng v 0.159 (the latest which works with 2.6.30 - I believe) with version 2.3 trace.|
What I am seeing is that 41 of the 42 threads are reported to be running on one of the CPUs. The CPUID field in the events for the PID for these threads is always the same (note that the threads - pthreads, specifically - seem to be implemented as processes as each thread has a pid associated with it).
However, when I look at the control flow viewer - it appears that at any point in time that up to 8 threads are in the "running" state (shown as bright green) at any one time. This consistent with what I believe should be happening - but conflicts with the CPUID field being reported with the events.
One other thing, at the same time that there are 8 "running" user space threads/processes - there are up to 8 (typically 6) system level processes which are reported (in the control flow view) as "running" (bright blue). While I have 8 PPC cores, they are not hyperthreaded to provide the illusion of 2 or more logical cores per physical core.
Can anyone shed some light on this?
How does LTTng determine the CPUID field? Can this be relied upon?
How does LTTng determine that a process is "running'? Is it possible to have more processes in the "running" state than cores available?
How can I correlate a running process with a specific CPU?
Thanks, Russ Klein
Powered by FUDForum
. Page generated in 0.12022 seconds