public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
From: Martin Sebor <msebor@gcc.gnu.org>
To: gcc-cvs@gcc.gnu.org
Subject: [gcc r12-1490] Consider size_t mangling as unsigned int and long [PR100876].
Date: Tue, 15 Jun 2021 18:47:07 +0000 (GMT)	[thread overview]
Message-ID: <20210615184707.9CA0E3857415@sourceware.org> (raw)

https://gcc.gnu.org/g:71790f398e119c7fed867b0cfce60a7500629dff

commit r12-1490-g71790f398e119c7fed867b0cfce60a7500629dff
Author: Martin Sebor <msebor@redhat.com>
Date:   Tue Jun 15 12:42:06 2021 -0600

    Consider size_t mangling as unsigned int and long [PR100876].
    
    gcc/ChangeLog:
    
            PR middle-end/100876
            * builtins.c: (gimple_call_return_array): Account for size_t
            mangling as either unsigned int or unsigned long

Diff:
---
 gcc/builtins.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/gcc/builtins.c b/gcc/builtins.c
index 75419cc4edc..855ad1eb6bb 100644
--- a/gcc/builtins.c
+++ b/gcc/builtins.c
@@ -5183,8 +5183,12 @@ gimple_call_return_array (gimple *stmt, offset_int offrng[2],
 	  || DECL_IS_REPLACEABLE_OPERATOR_NEW_P (fn))
 	return NULL_TREE;
 
+      /* Check the mangling, keeping in mind that operator new takes
+	 a size_t which could be unsigned int or unsigned long.  */
       tree fname = DECL_ASSEMBLER_NAME (fn);
-      if (!id_equal (fname, "_ZnwmPv")       // ordinary form
+      if (!id_equal (fname, "_ZnwjPv")       // ordinary form
+	  && !id_equal (fname, "_ZnwmPv")    // ordinary form
+	  && !id_equal (fname, "_ZnajPv")    // array form
 	  && !id_equal (fname, "_ZnamPv"))   // array form
 	return NULL_TREE;


                 reply	other threads:[~2021-06-15 18:47 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=20210615184707.9CA0E3857415@sourceware.org \
    --to=msebor@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).