Too many futex() calls

2.5k Views Asked by At

We are observing unusual delays in one of our Java apps on a Linux RedHat machine while trying to publish to an external MQ queue (It never happened before). Did a quick health check on the box and the CPU/memory usage seems quite alright. The MQ boxes are quite fine as well. Restarted my Java process, no luck! We grabbed a quick strace snapshot after that and it is full of futex() calls.

Was wondering if somebody could give any clues on why so many locks could be happening (I know it is a very wide open kind of question. Depends on what the app actually does).

But I was hoping to get some more insight into the problem.

1

There are 1 best solutions below

0
On

So did you actually profile it and determined that futex calls are the bottleneck?

Assuming you did, one thing might be that a futex() syscall implies that the mutex is contended; FUTEX = fast user space mutex, uncontended mutexes are handled in user-space without a syscall. That is, you might have a problem with lock contention.