Tìm hiểu về Memory Barriers (Rào cản bộ nhớ) và quy tắc Happens-Before trong Java. Những khái niệm quan trọng giúp viết code đa luồng an toàn và hiệu quả.

#Java #Programming #Concurrency #MemoryModel #Development #LậpTrình #ĐaLuồng #PhátTriển

https://www.reddit.com/r/programming/comments/1q161ds/explaining_memory_barriers_and_javas_happens/

He’ll explain what Rust’s ordering rules (`Relaxed`, `Acquire`, `SeqCst`, etc.) actually mean, and how they show up in the concurrency crates you use every day.

➡️ https://eurorust.eu/talks/rusts-memory-model/?utm_source=mastodon&utm_medium=social&utm_campaign=25-07-02-speaker-martin-ombura

#RustLang #Concurrency #MemoryModel

🧵 2/3

EuroRust 2025 – October 9 & 10, Paris & online

EuroRust is a 2 day conference for the European Rust community – October 9 & 10, 2025 – in Paris & online

EuroRust

I rather got a chuckle out of this #LWN article, which can sort of be summarized as "CPU architectures involving time-travel result in undefined behaviour".

https://lwn.net/Articles/993484/

#TimeTravel #MemoryModel #C #programming #C++ #UndefinedBehaviour

#ThemeOneProgram#JetsAndSharks 3
https://inquiryintoinquiry.com/2022/09/03/theme-one-program-jets-and-sharks-3/

Given a representation of the Jets & Sharks universe in computer memory, we naturally want to see if the memory serves to supply the facts a well-constructed #DataBase should.

In their #PDPHandbook presentation of the Jets & Sharks example, #McClelland & #Rumelhart give several exercises for exploring the use of their #NeuralPool #MemoryModel on tasks of #Retrieval & #Generalization.

Exercise 2.1
https://web.stanford.edu/group/pdplab/pdphandbook/handbookch3#x7-330001

#Logic

Theme One Program • Jets and Sharks 3

Inquiry Into Inquiry
research!rsc: Updating the Go Memory Model (Memory Models, Part 3)

The next part is equally insightful and even contains surprises:

"Programming Language Memory Models", Russ Cox (https://research.swtch.com/plmm).

On HN: https://news.ycombinator.com/item?id=27750610

#Programming #MemoryModel #Concurrency #Go #C #CPlusPlus #Rust #Swift #Java #LLVM #Atomics #Fences #Memory

research!rsc: Programming Language Memory Models (Memory Models, Part 2)

👆🏽 is the first part in a series of essays that seek to establish a #MemoryModel for #Go programs, in the pursuit of resolving this long-standing issue:

“Doc: Define How sync/atomic Interacts With Memory Model” (https://github.com/golang/go/issues/5045).

#GoLang #Programming #Concurrency

doc: define how sync/atomic interacts with memory model · Issue #5045 · golang/go

Neither golang.org/ref/mem nor golang.org/pkg/sync/atomic say anything about what guarantees are made by the atomic operations wrt the memory model. They should be as weak as possible, of course, b...

Wonderfully-accessible introduction 👌🏽 to the #HardwareMemoryModel in a modern #CPU that most programmers either gloss over or remain unaware of:

“Hardware Memory Models”, Russ Cox (https://research.swtch.com/hwmm).

On HN: https://news.ycombinator.com/item?id=27684703

#Programming #MemoryModel #Concurrency

research!rsc: Hardware Memory Models (Memory Models, Part 1)

Interesting, but not what I had in mind for a #MemoryModel:

“The Memory Models That Underlie Programming Languages” [2016], Kragen Javier Sitaker (http://canonical.org/~kragen/memory-models/).

Via HN: https://news.ycombinator.com/item?id=27455509

#Programming #ComputerHistory #PLDI #Memory #ProgrammingLanguage

The memory models that underlie programming languages

There are about six major conceptualizations of memory, which I’m calling “memory models”, that dominate today’s programming.