public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "cvs-commit at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/98481] [10 Regression] std::vector<std::string>::size_type as return type gets tagged with abi:cxx11
Date: Thu, 01 Apr 2021 11:38:17 +0000	[thread overview]
Message-ID: <bug-98481-4-BluovxHnjv@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-98481-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98481

--- Comment #6 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-10 branch has been updated by Richard Biener
<rguenth@gcc.gnu.org>:

https://gcc.gnu.org/g:892024d4af83b258801ff7484bf28f0cf1a1a999

commit r10-9651-g892024d4af83b258801ff7484bf28f0cf1a1a999
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Thu Apr 1 09:59:47 2021 +0200

    c++, abi: Fix abi_tag attribute handling [PR98481]

    In GCC10 cp_walk_subtrees has been changed to walk template arguments.
    As the following testcase, that changed the mangling of some functions.
    I believe the previous behavior that find_abi_tags_r doesn't recurse into
    template args has been the correct one, but setting *walk_subtrees = 0
    for the types and handling the types subtree walking manually in
    find_abi_tags_r looks too hard, there are a lot of subtrees and details
what
    should and shouldn't be walked, both in tree.c (walk_type_fields there,
    which is static) and in cp_walk_subtrees itself.

    The following patch abuses the fact that *walk_subtrees is an int to
    tell cp_walk_subtrees it shouldn't walk the template args.

    But we don't want to introduce an ABI change in the middle of the GCC 10
    cycle, so the GCC 10 version of this patch introduces ABI v15 for the fix,
    which will be available but not default in GCC 10.3.

    Co-authored-by: Jason Merrill <jason@redhat.com>

    gcc/cp/ChangeLog:

            PR c++/98481
            * class.c (find_abi_tags_r): Set *walk_subtrees to 2 instead of 1
            for types.
            (mark_abi_tags_r): Likewise.
            * tree.c (cp_walk_subtrees): If *walk_subtrees_p is 2, look through
            typedefs.

    gcc/testsuite/ChangeLog:

            PR c++/98481
            * g++.dg/abi/abi-tag24.C: New test.
            * g++.dg/abi/abi-tag24a.C: New test.
            * g++.dg/abi/macro0.C: Adjust expected value.

    gcc/ChangeLog:

            PR c++/98481
            * common.opt (fabi-version): Default to 14.

    gcc/c-family/ChangeLog:

            PR c++/98481
            * c-opts.c (c_common_post_options): Bump latest_abi_version.

  parent reply	other threads:[~2021-04-01 11:38 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-30 17:25 [Bug c++/98481] New: " Daniel.Riley at cornell dot edu
2021-01-05 10:48 ` [Bug c++/98481] [10/11 Regression] " rguenth at gcc dot gnu.org
2021-01-07 11:08 ` jakub at gcc dot gnu.org
2021-01-07 11:13 ` jakub at gcc dot gnu.org
2021-01-07 11:13 ` jakub at gcc dot gnu.org
2021-01-07 11:39 ` jakub at gcc dot gnu.org
2021-01-07 12:01 ` jakub at gcc dot gnu.org
2021-01-11 16:15 ` cvs-commit at gcc dot gnu.org
2021-04-01 11:38 ` cvs-commit at gcc dot gnu.org [this message]
2021-04-01 14:05 ` [Bug c++/98481] [10 " cvs-commit at gcc dot gnu.org
2021-04-05 21:36 ` jason at gcc dot gnu.org

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=bug-98481-4-BluovxHnjv@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@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).