I'm profiling Java (OpenJDK Runtime Environment (build 1.8.0_191-8u191-b12-0ubuntu0.18.04.1-b12)) application that mostly consists of I/O file to socket. The data is read from a file, gzipped on the fly and send to a socket.
I did some cpu-cycles sampling with perf and got the following picture:
The thing I noticed was sys_futex consumes most of the CPU (percisely _raw_spin_unlock_irqrestore - 11.44%) and the so called _ZN12GCTaskThread3runEnv symbol which I guessed from its name is related to GC.
QUESTIONS:
How to find out what this symbol
_ZN12GCTaskThread3runEnvis responsible for?Why is the
futexes (futex_wait,futex_wake) are the most cpu-time consuming? I expected that sort ofcopy_user_enhanced_fast_stringdue to highI/Oactivity would be on top, but it takes only0.56%in the samples shown.
AFAIK _raw_spin_unlock_irqstore stands for waiting on I/O event, but why does it comsume more CPU than the I/O itself?
