Hi All, Latest versions of some JVMs and libraries started to use release fences in constructors or builders of data structures which are not concurrent by definition.
Below are a couple of examples: 1) Using of release (and sometime store-store) fences in all constructors in GraalVM: https://github.com/oracle/graal/blob/e9dbc9d6d3080daf22dec38ce8c234417e1a8e3c/compiler/src/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/DefaultJavaLoweringProvider.java#L925 2) Using of release fences in constructors or builders of immutable collections in Scala 2.13: https://github.com/scala/scala/search?q=releaseFence%28%29&type=Code The question is: Why all these fences cannot be moved to places which work with concurrency immediately: GCs, static field initializers, concurrent data structures and APIs like futures, actors, etc.? -- You received this message because you are subscribed to the Google Groups "mechanical-sympathy" group. To unsubscribe from this group and stop receiving emails from it, send an email to mechanical-sympathy+unsubscr...@googlegroups.com. To view this discussion on the web, visit https://groups.google.com/d/msgid/mechanical-sympathy/69a49474-f523-490f-bf22-35299f2dab41%40googlegroups.com.