sandialabs / qthreads

Lightweight locality-aware user-level threading runtime.
https://www.sandia.gov/qthreads/
Other
173 stars 35 forks source link

Race Conditions in Distrib Threadqueue #244

Closed insertinterestingnamehere closed 7 months ago

insertinterestingnamehere commented 8 months ago

The thread sanitizer is flagging various issues in the distrib threadqueue. A few examples:

Non-atomic write: https://github.com/sandialabs/qthreads/blob/a2d1dbadb80a161a4a287c1056348808b022ba04/src/threadqueues/distrib_threadqueues.c#L207 Non-atomic read: https://github.com/sandialabs/qthreads/blob/a2d1dbadb80a161a4a287c1056348808b022ba04/src/threadqueues/distrib_threadqueues.c#L265

Non-atomic read: https://github.com/sandialabs/qthreads/blob/a2d1dbadb80a161a4a287c1056348808b022ba04/src/threadqueues/distrib_threadqueues.c#L216 Non-atomic write: https://github.com/sandialabs/qthreads/blob/a2d1dbadb80a161a4a287c1056348808b022ba04/src/threadqueues/distrib_threadqueues.c#L374

There are several more.