[PATCH] Add optimization flags for ARM926EJ-S

David Holmes david.holmes at oracle.com
Mon Nov 12 23:41:41 UTC 2018


Hi Jakub,

Build file changes have to be reviewed on build-dev - cc'd.

Thanks,
David

On 13/11/2018 8:57 AM, Jakub Vaněk wrote:
> Hi,
> 
> This patch adds a new ARM ABI option for ARM926EJ-S. The reason is not
> because of ABI breakage, but it is because of GCC -mcpu flags
> specifically for this CPU. We think that this might increase
> performance a little bit. However, we do not have numbers for this.
> Alternatively, we may just stick to the arm-sflt ABI option.
> 
> This patch was successfully built with a few other independent patches
> here: https://ci.adoptopenjdk.net/view/ev3dev/ ;
> https://github.com/ev3dev-lang-java/openjdk-ev3
> We haven't run full jtreg tests on the target platform yet, but Juan
> Antonio Brena Moral invested his time into Adopt's openjdktests in
> QEMU. Also, the JVM seems to run fine on the ARM board itself.
> 
> Regards,
> 
> Jakub Vanek (with credit to Juan Antonio)
> 
> # HG changeset patch
> # User Jakub Vaněk <linuxtardis at gmail.com>
> # Date 1542060149 -3600
> #      Mon Nov 12 23:02:29 2018 +0100
> # Node ID 82c5c630ee8f9237b533ba6414143d109dec0180
> # Parent  a609d549992a4d094a514a6c0f5b79443192d8bf
> Add optimization flags for ARM926EJ-S
> 
> diff --git a/make/autoconf/flags-other.m4 b/make/autoconf/flags-other.m4
> --- a/make/autoconf/flags-other.m4
> +++ b/make/autoconf/flags-other.m4
> @@ -119,6 +119,10 @@
>     # Misuse EXTRA_CFLAGS to mimic old behavior
>     $2JVM_ASFLAGS="$JVM_BASIC_ASFLAGS ${$2EXTRA_CFLAGS}"
> 
> +  if test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm926ejs; then
> +    $2JVM_ASFLAGS="$JVM_BASIC_ASFLAGS -mcpu=arm926ej-s"
> +  fi
> +
>     AC_SUBST($2JVM_ASFLAGS)
>   ])
> 
> diff --git a/make/autoconf/flags.m4 b/make/autoconf/flags.m4
> --- a/make/autoconf/flags.m4
> +++ b/make/autoconf/flags.m4
> @@ -34,7 +34,7 @@
>   AC_DEFUN([FLAGS_SETUP_ABI_PROFILE],
>   [
>     AC_ARG_WITH(abi-profile, [AS_HELP_STRING([--with-abi-profile],
> -      [specify ABI profile for ARM builds
> (arm-vfp-sflt,arm-vfp-hflt,arm-sflt,
> armv5-vfp-sflt,armv6-vfp-hflt,aarch64) @<:@toolchain dependent@:>@
> ])])
> +      [specify ABI profile for ARM builds
> (arm-vfp-sflt,arm-vfp-hflt,arm-sflt,
> arm926ejs,armv5-vfp-sflt,armv6-vfp-hflt,aarch64) @<:@toolchain
> dependent@:>@ ])])
> 
>     if test "x$with_abi_profile" != x; then
>       if test "x$OPENJDK_TARGET_CPU" != xarm && \
> @@ -55,6 +55,9 @@
>       elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-sflt; then
>         ARM_FLOAT_TYPE=sflt
>         ARM_ARCH_TYPE_FLAGS='-march=armv5t -marm'
> +    elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm926ejs; then
> +      ARM_FLOAT_TYPE=sflt
> +      ARM_ARCH_TYPE_FLAGS='-mcpu=arm926ej-s -marm'
>       elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarmv5-vfp-sflt; then
>         ARM_FLOAT_TYPE=vfp-sflt
>         ARM_ARCH_TYPE_FLAGS='-march=armv5t -marm'
> 


More information about the build-dev mailing list