Project

General

Profile

Actions

Bug #1189

closed

dead loop in rculfhash with urcu-sigal in userspace-rcu-0.10.2

Added by Ying Luo almost 5 years ago. Updated over 4 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Target version:
-
Start date:
07/12/2019
Due date:
% Done:

0%

Estimated time:

Description

->System infomation:
Component: Userspace RCU
Component version: 0.10.2
System information:
x86, 24 CPUS
3.10.0-862.14.1.6_59.x86_64 GNU/Linux

->Step to reproduce issue:
1. install userspace-rcu-0.10.2 package
2. apply attached patch to source code of userspace-rcu-0.10.2
3. cd userspace-rcu-0.10.2/doc/examples/rculfhash/
4. make
5. ./cds_lfht_destroy

>Expected behavior: program of Step5 should end after 200,000 loop
>Actual behavior: program trapped into dead loop, which can be observed by gdb

->There is no such issue in userspace-rcu-0.9.3

->Root Cause:
1. userspace-rcu-0.10.2 use a seperate thread(cds_lfht_workqueue) to handle hash table auto resize, and this thread block all signal at initialization.
2. While in urcu-signal flavor, call_rcu_thread will send SIGRCU signal to all the registed thread to make them do cmm_smp_mb
3. Based on above, call_rcu_thread and workqueue thread will trapped into a dead loop: where call_rcu_thread hold the rcu_registry_lock to waiting all the registed thread to do cmm_smp_mb, while workqueue thread nerver do cmm_smp_mb and waiting to get rcu_registry_lock to unregiter from rcu.


Files

reproduce_bug.patch (3.46 KB) reproduce_bug.patch patch to reproduce issue Ying Luo, 07/12/2019 05:46 AM
Actions

Also available in: Atom PDF