On Sat, Jun 09, 2007 at 05:19:48PM +1200, Mark Farnell wrote: > I have a parallel program, which calls some message passing functions > which block. Then I attempted to use times() (with struct tms) to > time the program. > No, times only provides the time spent running on the cpu, if you're blocked, then you're not on the cpu. If yo want to find out how much time that is, its roughtly: Time process is blocked = <wall clock time> - (user time + system time) wall clock time = gettimeofday(end) - gettimofday(start); Neil - To unsubscribe from this list: send the line "unsubscribe linux-net" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html