RFR: 8292591: Experimentally add back barrier-less Java thread transitions
Robbin Ehn
rehn at openjdk.org
Tue Sep 6 13:06:40 UTC 2022
On Mon, 5 Sep 2022 13:36:31 GMT, Martin Doerr <mdoerr at openjdk.org> wrote:
>> Please consider, only implemented on x64/aarch64 linux/windows.
>>
>> On my box calling clock_gettime via JNI goes from 35ns to 28ns when enabled.
>>
>> Passes t1-7 with option forced on, also passes t1-4 as is in this PR.
>
> src/hotspot/os/linux/systemMemoryBarrier_linux.cpp line 36:
>
>> 34: // Syscall defined in kernel 4.3
>> 35: #if !defined(SYS_membarrier)
>> 36: #define SYS_membarrier 324
>
> I'd like to get rid of the platform checks in this generic linux file.
> This number seems to be the only platform specific part:
SYS_gettid just have large ifdef else and then an error.
I guess e.g. ppc always compile on platforms with it defined since it doesn't need to define it.
The solution with a per plattform file as zSyscall does seems to be the nicest way. But IMHO a bit out of scope for this PR.
-------------
PR: https://git.openjdk.org/jdk/pull/10123
More information about the build-dev
mailing list