小编Jav*_*Cur的帖子

Java Memory Model: a JLS statement about sequential consistency seems incorrect

I'm reading Chapter 17. Threads and Locks of JLS and the following statement about sequential consistency in Java seems incorrect to me:

If a program has no data races, then all executions of the program will appear to be sequentially consistent.

They define a data race as:

When a program contains two conflicting accesses (§17.4.1) that are not ordered by a happens-before relationship, it is said to contain a data race.

They define conflicted accesses as:

Two accesses to (reads …

java java-memory-model jls

8
推荐指数
1
解决办法
202
查看次数

标签 统计

java ×1

java-memory-model ×1

jls ×1