https://gcc.gnu.org/bugzilla/show_bug.cgi?id=126082
--- Comment #4 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-14 branch has been updated by Christophe Lyon <[email protected]>: https://gcc.gnu.org/g:4034677deda9a05613c5ff8b715b4057a5813e1b commit r14-12956-g4034677deda9a05613c5ff8b715b4057a5813e1b Author: Christophe Lyon <[email protected]> Date: Fri Oct 2 07:44:06 2026 +0000 [testsuite, arm]: Rework arm_fp16_ok effective target [PR126082] arm_fp16_ok accepts a few -mfpu= overrides (*fp16*, vfpvN where N>=4, *fp-armv8*), but exits early with -mfpu=auto even though the related -march could include a valid FP option. In addition, it is no longer necessary to check for such flags, since modern DejaGnu gives them lower priority compared to the dg-add-options directives from individual testcases. Rework arm_fp16_ok to make it similar to arm_neon_ok and friends, iterating over several sets of flags until a working combination is found. Keep -mfpu=vfpv4 as in the original version. Tested on: -marm/-march=armv7-a/-mfloat-abi=soft -marm/-march=armv7-a/-mfpu=vfpv3-d16/-mfloat-abi=softfp -mthumb/-march=armv6s-m/-mtune=cortex-m0/-mfloat-abi=soft -mthumb/-march=armv7-m/-mtune=cortex-m3/-mfloat-abi=softfp -mthumb/-march=armv7e-m+fp/-mtune=cortex-m4/-mfloat-abi=hard -mthumb/-march=armv7e-m+fp.dp/-mtune=cortex-m7/-mfloat-abi=hard -mthumb/-march=armv8-m.base/-mtune=cortex-m23/-mfloat-abi=soft -mthumb/-march=armv8-m.main+dsp+fp/-mtune=cortex-m33/-mfloat-abi=hard -mthumb/-march=armv8.1-m.main+mve.fp+fp.dp/-mtune=cortex-m55/-mfloat-abi=hard -mthumb/-march=armv7-a/-mfpu=vfpv3-d16/-mfloat-abi=softfp -mthumb/-march=armv8-a+simd/-mfloat-abi=hard The tests gcc.target/arm/fp16-compile-vcvt.c gcc.target/arm/fp16-rounding-alt-1.c gcc.target/arm/vect-half-floats.c now PASS on * -marm/-march=armv7-a/-mfloat-abi=soft (was rejected because of -mfloat-abi=soft) * -mthumb/-march=armv7-a/-mfpu=vfpv3-d16/-mfloat-abi=softfp (was rejected because of -mfpu=vfpv3-d16) gcc.target/arm/vect-half-floats.c is UNSUPPORTED on -mthumb/-march=armv8.1-m.main+mve.fp+fp.dp/-mtune=cortex-m55/-mfloat-abi=hard thanks to the previous patch. gcc/testsuite/ChangeLog: PR testsuite/126082 * lib/target-supports.exp (check_effective_target_arm_fp16_ok_nocache): Iterate to find suitable flags. (cherry picked from commit 2936bd1c97134bd50e887f2e1d6fe306e514d70a)
