Skip to content

Commit 08eb6ea

Browse files
committed
script: rebase jdk15 patches
1 parent 3110033 commit 08eb6ea

File tree

5 files changed

+118
-1
lines changed

5 files changed

+118
-1
lines changed

scripts/config.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -301,7 +301,7 @@ elif [ "$JDKVER" == "loom" ] || [ "$JDKVER" == "tip" ]; then
301301
JAVA_REPO="https://github.com/openjdk/jdk.git"
302302
fi
303303
JAVA_SCM="git"
304-
PATCHVER="jdk14"
304+
PATCHVER="jdk15"
305305
AUTOGEN_STYLE="v2"
306306
if [ "$BUILDER_TYPE" = "native" ]; then
307307
HOSTJDK="$BUILDDIR/jdk-ev3"

scripts/jdk15_bkpt.patch

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
diff --git a/src/hotspot/cpu/arm/globalDefinitions_arm.hpp b/src/hotspot/cpu/arm/globalDefinitions_arm.hpp
2+
index 4aff72af7..0a400d008 100644
3+
--- a/src/hotspot/cpu/arm/globalDefinitions_arm.hpp
4+
+++ b/src/hotspot/cpu/arm/globalDefinitions_arm.hpp
5+
@@ -55,11 +55,4 @@ const bool HaveVFP = true;
6+
#define AD_MD_HPP "adfiles/ad_arm_32.hpp"
7+
#define C1_LIRGENERATOR_MD_HPP "c1_LIRGenerator_arm.hpp"
8+
9+
-#ifdef TARGET_COMPILER_gcc
10+
-#ifdef ARM32
11+
-#undef BREAKPOINT
12+
-#define BREAKPOINT __asm__ volatile ("bkpt")
13+
-#endif
14+
-#endif
15+
-
16+
#endif // CPU_ARM_GLOBALDEFINITIONS_ARM_HPP

scripts/jdk15_cds.patch

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
diff --git a/src/hotspot/share/memory/metaspaceShared.cpp b/src/hotspot/share/memory/metaspaceShared.cpp
2+
index 20d7f53d3..4f6130b62 100644
3+
--- a/src/hotspot/share/memory/metaspaceShared.cpp
4+
+++ b/src/hotspot/share/memory/metaspaceShared.cpp
5+
@@ -1221,7 +1221,7 @@ public:
6+
address obj = ref->obj();
7+
int bytes = ref->size() * BytesPerWord;
8+
char* p;
9+
- size_t alignment = BytesPerWord;
10+
+ size_t alignment = BytesPerLong;
11+
char* oldtop;
12+
char* newtop;
13+
14+
@@ -1239,7 +1239,7 @@ public:
15+
Klass* klass = (Klass*)obj;
16+
if (klass->is_instance_klass()) {
17+
SystemDictionaryShared::validate_before_archiving(InstanceKlass::cast(klass));
18+
- _rw_region.allocate(sizeof(address), BytesPerWord);
19+
+ _rw_region.allocate(sizeof(u8), alignment);
20+
}
21+
}
22+
p = _rw_region.allocate(bytes, alignment);
23+
diff --git a/src/hotspot/share/memory/metaspaceShared.hpp b/src/hotspot/share/memory/metaspaceShared.hpp
24+
index 4a4ee709f..57af38f19 100644
25+
--- a/src/hotspot/share/memory/metaspaceShared.hpp
26+
+++ b/src/hotspot/share/memory/metaspaceShared.hpp
27+
@@ -70,7 +70,7 @@ public:
28+
DumpRegion(const char* name) : _name(name), _base(NULL), _top(NULL), _end(NULL), _is_packed(false) {}
29+
30+
char* expand_top_to(char* newtop);
31+
- char* allocate(size_t num_bytes, size_t alignment=BytesPerWord);
32+
+ char* allocate(size_t num_bytes, size_t alignment=BytesPerLong);
33+
34+
void append_intptr_t(intptr_t n, bool need_to_mark = false);
35+

scripts/jdk15_new.patch

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
diff --git a/make/autoconf/hotspot.m4 b/make/autoconf/hotspot.m4
2+
index 0e4f4c283..647f41158 100644
3+
--- a/make/autoconf/hotspot.m4
4+
+++ b/make/autoconf/hotspot.m4
5+
@@ -172,6 +172,11 @@ AC_DEFUN_ONCE([HOTSPOT_SETUP_MISC],
6+
HOTSPOT_TARGET_CPU_DEFINE="ARM32"
7+
fi
8+
9+
+ if test "x$OPENJDK_BUILD_CPU" = xarm; then
10+
+ HOTSPOT_BUILD_CPU=arm_32
11+
+ HOTSPOT_BUILD_CPU_DEFINE="ARM32"
12+
+ fi
13+
+
14+
# --with-cpu-port is no longer supported
15+
UTIL_DEPRECATED_ARG_WITH(with-cpu-port)
16+
])
17+
diff --git a/src/hotspot/share/memory/metaspaceShared.cpp b/src/hotspot/share/memory/metaspaceShared.cpp
18+
index 5bc8df595..20d7f53d3 100644
19+
--- a/src/hotspot/share/memory/metaspaceShared.cpp
20+
+++ b/src/hotspot/share/memory/metaspaceShared.cpp
21+
@@ -71,6 +71,7 @@
22+
#include "utilities/bitMap.inline.hpp"
23+
#include "utilities/defaultStream.hpp"
24+
#include "utilities/hashtable.inline.hpp"
25+
+#include "gc/shared/softRefPolicy.hpp"
26+
#if INCLUDE_G1GC
27+
#include "gc/g1/g1CollectedHeap.hpp"
28+
#endif
29+
diff --git a/src/hotspot/share/oops/constantPool.cpp b/src/hotspot/share/oops/constantPool.cpp
30+
index b325f9f16..da47aff73 100644
31+
--- a/src/hotspot/share/oops/constantPool.cpp
32+
+++ b/src/hotspot/share/oops/constantPool.cpp
33+
@@ -429,8 +429,12 @@ void ConstantPool::remove_unshareable_info() {
34+
}
35+
36+
int ConstantPool::cp_to_object_index(int cp_index) {
37+
+ Array<u2> *map = reference_map();
38+
+ if (map == 0)
39+
+ return _no_index_sentinel;
40+
+
41+
// this is harder don't do this so much.
42+
- int i = reference_map()->find(cp_index);
43+
+ int i = map->find(cp_index);
44+
// We might not find the index for jsr292 call.
45+
return (i < 0) ? _no_index_sentinel : i;
46+
}

scripts/jdk15_nosflt.patch

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
diff --git a/src/hotspot/cpu/arm/assembler_arm_32.hpp b/src/hotspot/cpu/arm/assembler_arm_32.hpp
2+
index 44997ddcb..5d4b91209 100644
3+
--- a/src/hotspot/cpu/arm/assembler_arm_32.hpp
4+
+++ b/src/hotspot/cpu/arm/assembler_arm_32.hpp
5+
@@ -1252,10 +1252,11 @@ extern int __aeabi_dcmpgt(double, double);
6+
7+
// Imported code from glibc soft-fp bundle for
8+
// calculation accuracy improvement. See CR 6757269.
9+
-extern double __aeabi_fadd_glibc(float, float);
10+
-extern double __aeabi_fsub_glibc(float, float);
11+
-extern double __aeabi_dadd_glibc(double, double);
12+
-extern double __aeabi_dsub_glibc(double, double);
13+
+#define __aeabi_fadd_glibc __aeabi_fadd
14+
+#define __aeabi_fsub_glibc __aeabi_fsub
15+
+#define __aeabi_dadd_glibc __aeabi_dadd
16+
+#define __aeabi_dsub_glibc __aeabi_dsub
17+
+
18+
};
19+
#endif // __SOFTFP__
20+

0 commit comments

Comments
 (0)