See [JDK-8288719](https://bugs.openjdk.org/browse/JDK-8288719) and subsequent 
[discussion](https://mail.openjdk.org/pipermail/build-dev/2022-May/034635.html) 
back in 2022.

On Arm, we can generate either arm- or thumb-code (`-marm` or `-mthumb`). 

At the moment, if we don't specify an ABI profile (`--with_abi_profile`) when 
configuring the build, we call gcc without `-marm` or `-mthumb`. Then we use 
whatever the toolchain defaults too, which is pretty much random (it depends on 
how the toolchain itself had been built). That can cause really rare but tricky 
problems when combining static assembly and C++ code (See e.g. JDK-8288719).

I propose to always specify `-marm` as default, unless an ABI profile is given, 
to prevent such errors.

Thanks to @marchof for testing this.

-------------

Commit messages:
 - Merge branch 'openjdk:master' into 
JDK-8313790-arm32-Specify-marm-when-building-without-an-ABI-profile
 - Merge branch 'openjdk:master' into 
JDK-8313790-arm32-Specify-marm-when-building-without-an-ABI-profile
 - Merge branch 'openjdk:master' into 
JDK-8313790-arm32-Specify-marm-when-building-without-an-ABI-profile
 - Merge branch 'openjdk:master' into 
JDK-8313790-arm32-Specify-marm-when-building-without-an-ABI-profile
 - Merge branch 'openjdk:master' into 
JDK-8313790-arm32-Specify-marm-when-building-without-an-ABI-profile
 - Merge branch 'openjdk:master' into 
JDK-8313790-arm32-Specify-marm-when-building-without-an-ABI-profile
 - start

Changes: https://git.openjdk.org/jdk/pull/15162/files
 Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=15162&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8313790
  Stats: 6 lines in 1 file changed: 6 ins; 0 del; 0 mod
  Patch: https://git.openjdk.org/jdk/pull/15162.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/15162/head:pull/15162

PR: https://git.openjdk.org/jdk/pull/15162

Reply via email to