public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
From: Aldy Hernandez <aldyh@gcc.gnu.org>
To: gcc-cvs@gcc.gnu.org
Subject: [gcc r13-3420] [PR c++/106654] Handle non-irange ranges in get_range_global for default defs.
Date: Thu, 20 Oct 2022 19:43:40 +0000 (GMT)	[thread overview]
Message-ID: <20221020194340.245673865C2A@sourceware.org> (raw)

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

commit r13-3420-gd155442de043c1bef7d27cf2d6be4eba618afcb9
Author: Aldy Hernandez <aldyh@redhat.com>
Date:   Thu Oct 20 18:26:42 2022 +0200

    [PR c++/106654] Handle non-irange ranges in get_range_global for default defs.
    
    With the upcoming [[assume]] work, Andrew has pointed out that
    non-irange ranges are not handled in get_range_global for
    SSA_NAME_IS_DEFAULT_DEF.  This patch fixes the oversight.
    
            PR c++/106654
    
    gcc/ChangeLog:
    
            * value-query.cc (get_range_global): Handle non integer ranges for
            default def SSA names.

Diff:
---
 gcc/value-query.cc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gcc/value-query.cc b/gcc/value-query.cc
index 296784be31d..e8988ed67e0 100644
--- a/gcc/value-query.cc
+++ b/gcc/value-query.cc
@@ -343,7 +343,7 @@ get_range_global (vrange &r, tree name)
 	      && ((cfun && nonnull_arg_p (sym))
 		  || get_ssa_name_ptr_info_nonnull (name)))
 	    r.set_nonzero (type);
-	  else if (INTEGRAL_TYPE_P (type))
+	  else if (!POINTER_TYPE_P (type))
 	    {
 	      get_ssa_name_range_info (r, name);
 	      if (r.undefined_p ())

                 reply	other threads:[~2022-10-20 19:43 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20221020194340.245673865C2A@sourceware.org \
    --to=aldyh@gcc.gnu.org \
    --cc=gcc-cvs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).