public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc r12-4604] tree-optimization/102847 - adjust VMAT_INVARIANT load costing
@ 2021-10-21 11:04 Richard Biener
0 siblings, 0 replies; only message in thread
From: Richard Biener @ 2021-10-21 11:04 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:8516963942b0a8f06fa8f5ebd7c37f9edea151ac
commit r12-4604-g8516963942b0a8f06fa8f5ebd7c37f9edea151ac
Author: Richard Biener <rguenther@suse.de>
Date: Thu Oct 21 12:10:20 2021 +0200
tree-optimization/102847 - adjust VMAT_INVARIANT load costing
This adds the missing scalar load cost in the prologue.
2021-10-21 Richard Biener <rguenther@suse.de>
PR tree-optimization/102847
* tree-vect-stmts.c (vect_model_load_cost): Add the scalar
load cost in the prologue for VMAT_INVARIANT.
Diff:
---
gcc/tree-vect-stmts.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/gcc/tree-vect-stmts.c b/gcc/tree-vect-stmts.c
index 8f527452bd0..c28c9370655 100644
--- a/gcc/tree-vect-stmts.c
+++ b/gcc/tree-vect-stmts.c
@@ -1194,6 +1194,9 @@ vect_model_load_cost (vec_info *vinfo,
else if (memory_access_type == VMAT_INVARIANT)
{
/* Invariant loads will ideally be hoisted and splat to a vector. */
+ prologue_cost += record_stmt_cost (cost_vec, 1,
+ scalar_load, stmt_info, 0,
+ vect_prologue);
prologue_cost += record_stmt_cost (cost_vec, 1,
scalar_to_vec, stmt_info, 0,
vect_prologue);
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2021-10-21 11:04 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-21 11:04 [gcc r12-4604] tree-optimization/102847 - adjust VMAT_INVARIANT load costing Richard Biener
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).