mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-23 20:44:41 +02:00
7023898: Intrinsify AtomicLongFieldUpdater.getAndIncrement()
Use shorter instruction sequences for atomic add and atomic exchange when possible. Reviewed-by: kvn, jrose
This commit is contained in:
parent
25f18c20d9
commit
302540691b
38 changed files with 880 additions and 124 deletions
|
@ -37,6 +37,10 @@ class Abstract_VM_Version: AllStatic {
|
|||
static const char* _s_internal_vm_info_string;
|
||||
// These are set by machine-dependent initializations
|
||||
static bool _supports_cx8;
|
||||
static bool _supports_atomic_getset4;
|
||||
static bool _supports_atomic_getset8;
|
||||
static bool _supports_atomic_getadd4;
|
||||
static bool _supports_atomic_getadd8;
|
||||
static unsigned int _logical_processors_per_package;
|
||||
static int _vm_major_version;
|
||||
static int _vm_minor_version;
|
||||
|
@ -75,6 +79,13 @@ class Abstract_VM_Version: AllStatic {
|
|||
|
||||
// does HW support an 8-byte compare-exchange operation?
|
||||
static bool supports_cx8() {return _supports_cx8;}
|
||||
// does HW support atomic get-and-set or atomic get-and-add? Used
|
||||
// to guide intrinsification decisions for Unsafe atomic ops
|
||||
static bool supports_atomic_getset4() {return _supports_atomic_getset4;}
|
||||
static bool supports_atomic_getset8() {return _supports_atomic_getset8;}
|
||||
static bool supports_atomic_getadd4() {return _supports_atomic_getadd4;}
|
||||
static bool supports_atomic_getadd8() {return _supports_atomic_getadd8;}
|
||||
|
||||
static unsigned int logical_processors_per_package() {
|
||||
return _logical_processors_per_package;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue