public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc(refs/users/guojiufu/heads/guojiufu-branch)] tree_int_cst_equal compare cst tree
@ 2021-06-09  5:27 Jiu Fu Guo
  0 siblings, 0 replies; only message in thread
From: Jiu Fu Guo @ 2021-06-09  5:27 UTC (permalink / raw)
  To: gcc-cvs

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

commit de3900d5d34f1f5f83e41293d0efc13fcc0b9033
Author: Jiufu Guo <guojiufu@linux.ibm.com>
Date:   Thu Jun 3 21:05:48 2021 +0800

    tree_int_cst_equal compare cst tree

Diff:
---
 gcc/tree-ssa-loop-split.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gcc/tree-ssa-loop-split.c b/gcc/tree-ssa-loop-split.c
index fa79c257167..44bb8056b5b 100644
--- a/gcc/tree-ssa-loop-split.c
+++ b/gcc/tree-ssa-loop-split.c
@@ -1639,8 +1639,8 @@ get_ne_cond_branch (struct loop *loop)
       /* Avoid to split if bound is MAX/MIN val.  */
       tree bound_type = TREE_TYPE (bnd);
       if (TREE_CODE (bnd) == INTEGER_CST && INTEGRAL_TYPE_P (bound_type)
-	  && (bnd == TYPE_MAX_VALUE (bound_type)
-	      || bnd == TYPE_MIN_VALUE (bound_type)))
+	  && (tree_int_cst_equal (bnd, TYPE_MAX_VALUE (bound_type))
+	      || tree_int_cst_equal (bnd, TYPE_MIN_VALUE (bound_type))))
 	continue;
 
       /* Check if there is possible wrap.  */


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

only message in thread, other threads:[~2021-06-09  5:27 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-09  5:27 [gcc(refs/users/guojiufu/heads/guojiufu-branch)] tree_int_cst_equal compare cst tree Jiu Fu Guo

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