[Bug target/81143] New test case gcc.target/powerpc/pr79799-2.c fails on powerpc BE
bergner at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Feb 8 20:32:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81143
Peter Bergner <bergner at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |ASSIGNED
Last reconfirmed| |2018-02-08
CC| |bergner at gcc dot gnu.org
Assignee|unassigned at gcc dot gnu.org |bergner at gcc dot gnu.org
Ever confirmed|0 |1
--- Comment #1 from Peter Bergner <bergner at gcc dot gnu.org> ---
This is a test case bug. The problem is the following code:
#if __ORDER_LITTLE_ENDIAN__
#define ELE 2
#else
#define ELE 1
#endif
vector float
foo (vector float v1, vector float v2)
{
return vec_insert (vec_extract (v2, ELE), v1, 0);
}
The bug is that __ORDER_LITTLE_ENDIAN__ is always defined, so we pass the wrong
ELE value to vec_extract() call on big endian. We should be testing
__LITTLE_ENDIAN__ instead. Changing that fixes the failure.
More information about the Gcc-bugs
mailing list