JDK-8222286 : Fix for JDK-8213419 is broken on s390
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 8,11
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • OS: linux
  • CPU: s390x
  • Submitted: 2019-04-10
  • Updated: 2020-12-22
  • Resolved: 2020-09-21
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 11
11.0.10 b01Fixed
Related Reports
Relates :  
Description
On s390, calls to log2_intptr with a size_t are ambiguous, so an explicit cast to uintptr_t is necessary.

diff --git openjdk.orig/jdk/src/hotspot/share/runtime/os.cpp openjdk/jdk/src/hotspot/share/runtime/os.cpp
--- openjdk.orig/src/hotspot/share/runtime/os.cpp
+++ openjdk/src/hotspot/share/runtime/os.cpp
@@ -1368,7 +1368,7 @@
 }
 
 void os::set_memory_serialize_page(address page) {
-  int count = log2_intptr(sizeof(class JavaThread)) - log2_int(64);
+  int count = log2_intptr((uintptr_t) sizeof(class JavaThread)) - log2_int(64);
   _mem_serialize_page = (volatile int32_t *)page;
   // We initialize the serialization page shift count here
   // We assume a cache line size of 64 bytes

Comments
URL: https://hg.openjdk.java.net/jdk-updates/jdk11u/rev/d120ccdbeba1 User: goetz Date: 2020-11-10 16:21:51 +0000
10-11-2020

URL: https://hg.openjdk.java.net/jdk-updates/jdk11u-dev/rev/d120ccdbeba1 User: andrew Date: 2020-09-21 14:05:40 +0000
21-09-2020

Fix Request [11u]: Cast needed to fix build on S/390 (31-bit)
21-09-2020

This is not s390x, it is s390 (31-bit).
07-07-2020

JDK-8213436 removes the problematic function in OpenJDK 12 and later.
11-04-2019