Go to file
Richard Sandiford f095523350 Add a targetm.vectorize.related_mode hook
This patch is the first of a series that tries to remove two
assumptions:

(1) that all vectors involved in vectorisation must be the same size

(2) that there is only one vector mode for a given element mode and
    number of elements

Relaxing (1) helps with targets that support multiple vector sizes or
that require the number of elements to stay the same.  E.g. if we're
vectorising code that operates on narrow and wide elements, and the
narrow elements use 64-bit vectors, then on AArch64 it would normally
be better to use 128-bit vectors rather than pairs of 64-bit vectors
for the wide elements.

Relaxing (2) makes it possible for -msve-vector-bits=128 to produce
fixed-length code for SVE.  It also allows unpacked/half-size SVE
vectors to work with -msve-vector-bits=256.

The patch adds a new hook that targets can use to control how we
move from one vector mode to another.  The hook takes a starting vector
mode, a new element mode, and (optionally) a new number of elements.
The flexibility needed for (1) comes in when the number of elements
isn't specified.

All callers in this patch specify the number of elements, but a later
vectoriser patch doesn't.

2019-11-14  Richard Sandiford  <richard.sandiford@arm.com>

gcc/
	* target.def (related_mode): New hook.
	* doc/tm.texi.in (TARGET_VECTORIZE_RELATED_MODE): New hook.
	* doc/tm.texi: Regenerate.
	* targhooks.h (default_vectorize_related_mode): Declare.
	* targhooks.c (default_vectorize_related_mode): New function.
	* machmode.h (related_vector_mode): Declare.
	* stor-layout.c (related_vector_mode): New function.
	* expmed.c (extract_bit_field_1): Use it instead of mode_for_vector.
	* optabs-query.c (qimode_for_vec_perm): Likewise.
	* tree-vect-stmts.c (get_group_load_store_type): Likewise.
	(vectorizable_store, vectorizable_load): Likewise

From-SVN: r278229
2019-11-14 14:36:26 +00:00
config
contrib download_prerequisites: Use http instead of ftp for downloading. 2019-11-13 19:48:52 +02:00
fixincludes
gcc Add a targetm.vectorize.related_mode hook 2019-11-14 14:36:26 +00:00
gnattools
gotools libgo: update to Go 1.13beta1 release 2019-09-06 18:12:46 +00:00
include GCN libgomp port 2019-11-13 12:38:04 +00:00
INSTALL
intl
libada
libatomic
libbacktrace
libcc1
libcpp PR c++/91370 - Implement P1041R4 and P1139R2 - Stronger Unicode reqs 2019-11-07 21:24:38 +01:00
libdecnumber Update copyright years. 2019-01-01 13:31:55 +01:00
libffi Regenerate configure' scripts for uclinuxfdpiceabi' libtool.m4 update 2019-09-27 21:24:42 +00:00
libgcc Support 64-bit double and 64-bit long double configurations. 2019-11-07 09:19:31 +00:00
libgfortran PR fortran/92470 Fixes for CFI_address 2019-11-13 12:13:57 +01:00
libgo libgo: fix DejaGNU testsuite compiler when using build sysroot 2019-11-11 23:28:54 +00:00
libgomp GCN Libgomp Plugin 2019-11-13 12:38:18 +00:00
libhsail-rt
libiberty PR c++/91979 - mangling nullptr expression 2019-11-04 18:24:25 -05:00
libitm
libobjc
liboffloadmic
libphobos
libquadmath
libsanitizer Enable libsanitizer build on riscv64 2019-11-13 09:45:15 +00:00
libssp
libstdc++-v3 libsupc++: Implement comparison algorithms for C++20 2019-11-13 16:26:18 +00:00
libvtv
lto-plugin
maintainer-scripts update_version_svn (IGNORE_BRANCHES): Add 7. 2019-11-14 07:41:56 +00:00
zlib
.dir-locals.el
.gitattributes
.gitignore
ABOUT-NLS
ar-lib
ChangeLog Bump minimum MPFR version to 3.1.0 2019-11-11 17:59:48 +02:00
ChangeLog.jit
ChangeLog.tree-ssa
compile
config-ml.in
config.guess
config.rpath
config.sub
configure Bump minimum MPFR version to 3.1.0 2019-11-11 17:59:48 +02:00
configure.ac Bump minimum MPFR version to 3.1.0 2019-11-11 17:59:48 +02:00
COPYING
COPYING3
COPYING3.LIB
COPYING.LIB
COPYING.RUNTIME
depcomp
install-sh Update from upstream Automake files. 2014-11-16 14:07:13 +00:00
libtool-ldflags
libtool.m4
lt~obsolete.m4
ltgcc.m4
ltmain.sh
ltoptions.m4
ltsugar.m4
ltversion.m4
MAINTAINERS
Makefile.def
Makefile.in
Makefile.tpl
missing
mkdep
mkinstalldirs
move-if-change
multilib.am
README
symlink-tree
test-driver
ylwrap

This directory contains the GNU Compiler Collection (GCC).

The GNU Compiler Collection is free software.  See the files whose
names start with COPYING for copying permission.  The manuals, and
some of the runtime libraries, are under different terms; see the
individual source files for details.

The directory INSTALL contains copies of the installation information
as HTML and plain text.  The source of this information is
gcc/doc/install.texi.  The installation information includes details
of what is included in the GCC sources and what files GCC installs.

See the file gcc/doc/gcc.texi (together with other files that it
includes) for usage and porting information.  An online readable
version of the manual is in the files gcc/doc/gcc.info*.

See http://gcc.gnu.org/bugs/ for how to report bugs usefully.

Copyright years on GCC source files may be listed using range
notation, e.g., 1987-2012, indicating that every year in the range,
inclusive, is a copyrightable year that could otherwise be listed
individually.