Using "-c" and CTRL+C

Dmitry V. Levin ldv at altlinux.org
Mon May 12 12:24:10 UTC 2014


On Fri, May 09, 2014 at 12:42:02PM +0200, Bud Millwood wrote:
> I think I've located my problem - it's a question of choosing the right
> pid. I'm debugging a multi-threaded application, and "ps" doesn't show the
> pid for each thread, whereas htop does. Choosing the pid of a specific
> thread causes strace to give me the statistics I'm looking for.
> 
> So it seems that if I run "strace -c" on a pid that is blocked in a system
> call, it doesn't print statistics at all. It's a little misleading; maybe
> it should print out statistics, and just show that 100% of the time it was
> in that call. Or maybe it can't detect the current call if strace was
> started after the call was made?

strace -c prints statistics for exited syscalls.
If no syscall exited (for the given personality), no statistics is printed.


-- 
ldv
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://lists.strace.io/pipermail/strace-devel/attachments/20140512/67bcfaa9/attachment.bin>


More information about the Strace-devel mailing list