Skip to content

Atomic Instruction Samples #48

Description

@twood02

Lock-free data structures can improve performance compared to traditional locks by using atomic instructions such as compare and swap. For this issue you should write code that demonstrates how to use these instructions to build basic synchronization mechanisms like locks for a multi-threaded program.

You should coordinate with #44 to evaluate the performance of both the regular locks and your lock-free versions.

For example, you could write a program that measures the number of times per second a multi-threaded program can increment a counter, either by using standard mutexes or by using atomic instructions.

Put your code in threads/atomics. Include some documentation to explain how these work and links to relevant reference material.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions