Skip to content

Conversation

@schlad
Copy link
Contributor

@schlad schlad commented Dec 16, 2025

test_race() relied on a fixed loop count and implicit CQ draining to
validate EPOLL_WAIT behavior under concurrent wakeups. This lead to
hangs in the VMs with lower number of CPUs. This patch reworks the test,
so it explicitly counts SQEs submitted and CQEs completed. The writer
thread is now driven by an atomic run flag instead of a fixed loop
count, ensuring deterministic shutdown and stable completion accounting.

test_race() relied on a fixed loop count and implicit CQ draining to
validate EPOLL_WAIT behavior under concurrent wakeups. This lead to
hangs in the VMs with lower number of CPUs. This patch reworks the test,
so it explicitly counts SQEs submitted and CQEs completed. The writer
thread is now driven by an atomic run flag instead of a fixed loop
count, ensuring deterministic shutdown and stable completion accounting.

test_race() relied on a fixed loop count and implicit CQ draining to
validate EPOLL_WAIT behavior under concurrent wakeups. This lead to
hangs in the VMs with lower number of CPUs. This patch reworks the test,
so it explicitly counts SQEs submitted and CQEs completed. The writer
thread is now driven by an atomic run flag instead of a fixed loop
count, ensuring deterministic shutdown and stable completion accounting.

Signed-off-by: Sebastian Chlad <sebastian.chlad@suse.com>
Extend test_race() to explicitly validate pairing between submitted
SQEs and completed CQEs. Store user_data values for each submitted
SQE and corresponding CQE and verify that they match after the test
completes.

Signed-off-by: Sebastian Chlad <sebastian.chlad@suse.com>
@axboe axboe merged commit aa05705 into axboe:master Dec 17, 2025
19 checks passed
schlad referenced this pull request in schlad/liburing Dec 17, 2025
On some system under tests, especially smaller VMs, the writer can finish
producing data, but the race subtest keeps waiting for more CQEs, so it
hangs on a final wait with nothing left to deliver.
Break the loop if drained >= expected where expected is LOOPS * NPIPES * 3
as the test writes "foo".

Signed-off-by: Sebastian Chlad <sebastian.chlad@suse.com>
@schlad schlad deleted the epwait_iouring_track_sqe branch December 17, 2025 07:08
schlad added a commit to schlad/kernel-qe that referenced this pull request Dec 17, 2025
The corresponding bug has been resolved in the upstrea: bsc#1251957
axboe/liburing#1507
schlad added a commit to schlad/kernel-qe that referenced this pull request Dec 17, 2025
The corresponding bug has been resolved in the upstrea: bsc#1251957
axboe/liburing#1507
schlad added a commit to schlad/kernel-qe that referenced this pull request Dec 17, 2025
The corresponding bug has been resolved in the upstrea: bsc#1251957
axboe/liburing#1507
schlad added a commit to schlad/kernel-qe that referenced this pull request Dec 17, 2025
The corresponding bug has been resolved in the upstrea: bsc#1251957
axboe/liburing#1507
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants