https://gcc.gnu.org/bugzilla/show_bug.cgi?id=129017

--- Comment #3 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Igor Shevlyakov
<[email protected]>:

https://gcc.gnu.org/g:0ec86b4c9d3b66be6750a3e015c4a6e37890c666

commit r17-6675-g0ec86b4c9d3b66be6750a3e015c4a6e37890c666
Author: Igor Shevlyakov <[email protected]>
Date:   Tue Nov 24 23:34:25 2026 -0800

    testsuite: Fix the AArch64 complex, dotprod and i8mm hardware checks
[PR129017]

    check_effective_target_arm_v8_3a_complex_neon_hw runs FCADD #90 on
    {1, 3} and {2, 5} and expects {8, 24}, values copied from the dotprod
    check.  FCADD #90 gives {1 - 5, 3 + 2} = {-4, 5}, so since
    r11-5969-g3ed472af6bc inverted the return value the check has failed on
    every machine with FEAT_FCMA, and the tests that need it have been
    UNSUPPORTED on real hardware.  pr122408_2.f90 has never been run with
    -march=armv8.3-a.  Expecting {-4, 5} instead would fail on big-endian,
    where the real and imaginary lanes are swapped, so use a zero addend:
    FCADD then returns its first operand whatever the lane order.

    check_effective_target_arm_v8_2a_dotprod_neon_hw has the opposite
    problem.  UDOT accumulates into its destination, but the asm declares
    RESULTS as output only, so the sum is added to whatever the register
    held; the check then fails only when the result is exactly {8, 24}, the
    right answer.  It works as long as the register is not zero.
    check_effective_target_arm_v8_2a_i8mm_neon_hw, a copy of it for USDOT,
    has the same problem.  In both, make RESULTS an input as well and fail
    on anything but {8, 24}.

    With the complex check fixed, pr126592.c runs, and its
    scan-assembler-not has no assembly file to scan.  Add -save-temps.

    Assisted-by: Claude Opus 5.5

            PR testsuite/129017

    gcc/testsuite/ChangeLog:

            * lib/target-supports.exp
            (check_effective_target_arm_v8_2a_dotprod_neon_hw): Accumulate into
            a zeroed RESULTS and fail unless the result is {8, 24}.
            (check_effective_target_arm_v8_2a_i8mm_neon_hw): Likewise.
            (check_effective_target_arm_v8_3a_complex_neon_hw): Use a zero
            addend and expect the first operand.
            * gcc.target/aarch64/pr126592.c: Add -save-temps.

    Signed-off-by: Igor Shevlyakov <[email protected]>

Reply via email to