RFR(s): 8235410: Enable handshakes on Linux x86 (32-bit)

David Holmes david.holmes at oracle.com
Thu Dec 5 21:36:09 UTC 2019


Hi Robbin,

Change seems fine.
One query below ....

On 6/12/2019 12:01 am, Robbin Ehn wrote:
> Hi all, please review.
> 
> The flag ThreadLocalHandshakes is going to be obsolete in JDK 14.
> So we change the (unchangeable) default for Linux x86 to on/true.
> 
> There is a follow-up which removes ThreadLocalHandshakes completely.
> If the platform defines THREAD_LOCAL_POLL it will use handshakes.
> When arm32 have implemented local polls, the plan is to remove the 
> global poll
> code paths.
> 
> Last time I checked with some of the affected parties there was no 
> objections.
> 
> Built and sanity test.
> 
> Issue:
> https://bugs.openjdk.java.net/browse/JDK-8235410
> 
> Code below.
> 
> Thanks, Robbin
> 
> diff -r 636d71e53732 src/hotspot/cpu/x86/globals_x86.hpp
> --- a/src/hotspot/cpu/x86/globals_x86.hpp    Wed Dec 04 10:26:32 2019 +0100
> +++ b/src/hotspot/cpu/x86/globals_x86.hpp    Thu Dec 05 14:13:57 2019 +0100
> @@ -89,12 +89,7 @@
> 
>   define_pd_global(intx, InitArrayShortSize, 8*BytesPerLong);
> 
> -#if defined(_LP64) || defined(_WINDOWS)
>   define_pd_global(bool, ThreadLocalHandshakes, true);
> -#else
> -// get_thread() is slow on linux 32 bit, therefore off by default

Why would get_thread be slow on linux 32-bit? Have we discussed this 
when handshakes went in? I'm feeling surprised now to see only 32-bit 
Linux was disabled.

Thanks,
David

> -define_pd_global(bool, ThreadLocalHandshakes, false);
> -#endif
> 
>   #define ARCH_FLAGS(develop, \
>                      product, \


More information about the hotspot-dev mailing list