Skip to content
Snippets Groups Projects
Commit feebc22b authored by Richard Biener's avatar Richard Biener
Browse files

Maintain (mis-)alignment info in the first element of a group

This changes us to maintain and compute (mis-)alignment info for
the first element of a group only rather than for each DR when
doing interleaving and for the earliest, first, or first in the SLP
node (or any pair or all three of those) when SLP vectorizing.

For this to work out the easiest way I have changed the accessors
DR_MISALIGNMENT and DR_TARGET_ALIGNMENT to do the indirection to
the first element rather than adjusting all callers.

2021-09-13  Richard Biener  <rguenther@suse.de>

	* tree-vectorizer.h (dr_misalignment): Move out of line.
	(dr_target_alignment): New.
	(DR_TARGET_ALIGNMENT): Wrap dr_target_alignment.
	(set_dr_target_alignment): New.
	(SET_DR_TARGET_ALIGNMENT): Wrap set_dr_target_alignment.
	* tree-vect-data-refs.c (dr_misalignment): Compute and
	return the group members misalignment.
	(vect_compute_data_ref_alignment): Use SET_DR_TARGET_ALIGNMENT.
	(vect_analyze_data_refs_alignment): Compute alignment only
	for the first element of a DR group.
	(vect_slp_analyze_node_alignment): Likewise.
parent e4d36433
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment