Dissemination Barrier Synchronization for Multithreaded Work Stealing
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Current OpenMP synchronization barriers, particularly tree barriers, have a longer critical path and scalability issues as the number of threads grows and memory hierarchies become more complex, limiting efficient multithreaded performance in computing devices.
Innovation Solution
Implementing a non-tree barrier, such as a dissemination barrier, with a logical-OR reduction operation to manage thread synchronization and work stealing, allowing threads to steal tasks and execute them while waiting, thereby improving performance by reducing the critical path and enhancing scalability.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If tree barriers are used for synchronization, then task coordination is achieved, but the critical path becomes longer and scalability deteriorates
Solution Approach 1:
The barrier synchronization is segmented into multiple independent phases: thread arrival tracking, work stealing operations, and barrier exit coordination. Each phase operates independently with its own data structures and synchronization mechanisms, eliminating the single long critical path of traditional tree barriers while maintaining proper coordination.
Solution Approach 2:
The patent transitions from a hierarchical tree structure to a more distributed dimensional approach where threads can operate in parallel across multiple dimensions of the barrier protocol. Threads are organized in a grid-like structure with row and column indices, allowing simultaneous progress along different dimensions rather than sequential traversal of a single tree path.
2Productivity
If the number of threads increases, then parallel processing capability improves, but barrier contention increases and scalability worsens
Solution Approach 1:
The barrier is segmented into multiple independent entry points and tracking mechanisms, one for each thread. Each thread has its own arrival flag and can be tracked independently, allowing linear scaling with thread count without increasing contention on shared resources.
Solution Approach 2:
Threads serve themselves by independently setting their arrival flags and managing their own work stealing operations. The barrier mechanism does not require centralized coordination for each thread arrival, but rather allows threads to self-register and self-manage their synchronization state, reducing contention as thread count increases.
Data Source
Figure 1~2
Figure 3
Figure 4
AI summary
Technologies for multithreaded synchronization and work stealing include a computing device executing two or more threads in a thread team. A thread executes all of the tasks in its task queue and then exchanges its associated task stolen flag value with false and stores that value in a temporary flag. Subsequently, the thread enters a basic synchronization barrier. The computing device performs a logical-OR reduction over the temporary flags of the thread team to produce a reduction value. While waiting for other threads of the thread team to enter the barrier, the thread may steal a task from a victim thread and set the task stolen flag of the victim thread to true. After exiting the basic synchronization barrier, if the reduction value is true, the thread repeats exchanging the task stolen flag value and entering the basic synchronization barrier. Other embodiments are described and claimed.