---
title: "Discussion on \"Seqlock-Based Atomic Memory Snapshots\" | Hashnode"
description: "Discussion on \"Seqlock-Based Atomic Memory Snapshots\". We discuss seqlock-based atomic snapshots as an alternative to the k-word CAS algorithm when writes are infrequent and single-writer limitation is fine."
url: "https://hashnode.com/posts/seqlock-based-atomic-memory-snapshots/64cf7f8a79ecbf244f51df0b"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Seqlock-Based Atomic Memory Snapshots](https://puzpuzpuz.dev/seqlock-based-atomic-memory-snapshots?utm_source=hashnode&utm_medium=feed)

We discuss seqlock-based atomic snapshots as an alternative to the k-word CAS algorithm when writes are infrequent and single-writer limitation is fine.

Aug 6, 2023 · 5 min read · puzpuzpuz.dev  
Updated Jan 7, 2024  
Read the article

-   [#concurrency](https://hashnode.com/tag/concurrency)
-   [#multithreading](https://hashnode.com/tag/multithreading)
-   [#algorithms](https://hashnode.com/tag/algorithms)

## Written by

[Andrei Pechkurov](https://hashnode.com/@puzpuzpuz)

@puzpuzpuz

  
[View profile](https://hashnode.com/@puzpuzpuz)

Top data race and segfault producer in the room.

Core database engineer at QuestDB. Distributed systems gazer. Node.js contributor. Occasional tech blogger and speaker.

## Responses 1

Markdown supported · ⌘↵ to post

[Aleksander Lantsov](https://hashnode.com/@lantalex)

[Jan 6, 2024](https://hashnode.com/posts/seqlock-based-atomic-memory-snapshots/64cf7f8a79ecbf244f51df0b/comment/65994bcc0fe390a9f91a3fd1)

Excellent article, thank you!

Why is the last access to the "version" variable in the reader (right after loadLoadFence) done with acquire semantics (instead of opaque)?

[Andrei Pechkurov](https://hashnode.com/@puzpuzpuz)

[Jan 7, 2024](https://hashnode.com/posts/seqlock-based-atomic-memory-snapshots/64cf7f8a79ecbf244f51df0b/comment/65994bcc0fe390a9f91a3fd1#reply-659a78e05a246ab4fe9092fd)

Thanks for the feedback.

As for the last getAcquire, I think you're right. Considering the prior loadLoadFence, it can be changed to getOpaque.
