futex Questions
3
Two threads in same process using rwlock object stored in shared memory encounter crash during pthreads stress test. I spent a while trying to find memory corruption or deadlock but nothing so far....
Migraine asked 27/3, 2017 at 2:9
2
Solved
In C++20, we got the capability to sleep on atomic variables, waiting for their value to change.
We do so by using the std::atomic::wait method.
Unfortunately, while wait has been standardized, wai...
2
Solved
You'll have to pardon the rather large-ish block of code, but I believe this is a near-minimal reproduction of my problem. The problem is not isolated to example.com but persists across many other ...
Dispassionate asked 1/2, 2018 at 4:51
0
I am running a dotnet core 2.1 application on the following linux embedded system:
Linux arm 4.14.67-1.0.7+ #52 SMP PREEMPT armv7l GNU/Linux
The application hangs since a couple of days at a fut...
0
I wrote a thread pool with as many threads as I have (spare cores), to avoid context switching. Whenever a new task needs to be executed, that task is added to a lock-free ring buffer for threads o...
2
Currently my application periodically blocked in IO , and the output is very low . I use some command to trace the process.
By using jstack i found that the app is hanging at FileOutputStream.wri...
Alternation asked 28/8, 2015 at 3:35
2
I am investigating Intel CPU atomic features on my Haswell CPU
(a 4/8 core 2.3-3.9ghz i7-4790M), and am finding it really hard
to construct eg. reliable mutex_lock() and mutex_unlock()
operations ...
3
I have a simple Monte-Carlo Pi computation program. I tried running it on 2 different boxes(same hardware with slightly different kernel versions). I am seeing significant performance drop in one c...
Kibe asked 1/11, 2017 at 9:15
2
Solved
Before the futex system calls existed in Linux, what underlying system calls were used by threading libraries like pthreads to block/sleep a thread and to subsequently wake those threads from userl...
Foozle asked 18/8, 2017 at 20:10
1
Solved
A Python process hangs in futex():
root@pc:~# strace -p 9042
strace: Process 9042 attached
futex(0x1e61900, FUTEX_WAIT_BITSET_PRIVATE|FUTEX_CLOCK_REALTIME, 0, NULL, ffffffff
I want to see the st...
1
I'm debugging an issue in a multi-threaded linux process, where a certain thread appears to not execute for few seconds. Looking at strace output revealed it waits for futex e.g.
1673109 14:36:28.6...
Undercoat asked 27/7, 2016 at 22:5
2
Solved
How can unrelated processes cooperate using a futex?
Let's say I have unrelated processes, one being, say, an apache subprocess with my module, another being e.g. a background script.
I'd like to...
Frail asked 8/2, 2016 at 9:7
1
I was reading some documentation and trying out a few samples of code that issue the futex system call in Linux. I read that if a mutex is acquired by thread_a using FUTEX_LOCK_PI, and say if anoth...
Dahle asked 19/10, 2015 at 7:12
1
Solved
So I have a Queue :
q = Queue.Queue()
And I'm putting some items in it.
items = ["First", "Second"]
for val in items:
q.put(val)
And I'm spawning 15 threads.
for i in range(15):
tname = 't...
Mikkimiko asked 7/10, 2015 at 7:37
2
I have a process waiting on a futex:
# strace -p 5538
Process 5538 attached - interrupt to quit
futex(0x7f86c9ed6a0c, FUTEX_WAIT, 20, NULL
How can I best debug such a situation? Can I identify w...
1
We have two Linux process communicate with domain socket, the performance goal is 5k iops with 4k request size through single domain socket connection, in order to reduce cpu cost we replace domain...
Boarer asked 5/1, 2014 at 8:47
1
I have observed that when the linux futexes are contended, the system spends A LOT of time in the spinlocks. I noticed this to be a problem even when futexes are not used directly, but also when ca...
1
Solved
I have been tracing a process with strace and have seen entries such as:
futex(0x7ffff79b3e00, FUTEX_WAKE_PRIVATE, 1) = 1
futex(0x7ffff79b3e00, FUTEX_WAIT_PRIVATE, 2, NULL) = 0
However, when I l...
Trelliswork asked 2/4, 2012 at 21:0
1
I've run into an issue with the Linux futex syscall (FUTEX_WAIT operation) sometimes returning early seemingly without cause. The documentation specifies certain conditions that may cause it to ret...
1
© 2022 - 2024 — McMap. All rights reserved.