Skip to content

Commit e742126

Browse files
committed
Add new configure option --with-mixedrefs for mixed pointer mode
If `--with-mixedrefs` is specified in the confirgure command, the 'default' `OPENJ9_LIBS_SUBDIR` is used for the build. The mxdptrs CMake file corresponding to the build OS is used as the `OPENJ9_BUILDSPEC`. The new mxdpts build specs are defined in OpenJ9. The compressed and full GC libraries generated with the mixed build work are copied to the `OPENJ9_LIBS_SUBDIR` alongside the other existing libraries, depending on the build mode used. full or mixed mode: copy j9gc_full29, j9gcchk_full29 compressed or mixed mode: copy j9gc29, j9gcchk29 Signed-off-by: Sharon Wang <[email protected]>
1 parent a8db8f2 commit e742126

File tree

2 files changed

+36
-12
lines changed

2 files changed

+36
-12
lines changed

closed/autoconf/custom-hook.m4

+34-12
Original file line numberDiff line numberDiff line change
@@ -342,16 +342,26 @@ AC_DEFUN([OPENJ9_PLATFORM_SETUP],
342342
AC_ARG_WITH(noncompressedrefs, [AS_HELP_STRING([--with-noncompressedrefs],
343343
[build non-compressedrefs vm (large heap)])])
344344
345+
AC_ARG_WITH(mixedrefs, [AS_HELP_STRING([--with-mixedrefs],
346+
[build mixedrefs vm ])])
347+
345348
# When compiling natively host_cpu and build_cpu are the same. But when
346349
# cross compiling we need to work with the host_cpu (which is where the final
347350
# JVM will run).
348351
OPENJ9_PLATFORM_EXTRACT_VARS_FROM_CPU($host_cpu)
349352
350-
if test "x$with_noncompressedrefs" = x ; then
351-
OPENJ9_BUILDSPEC="${OPENJDK_BUILD_OS}_${OPENJ9_CPU}_cmprssptrs"
352-
OPENJ9_LIBS_SUBDIR=compressedrefs
353+
ENABLE_MIXED_REFERENCES=false
354+
if test "x$with_mixedrefs" = x; then
355+
if test "x$with_noncompressedrefs" = x ; then
356+
OPENJ9_BUILDSPEC="${OPENJDK_BUILD_OS}_${OPENJ9_CPU}_cmprssptrs"
357+
OPENJ9_LIBS_SUBDIR=compressedrefs
358+
else
359+
OPENJ9_BUILDSPEC="${OPENJDK_BUILD_OS}_${OPENJ9_CPU}"
360+
OPENJ9_LIBS_SUBDIR=default
361+
fi
353362
else
354-
OPENJ9_BUILDSPEC="${OPENJDK_BUILD_OS}_${OPENJ9_CPU}"
363+
ENABLE_MIXED_REFERENCES=true
364+
OPENJ9_BUILDSPEC="${OPENJDK_BUILD_OS}_${OPENJ9_CPU}_mxdptrs"
355365
OPENJ9_LIBS_SUBDIR=default
356366
fi
357367
@@ -360,25 +370,37 @@ AC_DEFUN([OPENJ9_PLATFORM_SETUP],
360370
OPENJ9_PLATFORM_CODE=xa64
361371
elif test "x$OPENJDK_BUILD_OS" = xwindows ; then
362372
OPENJ9_PLATFORM_CODE=wa64
363-
if test "x$OPENJ9_LIBS_SUBDIR" = xdefault ; then
364-
OPENJ9_BUILDSPEC=win_x86-64
373+
if test "x$ENABLE_MIXED_REFERENCES" = xfalse ; then
374+
if test "x$OPENJ9_LIBS_SUBDIR" = xdefault ; then
375+
OPENJ9_BUILDSPEC=win_x86-64
376+
else
377+
OPENJ9_BUILDSPEC=win_x86-64_cmprssptrs
378+
fi
365379
else
366-
OPENJ9_BUILDSPEC=win_x86-64_cmprssptrs
380+
OPENJ9_BUILDSPEC=win_x86-64_mxdptrs
367381
fi
368382
elif test "x$OPENJDK_BUILD_OS" = xmacosx ; then
369383
OPENJ9_PLATFORM_CODE=oa64
370-
if test "x$OPENJ9_LIBS_SUBDIR" = xdefault ; then
371-
OPENJ9_BUILDSPEC=osx_x86-64
384+
if test "x$ENABLE_MIXED_REFERENCES" = xfalse ; then
385+
if test "x$OPENJ9_LIBS_SUBDIR" = xdefault ; then
386+
OPENJ9_BUILDSPEC=osx_x86-64
387+
else
388+
OPENJ9_BUILDSPEC=osx_x86-64_cmprssptrs
389+
fi
372390
else
373-
OPENJ9_BUILDSPEC=osx_x86-64_cmprssptrs
391+
OPENJ9_BUILDSPEC=osx_x86-64_mxdptrs
374392
fi
375393
else
376394
AC_MSG_ERROR([Unsupported OpenJ9 platform ${OPENJDK_BUILD_OS}!])
377395
fi
378396
elif test "x$OPENJ9_CPU" = xppc-64_le ; then
379397
OPENJ9_PLATFORM_CODE=xl64
380-
if test "x$OPENJ9_LIBS_SUBDIR" != xdefault ; then
381-
OPENJ9_BUILDSPEC="${OPENJDK_BUILD_OS}_ppc-64_cmprssptrs_le"
398+
if test "x$ENABLE_MIXED_REFERENCES" = xfalse ; then
399+
if test "x$OPENJ9_LIBS_SUBDIR" != xdefault ; then
400+
OPENJ9_BUILDSPEC="${OPENJDK_BUILD_OS}_ppc-64_cmprssptrs_le"
401+
fi
402+
else
403+
OPENJ9_BUILDSPEC="${OPENJDK_BUILD_OS}_ppc-64_mxdptrs_le"
382404
fi
383405
elif test "x$OPENJ9_CPU" = x390-64 ; then
384406
OPENJ9_PLATFORM_CODE=xz64

closed/custom/copy/Copy-java.base.gmk

+2
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,9 @@ $(call openj9_copy_shlibs, \
6363
$(if $(filter zos,$(OPENJDK_TARGET_OS)),j9a2e) \
6464
j9dmp29 \
6565
j9gc29 \
66+
j9gc_full29 \
6667
j9gcchk29 \
68+
j9gcchk_full29 \
6769
j9hookable29 \
6870
$(if $(filter zos,$(OPENJDK_TARGET_OS)),j9ifa29) \
6971
$(if $(filter $(NO_JIT_CPUS),$(OPENJDK_TARGET_CPU)),,j9jit29) \

0 commit comments

Comments
 (0)