rs6000-c.c (altivec_overloaded_builtins): Add support for builtins...
authorCarl Love <cel@us.ibm.com>
Mon, 13 Nov 2017 19:26:54 +0000 (19:26 +0000)
committerCarl Love <carll@gcc.gnu.org>
Mon, 13 Nov 2017 19:26:54 +0000 (19:26 +0000)
commit4d85d480272fb7331924f04534e0f5f14b60421e
treec3c740cbf79182bf1451b5f3b38473dc7984a6d2
parent846b84fba76e47260018d9f018b6491d53b96732
rs6000-c.c (altivec_overloaded_builtins): Add support for builtins...

gcc/ChangeLog:

2017-11-13  Carl Love  <cel@us.ibm.com>

* config/rs6000/rs6000-c.c (altivec_overloaded_builtins):
Add support for builtins:
unsigned int vec_first_{,miss}_match_{,or_eos}index,
vector {un,}signed {char,int,short},
vector {un,}signed {char,int,short}) arguments.
* config/rs6000/rs6000-builtin.def (VFIRSTMATCHINDEX,
VFIRSTMATCHOREOSINDEX, VFIRSTMISMATCHINDEX, VFIRSTMISMATCHOREOSINDEX):
Add BU_P9V_AV_2 expansions for the builtins.
* config/rs6000/altivec.h (vec_first_match_index,
vec_first_mismatch_index, vec_first_match_or_eos_index,
vec_first_mismatch_or_eos_index): Add #defines for the builtins.
* config/rs6000/rs6000-protos.h (bytes_in_mode): Add
new extern declaration.
* config/rs6000/rs6000.c (bytes_in_mode): Add new function.
* config/rs6000/vsx.md (first_match_index_<mode>,
first_match_or_eos_index_<mode>, first_mismatch_index_<mode>,
first_mismatch_or_eos_index_<mode>): Add define expand.
(vctzlsbb_<mode>): Add mode field to define_insn for vctzlsbb.
* doc/extend.texi: Update the built-in documenation file for the new
built-in functions.

gcc/testsuite/ChangeLog:

2017-11-13  Carl Love  <cel@us.ibm.com>

* gcc.target/powerpc/builtins-6-p9-runnable.c: Add new runnable test.
* gcc.target/powerpc/vsu/vec-cnttz-lsbb-2.c: Update expected error
message.

From-SVN: r254704
gcc/ChangeLog
gcc/config/rs6000/altivec.h
gcc/config/rs6000/rs6000-builtin.def
gcc/config/rs6000/rs6000-c.c
gcc/config/rs6000/vsx.md
gcc/doc/extend.texi
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/powerpc/builtins-6-p9-runnable.c [new file with mode: 0644]
gcc/testsuite/gcc.target/powerpc/vsu/vec-cnttz-lsbb-2.c