mirror of
https://github.com/openjdk/jdk.git
synced 2026-02-17 05:45:05 +00:00
8176513: Poor code quality for ByteBuffers
Relaxes the condition under which MemBarCPUOrder nodes are added around unsafe accesses. Reviewed-by: vlivanov, kvn, jrose
This commit is contained in:
parent
c40d2d5af7
commit
23ef045ab2
@ -2375,7 +2375,7 @@ bool LibraryCallKit::inline_unsafe_access(bool is_store, const BasicType type, c
|
||||
bool need_mem_bar;
|
||||
switch (kind) {
|
||||
case Relaxed:
|
||||
need_mem_bar = mismatched || can_access_non_heap;
|
||||
need_mem_bar = mismatched && !adr_type->isa_aryptr();
|
||||
break;
|
||||
case Opaque:
|
||||
// Opaque uses CPUOrder membars for protection against code movement.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user