Skip to content

Commit

Permalink
Add support for mixed references mode in CMake builds
Browse files Browse the repository at this point in the history
Create new CMake spec files for mixed references mode

Update CMakeLists.txt for GC libs to support mixed refs mode

Update GC library selection to support mixed references static

Add configure documentation for --with-mixedrefs=[static|dynamic]

Add pipeline changes to build CMake mixed references mode

Set OMR_MIXED_REFERENCES_MODE_STATIC in mxdptrs.cmake

Declare the two glue interface libraries before adding omr

Signed-off-by: Sharon Wang <sharon-wang-cpsc@outlook.com>
  • Loading branch information
sharon-wang committed Nov 19, 2020
1 parent bff22d2 commit ae0f27d
Show file tree
Hide file tree
Showing 45 changed files with 940 additions and 75 deletions.
16 changes: 16 additions & 0 deletions buildenv/jenkins/jobs/pipelines/Pipeline-Build-Test-All.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -74,37 +74,43 @@ SPECS = ['ppc64_aix' : CURRENT_RELEASES,
'ppc64_aix_xl' : CURRENT_RELEASES,
'ppc64_aix_xl_cm' : CURRENT_RELEASES,
'ppc64_aix_xl_uma' : CURRENT_RELEASES,
'ppc64_aix_mixed_cm' : CURRENT_RELEASES,
'ppc64le_linux' : CURRENT_RELEASES,
'ppc64le_linux_cm' : CURRENT_RELEASES - '11',
'ppc64le_linux_uma' : CURRENT_RELEASES,
'ppc64le_linux_jit' : CURRENT_RELEASES,
'ppc64le_linux_xl' : CURRENT_RELEASES,
'ppc64le_linux_xl_cm' : CURRENT_RELEASES - '11',
'ppc64le_linux_xl_uma' : CURRENT_RELEASES,
'ppc64le_linux_mixed_cm' : CURRENT_RELEASES,
's390x_linux' : CURRENT_RELEASES,
's390x_linux_cm' : CURRENT_RELEASES - '11',
's390x_linux_uma' : CURRENT_RELEASES,
's390x_linux_jit' : CURRENT_RELEASES,
's390x_linux_xl' : CURRENT_RELEASES,
's390x_linux_xl_cm' : CURRENT_RELEASES - '11',
's390x_linux_xl_uma' : CURRENT_RELEASES,
's390x_linux_mixed_cm' : CURRENT_RELEASES,
's390x_zos' : ['11'],
's390x_zos_cm' : ['11'],
's390x_zos_uma' : ['11'],
's390x_zos_xl' : ['11'],
's390x_zos_xl_cm' : ['11'],
's390x_zos_mixed_cm' : ['11'],
'x86-64_linux' : CURRENT_RELEASES,
'x86-64_linux_cm': CURRENT_RELEASES - '11',
'x86-64_linux_uma' : CURRENT_RELEASES,
'x86-64_linux_xl': CURRENT_RELEASES,
'x86-64_linux_xl_cm': CURRENT_RELEASES - '11',
'x86-64_linux_xl_uma' : CURRENT_RELEASES,
'x86-64_linux_mixed_cm' : CURRENT_RELEASES,
'x86-64_linux_jit' : CURRENT_RELEASES,
'x86-64_linux_valhalla' : ['next'],
'x86-64_mac_xl' : CURRENT_RELEASES,
'x86-64_mac' : CURRENT_RELEASES,
'x86-64_mac_cm' : CURRENT_RELEASES - '11',
'x86-64_mac_xl_cm' : CURRENT_RELEASES - '11',
'x86-64_mac_mixed_cm' : CURRENT_RELEASES,
'x86-64_mac_uma' : CURRENT_RELEASES,
'x86-64_mac_xl_uma' : CURRENT_RELEASES,
'x86-32_windows' : ['8'],
Expand All @@ -116,12 +122,14 @@ SPECS = ['ppc64_aix' : CURRENT_RELEASES,
'x86-64_windows_xl' : CURRENT_RELEASES,
'x86-64_windows_xl_cm': CURRENT_RELEASES,
'x86-64_windows_xl_uma' : CURRENT_RELEASES,
'x86-64_windows_mixed_cm' : CURRENT_RELEASES,
'aarch64_linux' : CURRENT_RELEASES,
'aarch64_linux_cm': CURRENT_RELEASES,
'aarch64_linux_uma': CURRENT_RELEASES,
'aarch64_linux_xl' : CURRENT_RELEASES,
'aarch64_linux_xl_cm': CURRENT_RELEASES,
'aarch64_linux_xl_uma': CURRENT_RELEASES,
'aarch64_linux_mixed_cm' : CURRENT_RELEASES,
'ppc64_aix_ojdk292' : CURRENT_RELEASES,
'ppc64_aix_xl_ojdk292' : CURRENT_RELEASES,
'ppc64le_linux_ojdk292' : CURRENT_RELEASES,
Expand Down Expand Up @@ -150,6 +158,7 @@ SHORT_NAMES = ['all' : ['ppc64le_linux','ppc64le_linux_xl','s390x_linux','s390x_
'aixxl' : ['ppc64_aix_xl'],
'aixxlcm' : ['ppc64_aix_xl_cm'],
'aixxluma' : ['ppc64_aix_xl_uma'],
'aixmxdcm' : ['ppc64_aix_mixed_cm'],
'zlinux' : ['s390x_linux'],
'zlinuxcm' : ['s390x_linux_cm'],
'zlinuxuma' : ['s390x_linux_uma'],
Expand All @@ -158,6 +167,7 @@ SHORT_NAMES = ['all' : ['ppc64le_linux','ppc64le_linux_xl','s390x_linux','s390x_
'zlinuxxl' : ['s390x_linux_xl'],
'zlinuxxlcm' : ['s390x_linux_xl_cm'],
'zlinuxxluma' : ['s390x_linux_xl_uma'],
'zlinuxmxdcm' : ['s390x_linux_mixed_cm'],
'plinux' : ['ppc64le_linux'],
'plinuxcmake' : ['ppc64le_linux_cm'],
'plinuxcm' : ['ppc64le_linux_cm'],
Expand All @@ -167,6 +177,7 @@ SHORT_NAMES = ['all' : ['ppc64le_linux','ppc64le_linux_xl','s390x_linux','s390x_
'plinuxxl' : ['ppc64le_linux_xl'],
'plinuxxlcm' : ['ppc64le_linux_xl_cm'],
'plinuxxluma' : ['ppc64le_linux_xl_uma'],
'plinuxmxdcm' : ['ppc64le_linux_mixed_cm'],
'xlinuxlargeheap' : ['x86-64_linux_xl'],
'xlinuxxl' : ['x86-64_linux_xl'],
'xlinux' : ['x86-64_linux'],
Expand All @@ -175,6 +186,7 @@ SHORT_NAMES = ['all' : ['ppc64le_linux','ppc64le_linux_xl','s390x_linux','s390x_
'xlinuxuma' : ['x86-64_linux_uma'],
'xlinuxxlcm' : ['x86-64_linux_xl_cm'],
'xlinuxxluma' : ['x86-64_linux_xl_uma'],
'xlinuxmxdcm' : ['x86-64_linux_mixed_cm'],
'xlinuxjit' : ['x86-64_linux_jit'],
'xlinuxval' : ['x86-64_linux_valhalla'],
'win32' : ['x86-32_windows'],
Expand All @@ -187,6 +199,7 @@ SHORT_NAMES = ['all' : ['ppc64le_linux','ppc64le_linux_xl','s390x_linux','s390x_
'winxl' : ['x86-64_windows_xl'],
'winxlcm' : ['x86-64_windows_xl_cm'],
'winxluma' : ['x86-64_windows_xl_uma'],
'winmxdcm' : ['x86-64_windows_mixed_cm'],
'osx' : ['x86-64_mac'],
'osxlargeheap' : ['x86-64_mac_xl'],
'osxxl' : ['x86-64_mac_xl'],
Expand All @@ -195,19 +208,22 @@ SHORT_NAMES = ['all' : ['ppc64le_linux','ppc64le_linux_xl','s390x_linux','s390x_
'osxxlcm': ['x86-64_mac_xl_cm'],
'osxuma': ['x86-64_mac_uma'],
'osxxluma': ['x86-64_mac_xl_uma'],
'osxmxdcm': ['x86-64_mac_mixed_cm'],
'alinux64' : ['aarch64_linux'],
'alinux64cm' : ['aarch64_linux_cm'],
'alinux64uma' : ['aarch64_linux_uma'],
'alinux64xl' : ['aarch64_linux_xl'],
'alinux64xlcm' : ['aarch64_linux_xl_cm'],
'alinux64xluma' : ['aarch64_linux_xl_uma'],
'alinux64largeheap' : ['aarch64_linux_xl'],
'alinux64mxdcm' : ['aarch64_linux_mixed_cm'],
'zos' : ['s390x_zos'],
'zoscm' : ['s390x_zos_cm'],
'zosuma' : ['s390x_zos_uma'],
'zosxl' : ['s390x_zos_xl'],
'zoslargeheap' : ['s390x_zos_xl'],
'zosxlcm' : ['s390x_zos_xl_cm'],
'zosmxdcm' : ['s390x_zos_mixed_cm'],
'aixojdk292' : ['ppc64_aix_ojdk292'],
'aixxlojdk292' : ['ppc64_aix_xl_ojdk292'],
'aixlargeheapojdk292' : ['ppc64_aix_xl_ojdk292'],
Expand Down
91 changes: 91 additions & 0 deletions buildenv/jenkins/variables/defaults.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,11 @@ debuginfo:
largeheap:
extra_configure_options: '--with-noncompressedrefs'
#========================================#
# Mixed references build
#========================================#
mixedrefs:
extra_configure_options: '--with-mixedrefs'
#========================================#
# Build with cmake
#========================================#
cmake:
Expand Down Expand Up @@ -250,6 +255,21 @@ ppc64le_linux_xl_cm:
ppc64le_linux_xl_uma:
extends: ['ppc64le_linux_xl', 'uma']
#========================================#
# Linux PPCLE 64bits Mixed References
#========================================#
ppc64le_linux_mixed:
extends: ['ppc64le_linux', 'mixedrefs']
excluded_tests:
8:
- special.system
11:
- special.system
#========================================#
# Linux PPCLE 64bits Mixed References /w CMake
#========================================#
ppc64le_linux_mixed_cm:
extends: ['ppc64le_linux_mixed', 'cmake']
#========================================#
# Linux PPCLE 64bits Compressed Pointers /w JITSERVER
#========================================#
ppc64le_linux_jit:
Expand Down Expand Up @@ -303,6 +323,19 @@ s390x_linux_xl_cm:
s390x_linux_xl_uma:
extends: ['s390x_linux_xl', 'uma']
#========================================#
# Linux S390 64bits Mixed References
#========================================#
s390x_linux_mixed:
extends: ['s390x_linux', 'mixedrefs']
excluded_tests:
11:
- special.system
#========================================#
# Linux S390 64bits Mixed References /w CMake
#========================================#
s390x_linux_mixed_cm:
extends: ['s390x_linux_mixed', 'cmake']
#========================================#
# Linux S390 64bits Compressed Pointers /w JITSERVER
#========================================#
s390x_linux_jit:
Expand Down Expand Up @@ -362,6 +395,16 @@ ppc64_aix_xl_cm:
ppc64_aix_xl_uma:
extends: ['ppc64_aix_xl', 'uma']
#========================================#
# AIX PPC 64bits Mixed References
#========================================#
ppc64_aix_mixed:
extends: ['ppc64_aix', 'mixedrefs']
#========================================#
# AIX PPC 64bits Mixed References /w CMake
#========================================#
ppc64_aix_mixed_cm:
extends: ['ppc64_aix_mixed', 'cmake']
#========================================#
# Linux x86 64bits Compressed Pointers
#========================================#
x86-64_linux:
Expand Down Expand Up @@ -432,6 +475,21 @@ x86-64_linux_xl:
8:
- special.system
#========================================#
# Linux x86 64bits Mixed References
#========================================#
x86-64_linux_mixed:
extends: ['x86-64_linux', 'mixedrefs']
excluded_tests:
- extended.functional
- sanity.system
- extended.system
- special.system
#========================================#
# Linux x86 64bits Mixed References /w CMake
#========================================#
x86-64_linux_mixed_cm:
extends: ['x86-64_linux_mixed', 'cmake']
#========================================#
# Linux x86 64bits Compressed Pointers / Valhalla
#========================================#
x86-64_linux_valhalla:
Expand Down Expand Up @@ -477,6 +535,16 @@ aarch64_linux_xl_cm:
aarch64_linux_xl_uma:
extends: ['aarch64_linux_xl', 'uma']
#========================================#
# Linux Aarch 64bits Mixed References
#========================================#
aarch64_linux_mixed:
extends: ['aarch64_linux', 'mixedrefs']
#========================================#
# Linux Aarch 64bits Mixed References /w CMake
#========================================#
aarch64_linux_mixed_cm:
extends: ['aarch64_linux_mixed', 'cmake']
#========================================#
# Windows x86 64bits Compressed Pointers
#========================================#
x86-64_windows:
Expand Down Expand Up @@ -531,6 +599,16 @@ x86-64_windows_xl_cm:
x86-64_windows_xl_uma:
extends: ['x86-64_windows_xl', 'uma']
#========================================#
# Windows x86 64bits Mixed References
#========================================#
x86-64_windows_mixed:
extends: ['x86-64_windows', 'mixedrefs']
#========================================#
# Windows x86 64bits Mixed References /w CMake
#========================================#
x86-64_windows_mixed_cm:
extends: ['x86-64_windows_mixed', 'cmake']
#========================================#
# Windows x86 32bits
#========================================#
x86-32_windows:
Expand Down Expand Up @@ -598,6 +676,14 @@ x86-64_mac_xl:
8:
- special.system
#========================================#
# OSX x86 64bits Mixed References
#========================================#
x86-64_mac_mixed:
extends: ['x86-64_mac', 'mixedrefs']
excluded_tests:
8:
- special.system
#========================================#
# OSX x86 64bits Compressed Pointers /w CMake
#========================================#
x86-64_mac_cm:
Expand All @@ -608,6 +694,11 @@ x86-64_mac_cm:
x86-64_mac_xl_cm:
extends: ['x86-64_mac_xl', 'cmake']
#========================================#
# OSX x86 64bits Mixed References /w CMake
#========================================#
x86-64_mac_mixed_cm:
extends: ['x86-64_mac_mixed', 'cmake']
#========================================#
# OSX x86 64bits Compressed Pointers /w UMA
#========================================#
x86-64_mac_uma:
Expand Down
10 changes: 10 additions & 0 deletions doc/build-instructions/Build_Instructions_V11.md
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,8 @@ bash configure --with-freemarker-jar=/<my_home_dir>/freemarker.jar --with-boot-j

:pencil: **Non-compressed references support:** If you require a heap size greater than 57GB, enable a noncompressedrefs build with the `--with-noncompressedrefs` option during this step.

:pencil: **Mixed references support:** If you require a single build with both compressed references and non-compressed references available, enable a mixedrefs build with the `--with-mixedrefs` option during this step. Specify `--with-mixedrefs=static` for the VM to determine the reference mode statically (at compile time), or `--with-mixedrefs=dynamic` for the VM to determine the reference mode dynamically (at run time). The option defaults to determine the reference mode statically, if neither `static` nor `dynamic` is provided. _Note that `--with-cmake` must be used with this option, as it is only available with CMake enabled at this time._

:pencil: **OpenSSL support:** If you want to build an OpenJDK that includes OpenSSL, you must specify `--with-openssl={fetched|system|path_to_library}`

where:
Expand Down Expand Up @@ -282,6 +284,8 @@ where `<my_home_dir>` is the location where you stored **freemarker.jar** and `<

:pencil: **Non-compressed references support:** If you require a heap size greater than 57GB, enable a noncompressedrefs build with the `--with-noncompressedrefs` option during this step.

:pencil: **Mixed references support:** If you require a single build with both compressed references and non-compressed references available, enable a mixedrefs build with the `--with-mixedrefs` option during this step. Specify `--with-mixedrefs=static` for the VM to determine the reference mode statically (at compile time), or `--with-mixedrefs=dynamic` for the VM to determine the reference mode dynamically (at run time). The option defaults to determine the reference mode statically, if neither `static` nor `dynamic` is provided. _Note that `--with-cmake` must be used with this option, as it is only available with CMake enabled at this time._

:pencil: **OpenSSL support:** If you want to build an OpenJDK that includes OpenSSL, you must specify `--with-openssl={fetched|system|path_to_library}`

where:
Expand Down Expand Up @@ -441,6 +445,8 @@ Note: there is no need to specify --with-toolchain-version for 2017 as it will b

:pencil: **Non-compressed references support:** If you require a heap size greater than 57GB, enable a noncompressedrefs build with the `--with-noncompressedrefs` option during this step.

:pencil: **Mixed references support:** If you require a single build with both compressed references and non-compressed references available, enable a mixedrefs build with the `--with-mixedrefs` option during this step. Specify `--with-mixedrefs=static` for the VM to determine the reference mode statically (at compile time), or `--with-mixedrefs=dynamic` for the VM to determine the reference mode dynamically (at run time). The option defaults to determine the reference mode statically, if neither `static` nor `dynamic` is provided. _Note that `--with-cmake` must be used with this option, as it is only available with CMake enabled at this time._

:pencil: **OpenSSL support:** If you want to build an OpenJDK that includes OpenSSL, you must specify `--with-openssl=path_to_library`, where `path_to_library` specifies the path to the prebuilt OpenSSL library that you obtained in **2. Get the source**. If you want to include the OpenSSL cryptographic library in the OpenJDK binary, you must also include `--enable-openssl-bundling`.

### 4. build
Expand Down Expand Up @@ -559,6 +565,8 @@ bash configure --with-boot-jdk=<path_to_boot_JDK11>

:pencil: **Non-compressed references support:** If you require a heap size greater than 57GB, enable a noncompressedrefs build with the `--with-noncompressedrefs` option during this step.

:pencil: **Mixed references support:** If you require a single build with both compressed references and non-compressed references available, enable a mixedrefs build with the `--with-mixedrefs` option during this step. Specify `--with-mixedrefs=static` for the VM to determine the reference mode statically (at compile time), or `--with-mixedrefs=dynamic` for the VM to determine the reference mode dynamically (at run time). The option defaults to determine the reference mode statically, if neither `static` nor `dynamic` is provided. _Note that `--with-cmake` must be used with this option, as it is only available with CMake enabled at this time._

:pencil: **OpenSSL support:** If you want to build an OpenJDK that includes OpenSSL, you must specify `--with-openssl=path_to_library`, where `path_to_library` specifies the path to the prebuilt OpenSSL library that you obtained in **2. Get the source**. If you want to include the OpenSSL cryptographic library in the OpenJDK binary, you must also include `--enable-openssl-bundling`.

### 4. build
Expand Down Expand Up @@ -701,6 +709,8 @@ bash configure --openjdk-target=${OPENJ9_CC_PREFIX} \

:pencil: **Non-compressed references support:** If you require a heap size greater than 57GB, enable a noncompressedrefs build with the `--with-noncompressedrefs` option during this step.

:pencil: **Mixed references support:** If you require a single build with both compressed references and non-compressed references available, enable a mixedrefs build with the `--with-mixedrefs` option during this step. Specify `--with-mixedrefs=static` for the VM to determine the reference mode statically (at compile time), or `--with-mixedrefs=dynamic` for the VM to determine the reference mode dynamically (at run time). The option defaults to determine the reference mode statically, if neither `static` nor `dynamic` is provided. _Note that `--with-cmake` must be used with this option, as it is only available with CMake enabled at this time._

:pencil: **OpenSSL support:** If you want to build an OpenJDK that uses OpenSSL, you must specify `--with-openssl={system|path_to_library}`

where:
Expand Down
Loading

0 comments on commit ae0f27d

Please sign in to comment.