PR68577: Handle narrowing for vector popcount, etc.
This patch adds support for simple cases where a vector internal function returns wider results than the scalar equivalent. It punts on other cases. Tested on powerpc64-linux-gnu and x86_64-linux-gnu. gcc/ PR tree-optimization/68577 * tree-vect-stmts.c (simple_integer_narrowing): New function. (vectorizable_call): Restrict internal function handling to NONE and NARROW cases, using simple_integer_narrowing to test for the latter. Add cost of narrowing operation and insert it where necessary. gcc/testsuite/ PR tree-optimization/68577 * gcc.dg/vect/pr68577.c: New test. From-SVN: r231131
Showing
gcc/testsuite/gcc.dg/vect/pr68577.c
0 → 100644
Please
register
or
sign in
to comment