public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc(refs/users/kubaneko/heads/histogram)] Fix use of estimates.
@ 2023-05-01 22:19 Jan Hubicka
  0 siblings, 0 replies; only message in thread
From: Jan Hubicka @ 2023-05-01 22:19 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:e3bc373e2bf65039a7f5f11a2b49a742ac1caa09

commit e3bc373e2bf65039a7f5f11a2b49a742ac1caa09
Author: Honza <jh@ryzen3.suse.cz>
Date:   Tue May 2 00:18:57 2023 +0200

    Fix use of estimates.

Diff:
---
 gcc/tree-vect-loop.cc | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/gcc/tree-vect-loop.cc b/gcc/tree-vect-loop.cc
index 140bafad28c..ba068af264c 100644
--- a/gcc/tree-vect-loop.cc
+++ b/gcc/tree-vect-loop.cc
@@ -2109,9 +2109,10 @@ vect_analyze_loop_costing (loop_vec_info loop_vinfo,
   if (LOOP_VINFO_EPILOGUE_P (loop_vinfo))
     estimated_niter
       = vect_vf_for_cost (LOOP_VINFO_ORIG_LOOP_INFO (loop_vinfo)) - 1;
-  else if (use_estimate)
+  else
     {
-      estimated_niter = estimated_stmt_executions_int (loop);
+      if (use_estimate)
+	estimated_niter = estimated_stmt_executions_int (loop);
       if (estimated_niter == -1)
 	estimated_niter = likely_max_stmt_executions_int (loop);
     }

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-05-01 22:19 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-05-01 22:19 [gcc(refs/users/kubaneko/heads/histogram)] Fix use of estimates Jan Hubicka

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).