https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116461
Kewen Lin <linkw at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Ever confirmed|0 |1
Status|UNCONFIRMED |ASSIGNED
CC| |linkw at gcc dot gnu.org
Last reconfirmed| |2024-08-23
Assignee|unassigned at gcc dot gnu.org |linkw at gcc dot gnu.org
--- Comment #1 from Kewen Lin <linkw at gcc dot gnu.org> ---
Confirmed, this is a test case issue:
When i = 29, a[i] is 19, b[i] is 0, a[i]%b[i] is performing "% 0".
vmodsw (Vector Modulo Signed Word) says:
If an attempt is made to perform any of the modulo operations
...
<anything> % 0
then the remainder is undefined.
Similarly for scalar side, which adopts divw/mullw/subf, divw has:
If an attempt is made to perform any of the divisions
...
<anything> / 0
then the contents of register RT are undefined.
Here we unfortunately gets 0 from vmodsw while 19 from the scalar sequence, so
the abortion occurs.