8150197: Integrate AIX fixes from build-infra
Reviewed-by: erikj
This commit is contained in:
parent
2011115a3e
commit
4b8c19d6b7
@ -123,12 +123,16 @@ AC_DEFUN_ONCE([FLAGS_SETUP_INIT_FLAGS],
|
||||
[
|
||||
# COMPILER_TARGET_BITS_FLAG : option for selecting 32- or 64-bit output
|
||||
# COMPILER_COMMAND_FILE_FLAG : option for passing a command file to the compiler
|
||||
# COMPILER_BINDCMD_FILE_FLAG : option for specifying a file which saves the binder
|
||||
# commands produced by the link step (currently AIX only)
|
||||
if test "x$TOOLCHAIN_TYPE" = xxlc; then
|
||||
COMPILER_TARGET_BITS_FLAG="-q"
|
||||
COMPILER_COMMAND_FILE_FLAG="-f"
|
||||
COMPILER_BINDCMD_FILE_FLAG="-bloadmap:"
|
||||
else
|
||||
COMPILER_TARGET_BITS_FLAG="-m"
|
||||
COMPILER_COMMAND_FILE_FLAG="@"
|
||||
COMPILER_BINDCMD_FILE_FLAG=""
|
||||
|
||||
# The solstudio linker does not support @-files.
|
||||
if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
|
||||
@ -152,6 +156,7 @@ AC_DEFUN_ONCE([FLAGS_SETUP_INIT_FLAGS],
|
||||
fi
|
||||
AC_SUBST(COMPILER_TARGET_BITS_FLAG)
|
||||
AC_SUBST(COMPILER_COMMAND_FILE_FLAG)
|
||||
AC_SUBST(COMPILER_BINDCMD_FILE_FLAG)
|
||||
|
||||
# FIXME: figure out if we should select AR flags depending on OS or toolchain.
|
||||
if test "x$OPENJDK_TARGET_OS" = xmacosx; then
|
||||
@ -294,10 +299,23 @@ AC_DEFUN_ONCE([FLAGS_SETUP_COMPILER_FLAGS_FOR_LIBS],
|
||||
SET_SHARED_LIBRARY_NAME='-h [$]1'
|
||||
SET_SHARED_LIBRARY_MAPFILE='-M[$]1'
|
||||
elif test "x$TOOLCHAIN_TYPE" = xxlc; then
|
||||
PICFLAG="-qpic=large"
|
||||
# '-qpic' defaults to 'qpic=small'. This means that the compiler generates only
|
||||
# one instruction for accessing the TOC. If the TOC grows larger than 64K, the linker
|
||||
# will have to patch this single instruction with a call to some out-of-order code which
|
||||
# does the load from the TOC. This is of course slow. But in that case we also would have
|
||||
# to use '-bbigtoc' for linking anyway so we could also change the PICFLAG to 'qpic=large'.
|
||||
# With 'qpic=large' the compiler will by default generate a two-instruction sequence which
|
||||
# can be patched directly by the linker and does not require a jump to out-of-order code.
|
||||
# Another alternative instead of using 'qpic=large -bbigtoc' may be to use '-qminimaltoc'
|
||||
# instead. This creates a distinct TOC for every compilation unit (and thus requires two
|
||||
# loads for accessing a global variable). But there are rumors that this may be seen as a
|
||||
# 'performance feature' because of improved code locality of the symbols used in a
|
||||
# compilation unit.
|
||||
PICFLAG="-qpic"
|
||||
JVM_CFLAGS="$JVM_CFLAGS $PICFLAG"
|
||||
C_FLAG_REORDER=''
|
||||
CXX_FLAG_REORDER=''
|
||||
SHARED_LIBRARY_FLAGS="-qmkshrobj"
|
||||
SHARED_LIBRARY_FLAGS="-qmkshrobj -bM:SRE -bnoentry"
|
||||
SET_EXECUTABLE_ORIGIN=""
|
||||
SET_SHARED_LIBRARY_ORIGIN=''
|
||||
SET_SHARED_LIBRARY_NAME=''
|
||||
@ -835,7 +853,7 @@ AC_DEFUN_ONCE([FLAGS_SETUP_COMPILER_FLAGS_FOR_JDK],
|
||||
LDFLAGS_CXX_SOLSTUDIO="-norunpath"
|
||||
LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib"
|
||||
elif test "x$TOOLCHAIN_TYPE" = xxlc; then
|
||||
LDFLAGS_XLC="-brtl -bnolibpath -bexpall -bernotok"
|
||||
LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok"
|
||||
LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_XLC"
|
||||
fi
|
||||
|
||||
|
@ -744,6 +744,7 @@ EXE_OUT_OPTION
|
||||
CC_OUT_OPTION
|
||||
STRIPFLAGS
|
||||
ARFLAGS
|
||||
COMPILER_BINDCMD_FILE_FLAG
|
||||
COMPILER_COMMAND_FILE_FLAG
|
||||
COMPILER_TARGET_BITS_FLAG
|
||||
JT_HOME
|
||||
@ -4861,7 +4862,7 @@ VS_SDK_PLATFORM_NAME_2013=
|
||||
#CUSTOM_AUTOCONF_INCLUDE
|
||||
|
||||
# Do not change or remove the following line, it is needed for consistency checks:
|
||||
DATE_WHEN_GENERATED=1456136545
|
||||
DATE_WHEN_GENERATED=1456136781
|
||||
|
||||
###############################################################################
|
||||
#
|
||||
@ -45392,12 +45393,16 @@ $as_echo "$tool_specified" >&6; }
|
||||
|
||||
# COMPILER_TARGET_BITS_FLAG : option for selecting 32- or 64-bit output
|
||||
# COMPILER_COMMAND_FILE_FLAG : option for passing a command file to the compiler
|
||||
# COMPILER_BINDCMD_FILE_FLAG : option for specifying a file which saves the binder
|
||||
# commands produced by the link step (currently AIX only)
|
||||
if test "x$TOOLCHAIN_TYPE" = xxlc; then
|
||||
COMPILER_TARGET_BITS_FLAG="-q"
|
||||
COMPILER_COMMAND_FILE_FLAG="-f"
|
||||
COMPILER_BINDCMD_FILE_FLAG="-bloadmap:"
|
||||
else
|
||||
COMPILER_TARGET_BITS_FLAG="-m"
|
||||
COMPILER_COMMAND_FILE_FLAG="@"
|
||||
COMPILER_BINDCMD_FILE_FLAG=""
|
||||
|
||||
# The solstudio linker does not support @-files.
|
||||
if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
|
||||
@ -45425,6 +45430,7 @@ $as_echo "no" >&6; }
|
||||
|
||||
|
||||
|
||||
|
||||
# FIXME: figure out if we should select AR flags depending on OS or toolchain.
|
||||
if test "x$OPENJDK_TARGET_OS" = xmacosx; then
|
||||
ARFLAGS="-r"
|
||||
@ -46199,10 +46205,23 @@ $as_echo "$ac_cv_c_bigendian" >&6; }
|
||||
SET_SHARED_LIBRARY_NAME='-h $1'
|
||||
SET_SHARED_LIBRARY_MAPFILE='-M$1'
|
||||
elif test "x$TOOLCHAIN_TYPE" = xxlc; then
|
||||
PICFLAG="-qpic=large"
|
||||
# '-qpic' defaults to 'qpic=small'. This means that the compiler generates only
|
||||
# one instruction for accessing the TOC. If the TOC grows larger than 64K, the linker
|
||||
# will have to patch this single instruction with a call to some out-of-order code which
|
||||
# does the load from the TOC. This is of course slow. But in that case we also would have
|
||||
# to use '-bbigtoc' for linking anyway so we could also change the PICFLAG to 'qpic=large'.
|
||||
# With 'qpic=large' the compiler will by default generate a two-instruction sequence which
|
||||
# can be patched directly by the linker and does not require a jump to out-of-order code.
|
||||
# Another alternative instead of using 'qpic=large -bbigtoc' may be to use '-qminimaltoc'
|
||||
# instead. This creates a distinct TOC for every compilation unit (and thus requires two
|
||||
# loads for accessing a global variable). But there are rumors that this may be seen as a
|
||||
# 'performance feature' because of improved code locality of the symbols used in a
|
||||
# compilation unit.
|
||||
PICFLAG="-qpic"
|
||||
JVM_CFLAGS="$JVM_CFLAGS $PICFLAG"
|
||||
C_FLAG_REORDER=''
|
||||
CXX_FLAG_REORDER=''
|
||||
SHARED_LIBRARY_FLAGS="-qmkshrobj"
|
||||
SHARED_LIBRARY_FLAGS="-qmkshrobj -bM:SRE -bnoentry"
|
||||
SET_EXECUTABLE_ORIGIN=""
|
||||
SET_SHARED_LIBRARY_ORIGIN=''
|
||||
SET_SHARED_LIBRARY_NAME=''
|
||||
@ -46825,7 +46844,7 @@ $as_echo "$supports" >&6; }
|
||||
LDFLAGS_CXX_SOLSTUDIO="-norunpath"
|
||||
LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib"
|
||||
elif test "x$TOOLCHAIN_TYPE" = xxlc; then
|
||||
LDFLAGS_XLC="-brtl -bnolibpath -bexpall -bernotok"
|
||||
LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok"
|
||||
LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_XLC"
|
||||
fi
|
||||
|
||||
|
@ -314,6 +314,10 @@ COMPILER_SUPPORTS_TARGET_BITS_FLAG=@COMPILER_SUPPORTS_TARGET_BITS_FLAG@
|
||||
# Option used to pass a command file to the compiler
|
||||
COMPILER_COMMAND_FILE_FLAG:=@COMPILER_COMMAND_FILE_FLAG@
|
||||
|
||||
# Option for specifying a file which saves the binder commands
|
||||
# produced by the link step (for debugging, currently AIX only)
|
||||
COMPILER_BINDCMD_FILE_FLAG:=@COMPILER_BINDCMD_FILE_FLAG@
|
||||
|
||||
CC_OUT_OPTION:=@CC_OUT_OPTION@
|
||||
EXE_OUT_OPTION:=@EXE_OUT_OPTION@
|
||||
LD_OUT_OPTION:=@LD_OUT_OPTION@
|
||||
|
@ -771,6 +771,11 @@ define SetupNativeCompilationBody
|
||||
$1_EXTRA_LDFLAGS += "-implib:$$($1_OBJECT_DIR)/$$($1_LIBRARY).lib"
|
||||
endif
|
||||
|
||||
# Create loadmap on AIX. Helps in diagnosing some problems.
|
||||
ifneq ($(COMPILER_BINDCMD_FILE_FLAG),)
|
||||
$1_EXTRA_LDFLAGS += $(COMPILER_BINDCMD_FILE_FLAG)$$($1_OBJECT_DIR)/$$($1_NOSUFFIX).loadmap
|
||||
endif
|
||||
|
||||
$1_EXTRA_LIBS += $(GLOBAL_LIBS)
|
||||
|
||||
$1_VARDEPS := $$($1_LD) $$($1_SYSROOT_LDFLAGS) $$($1_LDFLAGS) $$($1_EXTRA_LDFLAGS) \
|
||||
|
Loading…
Reference in New Issue
Block a user