8165440: Add Zero support for x86_64-linux-gnux32 target

Reviewed-by: erikj, ihse
This commit is contained in:
John Paul Adrian Glaubitz 2018-09-05 11:15:28 +02:00
parent e2eab3c1b7
commit e7a2c9d679
3 changed files with 11 additions and 2 deletions

View File

@ -241,7 +241,8 @@ AC_DEFUN_ONCE([FLAGS_PRE_TOOLCHAIN],
elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
MACHINE_FLAG="-m${OPENJDK_TARGET_CPU_BITS}"
elif test "x$TOOLCHAIN_TYPE" = xgcc || test "x$TOOLCHAIN_TYPE" = xclang; then
if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86 ||
if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86 &&
test "x$OPENJDK_TARGET_CPU" != xx32 ||
test "x$OPENJDK_TARGET_CPU_ARCH" = xsparc ||
test "x$OPENJDK_TARGET_CPU_ARCH" = xppc; then
MACHINE_FLAG="-m${OPENJDK_TARGET_CPU_BITS}"

View File

@ -30,6 +30,12 @@ AC_DEFUN([PLATFORM_EXTRACT_VARS_FROM_CPU],
[
# First argument is the cpu name from the trip/quad
case "$1" in
x86_64*x32)
VAR_CPU=x32
VAR_CPU_ARCH=x86
VAR_CPU_BITS=32
VAR_CPU_ENDIAN=little
;;
x86_64)
VAR_CPU=x86_64
VAR_CPU_ARCH=x86
@ -455,6 +461,8 @@ AC_DEFUN([PLATFORM_SETUP_LEGACY_VARS_HELPER],
HOTSPOT_$1_CPU_DEFINE=IA32
elif test "x$OPENJDK_$1_CPU" = xx86_64; then
HOTSPOT_$1_CPU_DEFINE=AMD64
elif test "x$OPENJDK_$1_CPU" = xx32; then
HOTSPOT_$1_CPU_DEFINE=X32
elif test "x$OPENJDK_$1_CPU" = xsparcv9; then
HOTSPOT_$1_CPU_DEFINE=SPARC
elif test "x$OPENJDK_$1_CPU" = xaarch64; then

View File

@ -1742,7 +1742,7 @@ void * os::dll_load(const char *filename, char *ebuf, int ebuflen) {
#if (defined IA32)
static Elf32_Half running_arch_code=EM_386;
#elif (defined AMD64)
#elif (defined AMD64) || (defined X32)
static Elf32_Half running_arch_code=EM_X86_64;
#elif (defined IA64)
static Elf32_Half running_arch_code=EM_IA_64;