nowfound

Life & fun · January 20, 2022

Lockless Ringbuffer Built with Go Generics

A single publisher, multi subscriber lockless ring buffer build with the new generics in Go 1.18beta.

Lockless Ringbuffer Built with Go Generics launched on January 20, 2022 with 44 votes, #903 of 2,891 launches that month and more than 75% of that year's launches. The site was still online in September 2026, 4 years on.

In plain words

Lockless Ringbuffer is a Go library that implements a ring buffer data structure supporting one publisher and multiple subscribers without requiring locks. Built using Go 1.18's new generics feature, it enables efficient, lock-free data passing between concurrent goroutines. The library is designed for developers building high-performance concurrent applications in Go who need a thread-safe buffer mechanism without traditional locking overhead.

written from the facts on this page · September 2026

From the sources

Single producer and multi-reader lockless ring buffer in go using generics from the go 1.18.x release. It is significantly faster than channels with the added type safety of generics compared to ring buffers using interfaces. - GavinClarke0/lockless-generic-ring-buffer

Does a similar job

all alternatives →
  • A pure C89 implementation of Go channels, with blocking selects2023 · github.com · ▲271

    A pure C (-std=c89) implementation of Go channels, including blocking and non-blocking selects. - GitHub - rochus-keller/CspChan: A pure C (-std=c89) implementation of Go channels, including blocking and non-blocking selects.

  • go-nbd – A Pure Go NBD Server and Client2023 · github.com · ▲113

    Hey HN! I just released go-nbd, a lightweight Go library for effortlessly creating NBD servers and clients. Its a neat tool for creating custom Linux block devices with arbitrary backends, such as a file, byte slice or what I'm planning to use it for, a tape drive. While there are a few partially abandoned projects like this out there already, this library tries to be as maintainable as possible by only implementing the most recent handshake revision and baseline functionality for both the client and the server, while still having enough support to be useful. I'd love to get your feedback :)

  • A LRU cache using go generics2022 · github.com · ▲57

    LRU cache using go generics. Contribute to dboslee/lru development by creating an account on GitHub.

  • go-zero2022 · github.com · ▲69

    A web & rpc framework written in Go

  • A minimal and idiomatic WebSocket library for Go2019 · github.com · ▲99

    Minimal and idiomatic WebSocket library for Go. Contribute to coder/websocket development by creating an account on GitHub.

  • Chan – pure C implementation of Go channels2014 · github.com · ▲150

    Pure C implementation of Go channels. Contribute to tylertreat/chan development by creating an account on GitHub.

More life & fun this month

the category →

Source: Show HN post ↗

Launched alongside, January 2022

the whole month →
  • LA

    Life & fun · 2022 · looptap.vasanthv.com

  • Fig▲956

    Autocomplete for the Terminal

    Dev tools · 2022 · fig.io

  • The world's best copy. In one place.

    Growth · 2022 · marketingexamples.com

  • History: Last year I had to replace the tire on my bike, and I was surprised how difficult it was to find a suitable new tire. There were a lot of numbers written on the casing, so I googled what they meant. In the end I was successful, but I didn't want to do the same work again for the next bike after I've forgotten the details. So I wrote this website. Technically, the web page is kept very simple, no frameworks, no templates, no website builder. It uses HTML5, CSS and JavaScript, and it privides a responsive layout for mobile usage. I'm happy to receive feedback. If you have tried the…

    Life & fun · 2022 · fahrrad-tools.de

  • The ultimate MVP cheat sheet with 60+ startup formulas

    Dev tools · 2022 · mvprecipes.com

  • hagrid▲595

    No-code user-generated FAQ, for any webpage

    Dev tools · 2022 · magicstudio.com