Restore child processes as user time?

I have a Java process that starts a bunch of child processes and alternates between them doing "kill -STOP" and "kill -CONT" (following the suggestion given in Suspend child process created by java )

Now I want to time the process. I am running "time java [...]"

and the resulting "user" time is about half of the "real" time (the "sys" time is negligible).

Regardless of whether child processes are considered "user" or not, it doesn't make sense, because (unless my code is using significantly more CPU than I thought) most of the time my Java code spends is wasted (or, rather, (through a loop wait(10000)

that wakes up every ten seconds to kill -STOP one process and kill -CONT another until one of them returns successfully).

Is there a call overhead kill

(i.e. ten seconds too short interval)? Are children's processes related to user time? If so, what else could explain the discrepancy?

+3
java time kill-process child-process overhead


source to share


No one has answered this question yet

See similar questions:

1
Suspend child process created by java

or similar:

23498
Why is processing a sorted array faster than processing an unsorted array?
6549
Why subtracting these two times (in 1927) gives a strange result?
2568
How to find the current time in Python
1582
What do "real", "custom" and "sys" mean in time output (1)?
1425
Calculate relative time in C #
1039
Get current time and date on Android
910
Convert Unix timestamp to JavaScript
804
How do I get the execution time of a Python program?
612
How to kill a process running on a specific port in Linux?
0
Java process pauses and continues



All Articles
Loading...
X
Show
Funny
Dev
Pics