RFR (S): CR 8004318/JEP 171 Fences intrinsics
dl at cs.oswego.edu
Mon Dec 3 15:57:10 PST 2012
On 12/03/12 17:40, Vitaly Davidovich wrote:
> Hi Aleksey,
> Why not have a bit more fine grained methods? OrderAccess in the VM has
> operations matching JMM wording: loadload, storestore, loadstore, storeload.
By convention these days, in sparc-ese,
"loadFence" => LOAD_LOAD|LOAD_STORE
"storeFence" => STORE_STORE|LOAD_STORE
"fullFence" => STORE_LOAD|LOAD_LOAD|STORE_STORE|LOAD_STORE
Which maps exactly to internals in hotspot, and other VMs,
and most processors(*) and to the non-exotic C11/C++11 modes.
So there's nothing else you'd be tempted to support.
(*) except, famously, POWER and pre-ARMV8/ARM64 ARM, which
are always a bit of an adventure to map. Luckily, upcoming
ARMV8 is a breeze though.
More information about the hotspot-compiler-dev