Skip to content

Conversation

@elizarov
Copy link
Contributor

@elizarov elizarov commented Mar 5, 2020

  • The problem was introduced by Simpler and faster lock-free linked list #1565. When doing concurrent add+removeFirst the following can happen:
    • "add" completes, but has not correct prev pointer in next node yet
    • "removeFirst" removes freshly added element
    • "add" performs "finishAdd" that adjust prev pointer of the next node and thus removed element is pointed from the list again
  • A separate LockFreeLinkedListAddRemoveStressTest is added that reproduces this problem.
  • The old LockFreeLinkedListAtomicLFStressTest is refactored a bit.

* The problem was introduced by #1565. When doing concurrent add+removeFirst the following can happen:
  - "add" completes, but has not correct prev pointer in next node yet
  - "removeFirst" removes freshly added element
  - "add" performs "finishAdd" that adjust prev pointer of the next node and thus removed element is pointed from the list again
* A separate LockFreeLinkedListAddRemoveStressTest is added that reproduces this problem.
* The old LockFreeLinkedListAtomicLFStressTest is refactored a bit.
@elizarov elizarov requested a review from qwwdfsad March 5, 2020 15:40
@qwwdfsad qwwdfsad merged commit 7df61ee into develop Mar 6, 2020
@qwwdfsad qwwdfsad deleted the list-add-remove branch March 6, 2020 09:23
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