-
Notifications
You must be signed in to change notification settings - Fork 11
Description
Description
Even in situations where the conflict domain is small, RwLock
result in a twofold degradation of performance.
As illustrated in the code below, the number of times a write lock is acquired and the instances where conditions are not met are counted. In the continuous block test, the occurrences of unmet conditions are virtually negligible, indicating a high probability of achieving correct results without employing the write lock. Over ten thousand write locks are applied in total; however, the critical section governed by these locks merely compares the magnitude of two integers, which leads to a halving of performance. This implies that by excising this segment of safety code, the parallel execution time could be reduced to approximately 240 milliseconds.
branch: lock_free_dag