A collection of lock-free data structures written in standard C++11

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

CodeRabbit: AI Code Reviews for Developers
Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.
coderabbit.ai
featured
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com
featured
  1. lockfree

    A collection of lock-free data structures written in standard C++11

    - A lot of code won't work for types with no default constructors, but that is at least compile error

    - Using memcpy[0] for arbitrary types is just wrong, see [1]

    [0] https://github.com/DNedic/lockfree/blob/main/lockfree/inc/bi...

    [1] https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2023/p11...

  2. CodeRabbit

    CodeRabbit: AI Code Reviews for Developers. Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.

    CodeRabbit logo
  3. spsc_queue

    A fast, concurrent, bounded, single producer, single consumer queue

    Should be benchmarked against ->

    https://github.com/Deaod/spsc_queue

    If proven faster OK.. If not.. Well.. back to the drawing board.

  4. tlaplus

    TLC is a model checker for specifications written in TLA+. The TLA+Toolbox is an IDE for TLA+.

    Checking the invariant with assert is also useful in my limited experience with concurrency.

    https://lamport.azurewebsites.net/tla/tla.html

  5. multiversion-concurrency-control

    Discontinued Implementation of multiversion concurrency control, Raft, Left Right concurrency Hashmaps and a multi consumer multi producer Ringbuffer, concurrent and parallel load-balanced loops, parallel actors implementation in Main.java, Actor2.java and a parallel interpreter

    I think I lean towards per-thread sharding instead of mutex based or lock free data structures except for lockfree ringbuffers.

    You can get embarassingly parallel performance if you split your data by thread and aggregate periodically.

    If you need a consistent view of your entire set of data, that is slow path with sharding.

    In my experiments with multithreaded software I simulate a bank where many bankaccounts are randomly withdrawn from and deposited to. https://github.com/samsquire/multiversion-concurrency-contro...

    I get 700 million requests per second due to the sharding of money over accounts.

  6. I think I lean towards per-thread sharding instead of mutex based or lock free data structures except for lockfree ringbuffers.

    You can get embarassingly parallel performance if you split your data by thread and aggregate periodically.

    If you need a consistent view of your entire set of data, that is slow path with sharding.

    In my experiments with multithreaded software I simulate a bank where many bankaccounts are randomly withdrawn from and deposited to. https://github.com/samsquire/multiversion-concurrency-contro...

    I get 700 million requests per second due to the sharding of money over accounts.

  7. glibc

    Discontinued GNU Libc (by lattera)

    The code isn't the easiest to read but in glibc it seems that the syscall is only performed if waiter are detected in userspace during an unlock operation

    https://github.com/lattera/glibc/blob/master/nptl/pthread_mu...

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • Do not die hard with TLA+ pt.1

    1 project | dev.to | 15 Feb 2025
  • Formal Methods: Just Good Engineering Practice?

    5 projects | news.ycombinator.com | 10 Jan 2025
  • Ask HN: Usefulness of formal verification (Coq) and formal verification (TLA+)?

    1 project | news.ycombinator.com | 7 Apr 2024
  • Quint: A specification language based on the temporal logic of actions (TLA)

    5 projects | news.ycombinator.com | 19 Dec 2023
  • Ask HN: How you understand TLA+ and how you use TLA+ in your projects?

    1 project | news.ycombinator.com | 11 Jun 2023

Did you know that Java is
the 8th most popular programming language
based on number of references?