Skip to content

Commit c58c34d

Browse files
committed
[patch] Update JDK12 patch to current tip source
1 parent 2195dba commit c58c34d

File tree

1 file changed

+79
-88
lines changed

1 file changed

+79
-88
lines changed

scripts/jdk12.patch

Lines changed: 79 additions & 88 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,7 @@
1-
diff --git a/make/autoconf/flags-other.m4 b/make/autoconf/flags-other.m4
2-
index e10e58930..c72b9390c 100644
3-
--- a/make/autoconf/flags-other.m4
4-
+++ b/make/autoconf/flags-other.m4
5-
@@ -121,6 +121,16 @@ AC_DEFUN([FLAGS_SETUP_ASFLAGS_CPU_DEP],
6-
# Misuse EXTRA_CFLAGS to mimic old behavior
7-
$2JVM_ASFLAGS="$JVM_BASIC_ASFLAGS ${$2EXTRA_CFLAGS}"
8-
9-
+ if test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-ev3; then
10-
+ $2JVM_ASFLAGS="$JVM_BASIC_ASFLAGS -mcpu=arm926ej-s"
11-
+ elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-rpi1; then
12-
+ $2JVM_ASFLAGS="$JVM_BASIC_ASFLAGS -mcpu=arm1176jzf-s"
13-
+ elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-rpi2; then
14-
+ $2JVM_ASFLAGS="$JVM_BASIC_ASFLAGS -mcpu=cortex-a7"
15-
+ elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-rpi3; then
16-
+ $2JVM_ASFLAGS="$JVM_BASIC_ASFLAGS -mcpu=cortex-a53"
17-
+ fi
18-
+
19-
AC_SUBST($2JVM_ASFLAGS)
20-
])
21-
22-
diff --git a/make/autoconf/flags.m4 b/make/autoconf/flags.m4
23-
index 472e7a638..45445f23b 100644
24-
--- a/make/autoconf/flags.m4
25-
+++ b/make/autoconf/flags.m4
26-
@@ -34,7 +34,7 @@ m4_include([flags-other.m4])
1+
diff -Naur a/make/autoconf/flags.m4 b/make/autoconf/flags.m4
2+
--- a/make/autoconf/flags.m4 2018-10-27 00:13:12.000000000 +0200
3+
+++ b/make/autoconf/flags.m4 2018-10-27 20:20:42.790765675 +0200
4+
@@ -34,7 +34,7 @@
275
AC_DEFUN([FLAGS_SETUP_ABI_PROFILE],
286
[
297
AC_ARG_WITH(abi-profile, [AS_HELP_STRING([--with-abi-profile],
@@ -32,7 +10,7 @@ index 472e7a638..45445f23b 100644
3210

3311
if test "x$with_abi_profile" != x; then
3412
if test "x$OPENJDK_TARGET_CPU" != xarm && \
35-
@@ -55,6 +55,18 @@ AC_DEFUN([FLAGS_SETUP_ABI_PROFILE],
13+
@@ -55,6 +55,18 @@
3614
elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-sflt; then
3715
ARM_FLOAT_TYPE=sflt
3816
ARM_ARCH_TYPE_FLAGS='-march=armv5t -marm'
@@ -51,11 +29,62 @@ index 472e7a638..45445f23b 100644
5129
elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarmv5-vfp-sflt; then
5230
ARM_FLOAT_TYPE=vfp-sflt
5331
ARM_ARCH_TYPE_FLAGS='-march=armv5t -marm'
54-
diff --git a/make/autoconf/lib-softfloat.m4 b/make/autoconf/lib-softfloat.m4
55-
new file mode 100644
56-
index 000000000..7fa1ed1ac
57-
--- /dev/null
58-
+++ b/make/autoconf/lib-softfloat.m4
32+
diff -Naur a/make/autoconf/flags-other.m4 b/make/autoconf/flags-other.m4
33+
--- a/make/autoconf/flags-other.m4 2018-10-27 00:13:12.000000000 +0200
34+
+++ b/make/autoconf/flags-other.m4 2018-10-27 20:20:42.790765675 +0200
35+
@@ -119,6 +119,16 @@
36+
# Misuse EXTRA_CFLAGS to mimic old behavior
37+
$2JVM_ASFLAGS="$JVM_BASIC_ASFLAGS ${$2EXTRA_CFLAGS}"
38+
39+
+ if test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-ev3; then
40+
+ $2JVM_ASFLAGS="$JVM_BASIC_ASFLAGS -mcpu=arm926ej-s"
41+
+ elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-rpi1; then
42+
+ $2JVM_ASFLAGS="$JVM_BASIC_ASFLAGS -mcpu=arm1176jzf-s"
43+
+ elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-rpi2; then
44+
+ $2JVM_ASFLAGS="$JVM_BASIC_ASFLAGS -mcpu=cortex-a7"
45+
+ elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-rpi3; then
46+
+ $2JVM_ASFLAGS="$JVM_BASIC_ASFLAGS -mcpu=cortex-a53"
47+
+ fi
48+
+
49+
AC_SUBST($2JVM_ASFLAGS)
50+
])
51+
52+
diff -Naur a/make/autoconf/libraries.m4 b/make/autoconf/libraries.m4
53+
--- a/make/autoconf/libraries.m4 2018-10-27 00:13:12.000000000 +0200
54+
+++ b/make/autoconf/libraries.m4 2018-10-27 20:20:42.790765675 +0200
55+
@@ -33,6 +33,7 @@
56+
m4_include([lib-x11.m4])
57+
m4_include([lib-fontconfig.m4])
58+
m4_include([lib-tests.m4])
59+
+m4_include([lib-softfloat.m4])
60+
61+
################################################################################
62+
# Determine which libraries are needed for this configuration
63+
@@ -79,6 +80,13 @@
64+
NEEDS_LIB_ALSA=false
65+
fi
66+
67+
+ if (test "x$OPENJDK_TARGET_CPU" == xarm &&
68+
+ test "x$ARM_FLOAT_TYPE" = xsflt); then
69+
+ NEEDS_LIB_SOFTFLOAT=true
70+
+ else
71+
+ NEEDS_LIB_SOFTFLOAT=false
72+
+ fi
73+
+
74+
# Check if ffi is needed
75+
if HOTSPOT_CHECK_JVM_VARIANT(zero); then
76+
NEEDS_LIB_FFI=true
77+
@@ -98,6 +106,7 @@
78+
LIB_SETUP_FONTCONFIG
79+
LIB_SETUP_FREETYPE
80+
LIB_SETUP_ALSA
81+
+ LIB_SETUP_SOFTFLOAT
82+
LIB_SETUP_LIBFFI
83+
LIB_SETUP_BUNDLED_LIBS
84+
LIB_SETUP_MISC_LIBS
85+
diff -Naur a/make/autoconf/lib-softfloat.m4 b/make/autoconf/lib-softfloat.m4
86+
--- a/make/autoconf/lib-softfloat.m4 1970-01-01 01:00:00.000000000 +0100
87+
+++ b/make/autoconf/lib-softfloat.m4 2018-10-27 20:20:42.790765675 +0200
5988
@@ -0,0 +1,57 @@
6089
+#
6190
+# Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
@@ -114,69 +143,32 @@ index 000000000..7fa1ed1ac
114143
+
115144
+ AC_SUBST(SOFTFLOAT_LIBS)
116145
+])
117-
diff --git a/make/autoconf/libraries.m4 b/make/autoconf/libraries.m4
118-
index ab40c8bd2..fca2f8316 100644
119-
--- a/make/autoconf/libraries.m4
120-
+++ b/make/autoconf/libraries.m4
121-
@@ -33,6 +33,7 @@ m4_include([lib-std.m4])
122-
m4_include([lib-x11.m4])
123-
m4_include([lib-fontconfig.m4])
124-
m4_include([lib-tests.m4])
125-
+m4_include([lib-softfloat.m4])
126-
127-
################################################################################
128-
# Determine which libraries are needed for this configuration
129-
@@ -79,6 +80,13 @@ AC_DEFUN_ONCE([LIB_DETERMINE_DEPENDENCIES],
130-
NEEDS_LIB_ALSA=false
131-
fi
132-
133-
+ if (test "x$OPENJDK_TARGET_CPU" == xarm &&
134-
+ test "x$ARM_FLOAT_TYPE" = xsflt); then
135-
+ NEEDS_LIB_SOFTFLOAT=true
136-
+ else
137-
+ NEEDS_LIB_SOFTFLOAT=false
138-
+ fi
139-
+
140-
# Check if ffi is needed
141-
if HOTSPOT_CHECK_JVM_VARIANT(zero); then
142-
NEEDS_LIB_FFI=true
143-
@@ -98,6 +106,7 @@ AC_DEFUN_ONCE([LIB_SETUP_LIBRARIES],
144-
LIB_SETUP_FONTCONFIG
145-
LIB_SETUP_FREETYPE
146-
LIB_SETUP_ALSA
147-
+ LIB_SETUP_SOFTFLOAT
148-
LIB_SETUP_LIBFFI
149-
LIB_SETUP_BUNDLED_LIBS
150-
LIB_SETUP_MISC_LIBS
151-
diff --git a/make/autoconf/spec.gmk.in b/make/autoconf/spec.gmk.in
152-
index c08bec082..13599e301 100644
153-
--- a/make/autoconf/spec.gmk.in
154-
+++ b/make/autoconf/spec.gmk.in
155-
@@ -345,6 +345,7 @@ FONTCONFIG_CFLAGS:=@FONTCONFIG_CFLAGS@
146+
diff -Naur a/make/autoconf/spec.gmk.in b/make/autoconf/spec.gmk.in
147+
--- a/make/autoconf/spec.gmk.in 2018-10-27 00:13:12.000000000 +0200
148+
+++ b/make/autoconf/spec.gmk.in 2018-10-27 20:20:42.794765749 +0200
149+
@@ -349,6 +349,7 @@
156150
CUPS_CFLAGS:=@CUPS_CFLAGS@
157151
ALSA_LIBS:=@ALSA_LIBS@
158152
ALSA_CFLAGS:=@ALSA_CFLAGS@
159153
+SOFTFLOAT_LIBS:=@SOFTFLOAT_LIBS@
160154
LIBFFI_LIBS:=@LIBFFI_LIBS@
161155
LIBFFI_CFLAGS:=@LIBFFI_CFLAGS@
162156
ENABLE_LIBFFI_BUNDLING:=@ENABLE_LIBFFI_BUNDLING@
163-
diff --git a/make/hotspot/lib/CompileJvm.gmk b/make/hotspot/lib/CompileJvm.gmk
164-
index a4b67f09f..15f8ae62d 100644
165-
--- a/make/hotspot/lib/CompileJvm.gmk
166-
+++ b/make/hotspot/lib/CompileJvm.gmk
167-
@@ -49,6 +49,7 @@ JVM_LDFLAGS += \
157+
diff -Naur a/make/hotspot/lib/CompileJvm.gmk b/make/hotspot/lib/CompileJvm.gmk
158+
--- a/make/hotspot/lib/CompileJvm.gmk 2018-10-27 00:13:12.000000000 +0200
159+
+++ b/make/hotspot/lib/CompileJvm.gmk 2018-10-27 20:20:42.794765749 +0200
160+
@@ -49,6 +49,7 @@
168161

169162
JVM_LIBS += \
170163
$(JVM_LIBS_FEATURES) \
171164
+ $(SOFTFLOAT_LIBS) \
172165
#
173166

174167
# These files and directories are always excluded
175-
diff --git a/src/hotspot/cpu/arm/assembler_arm_32.hpp b/src/hotspot/cpu/arm/assembler_arm_32.hpp
176-
index 53d6d17de..c949c6363 100644
177-
--- a/src/hotspot/cpu/arm/assembler_arm_32.hpp
178-
+++ b/src/hotspot/cpu/arm/assembler_arm_32.hpp
179-
@@ -498,7 +498,7 @@ class Assembler : public AbstractAssembler {
168+
diff -Naur a/src/hotspot/cpu/arm/assembler_arm_32.hpp b/src/hotspot/cpu/arm/assembler_arm_32.hpp
169+
--- a/src/hotspot/cpu/arm/assembler_arm_32.hpp 2018-10-27 00:13:12.000000000 +0200
170+
+++ b/src/hotspot/cpu/arm/assembler_arm_32.hpp 2018-10-27 20:20:42.794765749 +0200
171+
@@ -498,7 +498,7 @@
180172
void dmb(DMB_Opt opt, Register reg) {
181173
if (VM_Version::arm_arch() >= 7) {
182174
emit_int32(0xF57FF050 | opt);
@@ -185,7 +177,7 @@ index 53d6d17de..c949c6363 100644
185177
bool preserve_tmp = (reg == noreg);
186178
if(preserve_tmp) {
187179
reg = Rtemp;
188-
@@ -1239,10 +1239,11 @@ extern int __aeabi_dcmpgt(double, double);
180+
@@ -1242,10 +1242,11 @@
189181

190182
// Imported code from glibc soft-fp bundle for
191183
// calculation accuracy improvement. See CR 6757269.
@@ -199,11 +191,10 @@ index 53d6d17de..c949c6363 100644
199191
};
200192
#endif // __SOFTFP__
201193

202-
diff --git a/src/hotspot/os_cpu/linux_arm/orderAccess_linux_arm.hpp b/src/hotspot/os_cpu/linux_arm/orderAccess_linux_arm.hpp
203-
index 9e6bda265..01a4adebf 100644
204-
--- a/src/hotspot/os_cpu/linux_arm/orderAccess_linux_arm.hpp
205-
+++ b/src/hotspot/os_cpu/linux_arm/orderAccess_linux_arm.hpp
206-
@@ -72,7 +72,7 @@ inline static void dmb_sy() {
194+
diff -Naur a/src/hotspot/os_cpu/linux_arm/orderAccess_linux_arm.hpp b/src/hotspot/os_cpu/linux_arm/orderAccess_linux_arm.hpp
195+
--- a/src/hotspot/os_cpu/linux_arm/orderAccess_linux_arm.hpp 2018-10-27 00:13:12.000000000 +0200
196+
+++ b/src/hotspot/os_cpu/linux_arm/orderAccess_linux_arm.hpp 2018-10-27 20:20:42.794765749 +0200
197+
@@ -67,7 +67,7 @@
207198
__asm__ volatile (
208199
".word 0xF57FF050 | 0xf" : : : "memory");
209200
#endif
@@ -212,7 +203,7 @@ index 9e6bda265..01a4adebf 100644
212203
intptr_t zero = 0;
213204
__asm__ volatile (
214205
"mcr p15, 0, %0, c7, c10, 5"
215-
@@ -96,7 +96,7 @@ inline static void dmb_st() {
206+
@@ -88,7 +88,7 @@
216207
__asm__ volatile (
217208
".word 0xF57FF050 | 0xe" : : : "memory");
218209
#endif

0 commit comments

Comments
 (0)