I know that Yourkit measures the time on the wall for methods like Thread.sleep (), but what about the unsafe.park native method? Bellows are sampling parameters:
walltime = java.io.RandomAccessFile: readBytes (byte [], int, int) walltime = java.io.RandomAccessFile: read () walltime = java.io.RandomAccessFile: write (int) walltime = java.io.RandomAccessFile: writeBytes (byte [], int, int) walltime = java.net.SocketInputStream: socketRead0 (java.io.FileDescriptor, byte [], int, int, int) walltime = java.net.SocketOutputStream: socketWrite0 (java.io.FileDescriptor , byte [], int, int) walltime = java.lang.Thread: sleep (*)
sampling_period_ms = 20
It seemed that unsafe.park () was not using walltime, so it should be CPU time. Based on Yourkit documentation, CPU time is the actual time the processor spent on this method, and not just the time between the input and output of the method.
Yourkit showed that a lot of time is spent on the park () method, but I do not think that the processor spent a lot of time on the park () method. Could you confirm this? Thank.
source
share