public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/gcc-patches:master commit in: 15.0.0/gentoo/
Date: Fri, 21 Mar 2025 11:20:11 +0000 (UTC)	[thread overview]
Message-ID: <1742555997.ebea0f72bf6bcc9c53105a689beb6263047b35c8.sam@gentoo> (raw)

commit:     ebea0f72bf6bcc9c53105a689beb6263047b35c8
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 21 11:19:57 2025 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Mar 21 11:19:57 2025 +0000
URL:        https://gitweb.gentoo.org/proj/gcc-patches.git/commit/?id=ebea0f72

15.0.0: drop musttail workaround

Jakub's committed several fixes now, so let's see what falls out.

Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../77_all_PR119376-Disable-clang-musttail.patch   | 200 ---------------------
 15.0.0/gentoo/README.history                       |   1 -
 2 files changed, 201 deletions(-)

diff --git a/15.0.0/gentoo/77_all_PR119376-Disable-clang-musttail.patch b/15.0.0/gentoo/77_all_PR119376-Disable-clang-musttail.patch
deleted file mode 100644
index 3af4ab4..0000000
--- a/15.0.0/gentoo/77_all_PR119376-Disable-clang-musttail.patch
+++ /dev/null
@@ -1,200 +0,0 @@
-https://inbox.sourceware.org/gcc-patches/20250320013102.1336516-1-andi@firstfloor.org/
-
-From 592f60bef27cb60ea6405ca8603449fc4d92e640 Mon Sep 17 00:00:00 2001
-Message-ID: <592f60bef27cb60ea6405ca8603449fc4d92e640.1742435883.git.sam@gentoo.org>
-From: Andi Kleen <ak@gcc.gnu.org>
-Date: Wed, 19 Mar 2025 18:31:02 -0700
-Subject: [PATCH] PR119376: Disable clang musttail
-
-There are multiple reports (see PR 119376) now where semantic differences
-in the gcc musttail implementation break existing programs written for the clang
-variant.
-
-Even though that can be all hopefully fixed eventually,
-for the gcc 15 release it seems safer to disable clang::musttail,
-and only keep gnu::musttail.
-
-That means that programs that use __has_c_attribute to check for
-clang::musttail must opt-in explicitly.
-
-Reported-by: Sam James
-
-gcc/c/ChangeLog:
-
-	PR ipa/119376
-	* c-parser.cc (c_parser_handle_musttail): Drop clang namespace
-	check.
-
-gcc/cp/ChangeLog:
-
-	PR ipa/119376
-	* parser.cc (cp_parser_jump_statement): Drop clang namespace
-	check.
-
-gcc/ChangeLog:
-
-	PR ipa/119376
-	* doc/extend.texi: Drop clang::musttail reference.
-
-gcc/testsuite/ChangeLog:
-
-PR ipa/119376
-	* c-c++-common/musttail23.c: Don't use clang::musttail
-	* c-c++-common/musttail24.c: Dito.
-	* c-c++-common/musttail3.c: Dito.
-	* g++.dg/musttail14.C: Dito.
----
- gcc/c/c-parser.cc                       |  5 -----
- gcc/cp/parser.cc                        |  6 ------
- gcc/doc/extend.texi                     |  2 +-
- gcc/testsuite/c-c++-common/musttail23.c | 10 +++++-----
- gcc/testsuite/c-c++-common/musttail24.c |  6 ------
- gcc/testsuite/c-c++-common/musttail3.c  |  6 +++---
- gcc/testsuite/g++.dg/musttail14.C       |  4 ++--
- 7 files changed, 11 insertions(+), 28 deletions(-)
-
-diff --git a/gcc/c/c-parser.cc b/gcc/c/c-parser.cc
-index d49d5c58659f..79654448acaa 100644
---- a/gcc/c/c-parser.cc
-+++ b/gcc/c/c-parser.cc
-@@ -7409,11 +7409,6 @@ c_parser_handle_musttail (c_parser *parser, tree std_attrs, attr_state &attr)
- 	  std_attrs = remove_attribute ("gnu", "musttail", std_attrs);
- 	  attr.musttail_p = true;
- 	}
--      if (lookup_attribute ("clang", "musttail", std_attrs))
--	{
--	  std_attrs = remove_attribute ("clang", "musttail", std_attrs);
--	  attr.musttail_p = true;
--	}
-     }
-   return std_attrs;
- }
-diff --git a/gcc/cp/parser.cc b/gcc/cp/parser.cc
-index 2fb1dc5992d4..da7700b55c64 100644
---- a/gcc/cp/parser.cc
-+++ b/gcc/cp/parser.cc
-@@ -15342,12 +15342,6 @@ cp_parser_jump_statement (cp_parser* parser, tree &std_attrs)
- 		musttail_p = true;
- 		std_attrs = remove_attribute ("gnu", "musttail", std_attrs);
- 	      }
--	    /* Support this for compatibility.  */
--	    if (lookup_attribute ("clang", "musttail", std_attrs))
--	      {
--		musttail_p = true;
--		std_attrs = remove_attribute ("clang", "musttail", std_attrs);
--	      }
- 
- 	    tree ret_expr = expr;
- 	    if (ret_expr && TREE_CODE (ret_expr) == TARGET_EXPR)
-diff --git a/gcc/doc/extend.texi b/gcc/doc/extend.texi
-index b919df914648..50f95e968ff9 100644
---- a/gcc/doc/extend.texi
-+++ b/gcc/doc/extend.texi
-@@ -10241,7 +10241,7 @@ have to optimize it to just @code{return 42 + 42;}.
- @cindex @code{musttail} statement attribute
- @item musttail
- 
--The @code{gnu::musttail} or @code{clang::musttail} standard attribute
-+The @code{gnu::musttail} standard attribute
- or @code{musttail} GNU attribute can be applied to a @code{return} statement
- with a return-value expression that is a function call.  It asserts that the
- call must be a tail call that does not allocate extra stack space, so it is
-diff --git a/gcc/testsuite/c-c++-common/musttail23.c b/gcc/testsuite/c-c++-common/musttail23.c
-index d2ba70b03250..1ceab1165129 100644
---- a/gcc/testsuite/c-c++-common/musttail23.c
-+++ b/gcc/testsuite/c-c++-common/musttail23.c
-@@ -19,10 +19,10 @@ foo (int x)
-     [[gnu::musttail (1, "", 3)]] return bar ();		/* { dg-error "'musttail' attribute does not take any arguments" } */
- 							/* { dg-error "expected" "" { target c } .-1 } */
-   if (x == 3)
--    [[clang::musttail (1)]] return bar ();		/* { dg-error "'musttail' attribute does not take any arguments" } */
-+    [[gnu::musttail (1)]] return bar ();		/* { dg-error "'musttail' attribute does not take any arguments" } */
- 							/* { dg-error "expected" "" { target c } .-1 } */
-   if (x == 4)
--    [[clang::musttail (1, "", 3)]] return bar ();	/* { dg-error "'musttail' attribute does not take any arguments" } */
-+    [[gnu::musttail (1, "", 3)]] return bar ();	/* { dg-error "'musttail' attribute does not take any arguments" } */
- 							/* { dg-error "expected" "" { target c } .-1 } */
-   if (x == 5)
-     __attribute__((fallthrough, musttail)) return bar (); /* { dg-warning "attribute 'musttail' mixed with other attributes on 'return' statement" "" { target c } } */
-@@ -32,14 +32,14 @@ foo (int x)
-     [[fallthrough]] [[gnu::musttail]] return bar ();	/* { dg-warning "'fallthrough' attribute ignored" "" { target c } } */
- 							/* { dg-warning "attributes at the beginning of statement are ignored" "" { target c++ } .-1 } */
-   if (x == 7)
--    [[clang::musttail, fallthrough]] return bar ();	/* { dg-warning "'fallthrough' attribute ignored" "" { target c } } */
-+    [[gnu::musttail, fallthrough]] return bar ();	/* { dg-warning "'fallthrough' attribute ignored" "" { target c } } */
- 							/* { dg-warning "attributes at the beginning of statement are ignored" "" { target c++ } .-1 } */
-   if (x == 8)
-     __attribute__((musttail, musttail)) return bar ();
-   if (x == 9)
-     [[gnu::musttail, gnu::musttail]] return bar ();
-   if (x == 10)
--    [[clang::musttail]] [[clang::musttail]] return bar ();
-+    [[gnu::musttail]] [[gnu::musttail]] return bar ();
-   if (x == 11)
--    [[clang::musttail]] [[gnu::musttail]] return bar ();
-+    [[gnu::musttail]] [[gnu::musttail]] return bar ();
- }
-diff --git a/gcc/testsuite/c-c++-common/musttail24.c b/gcc/testsuite/c-c++-common/musttail24.c
-index 10c2d3f188d8..26b8dbfb4c8e 100644
---- a/gcc/testsuite/c-c++-common/musttail24.c
-+++ b/gcc/testsuite/c-c++-common/musttail24.c
-@@ -8,14 +8,8 @@
- #if !__has_cpp_attribute (gnu::musttail)
- #error missing gnu::musttail attribute
- #endif
--#if !__has_cpp_attribute (clang::musttail)
--#error missing clang::musttail attribute
--#endif
- #else
- #if !__has_c_attribute (gnu::musttail)
- #error missing gnu::musttail attribute
- #endif
--#if !__has_c_attribute (clang::musttail)
--#error missing clang::musttail attribute
--#endif
- #endif
-diff --git a/gcc/testsuite/c-c++-common/musttail3.c b/gcc/testsuite/c-c++-common/musttail3.c
-index 7499fd6460b4..daedca28852a 100644
---- a/gcc/testsuite/c-c++-common/musttail3.c
-+++ b/gcc/testsuite/c-c++-common/musttail3.c
-@@ -11,7 +11,7 @@ struct str
- cstruct (int x)
- {
-   if (x < 10)
--    [[clang::musttail]] return cstruct (x + 1);
-+    [[gnu::musttail]] return cstruct (x + 1);
-   return ((struct str){ x, 0 });
- }
- 
-@@ -19,11 +19,11 @@ int
- foo (int x)
- {
-   if (x < 10)
--    [[clang::musttail]] return foo2 (x, 29);
-+    [[gnu::musttail]] return foo2 (x, 29);
-   if (x < 100)
-     {
-       int k = foo (x + 1);
--      [[clang::musttail]] return k;	/* { dg-error "cannot tail-call: " } */
-+      [[gnu::musttail]] return k;	/* { dg-error "cannot tail-call: " } */
-     }
-   return x;
- }
-diff --git a/gcc/testsuite/g++.dg/musttail14.C b/gcc/testsuite/g++.dg/musttail14.C
-index 810b45546d61..e4764a3bc03b 100644
---- a/gcc/testsuite/g++.dg/musttail14.C
-+++ b/gcc/testsuite/g++.dg/musttail14.C
-@@ -58,8 +58,8 @@ garply (int x)
-     case 3:
-       __attribute__(()) [[gnu::musttail]] __attribute__(()) [[]] __attribute__(()) return qux (45);
-     case 4:
--      [[]] __attribute__(()) [[clang::musttail]] __attribute__(()) [[]] return corge (46);
-+      [[]] __attribute__(()) [[gnu::musttail]] __attribute__(()) [[]] return corge (46);
-     default:
--      __attribute__(()) [[clang::musttail]] __attribute__(()) [[]] __attribute__(()) return freddy (47);
-+      __attribute__(()) [[gnu::musttail]] __attribute__(()) [[]] __attribute__(()) return freddy (47);
-     }
- }
--- 
-2.49.0
-

diff --git a/15.0.0/gentoo/README.history b/15.0.0/gentoo/README.history
index c3b9934..5543b1c 100644
--- a/15.0.0/gentoo/README.history
+++ b/15.0.0/gentoo/README.history
@@ -1,6 +1,5 @@
 48	????
 
-	+ 77_all_PR119376-Disable-clang-musttail.patch
 	+ 78_all_PR118615.patch
 	+ 79_all_PR117811-arm-neon-shift.patch
 


             reply	other threads:[~2025-03-21 11:20 UTC|newest]

Thread overview: 184+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-21 11:20 Sam James [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-03-26  6:25 [gentoo-commits] proj/gcc-patches:master commit in: 15.0.0/gentoo/ Sam James
2025-03-25 10:27 Sam James
2025-03-25  8:38 Sam James
2025-03-25  2:32 Sam James
2025-03-25  1:27 Sam James
2025-03-24  0:35 Sam James
2025-03-21 19:31 Sam James
2025-03-21 17:21 Sam James
2025-03-21 16:23 Sam James
2025-03-21  8:51 Sam James
2025-03-21  6:07 Sam James
2025-03-20 22:08 Sam James
2025-03-20  1:59 Sam James
2025-03-20  1:59 Sam James
2025-03-16 22:37 Sam James
2025-03-14 14:46 Sam James
2025-03-14 13:37 Sam James
2025-03-13 16:48 Sam James
2025-03-13 10:08 Sam James
2025-03-11 10:32 Sam James
2025-03-07 16:54 Sam James
2025-03-03 16:38 Sam James
2025-03-01 10:33 Sam James
2025-03-01  6:50 Sam James
2025-02-17  1:30 Sam James
2025-02-13  9:23 Sam James
2025-02-12 15:12 Sam James
2025-02-10 21:22 Sam James
2025-02-09 23:58 Sam James
2025-02-07 23:37 Sam James
2025-02-07 21:19 Sam James
2025-02-03 22:04 Sam James
2025-02-02 22:41 Sam James
2025-01-29 20:21 Sam James
2025-01-26 22:52 Sam James
2025-01-22 16:27 Sam James
2025-01-19 22:43 Sam James
2025-01-16 23:11 Sam James
2025-01-16 23:11 Sam James
2025-01-15 11:41 Sam James
2025-01-14 16:22 Sam James
2025-01-14 15:06 Sam James
2025-01-14 15:06 Sam James
2025-01-14 12:29 Sam James
2025-01-14  8:43 Sam James
2025-01-14  8:40 Sam James
2025-01-13 13:58 Sam James
2025-01-13  6:00 Sam James
2025-01-13  3:40 Sam James
2025-01-13  3:23 Sam James
2025-01-13  3:20 Sam James
2025-01-13  0:20 Sam James
2025-01-12 18:53 Sam James
2025-01-11 12:53 Sam James
2025-01-08 21:51 Sam James
2025-01-06 10:50 Sam James
2025-01-06 10:03 Sam James
2025-01-06  4:49 Sam James
2025-01-06  4:44 Sam James
2025-01-06  4:13 Sam James
2025-01-06  4:13 Sam James
2025-01-06  4:13 Sam James
2025-01-06  4:03 Sam James
2025-01-05 23:19 Sam James
2025-01-03  3:07 Sam James
2024-12-30  1:05 Sam James
2024-12-29 10:00 Sam James
2024-12-27 15:14 Sam James
2024-12-24 20:48 Sam James
2024-12-22 22:46 Sam James
2024-12-20 11:25 Sam James
2024-12-20  5:57 Sam James
2024-12-20  1:55 Sam James
2024-12-19 18:34 Sam James
2024-12-13 13:23 Sam James
2024-12-13 11:52 Sam James
2024-12-13  5:08 Sam James
2024-12-12 12:28 Sam James
2024-12-11  4:41 Sam James
2024-12-11  0:58 Sam James
2024-12-10 19:19 Sam James
2024-12-10 14:55 Sam James
2024-12-10  5:19 Sam James
2024-12-10  5:13 Sam James
2024-12-10  5:11 Sam James
2024-12-10  5:07 Sam James
2024-12-09  3:05 Sam James
2024-12-08 22:41 Sam James
2024-12-06 17:33 Sam James
2024-12-04 20:40 Sam James
2024-12-01 22:51 Sam James
2024-12-01 22:51 Sam James
2024-11-30 11:30 Sam James
2024-11-27 17:42 Sam James
2024-11-25 15:10 Sam James
2024-11-25  3:01 Sam James
2024-11-25  3:00 Sam James
2024-11-25  3:00 Sam James
2024-11-24 22:42 Sam James
2024-11-18 17:25 Sam James
2024-11-18 10:42 Sam James
2024-11-18 10:42 Sam James
2024-11-18  9:25 Sam James
2024-11-18  9:25 Sam James
2024-11-14 18:38 Sam James
2024-11-13  4:26 Sam James
2024-11-13  0:16 Sam James
2024-11-12  2:33 Sam James
2024-11-11 19:46 Sam James
2024-11-11 19:46 Sam James
2024-11-10 22:41 Sam James
2024-11-09 16:24 Sam James
2024-11-09  7:55 Sam James
2024-11-08  8:22 Sam James
2024-11-07 16:13 Sam James
2024-11-03 23:16 Sam James
2024-11-01  8:24 Sam James
2024-11-01  8:24 Sam James
2024-11-01  8:18 Sam James
2024-11-01  8:17 Sam James
2024-10-30 16:03 Sam James
2024-10-29 19:17 Sam James
2024-10-28 21:32 Sam James
2024-10-28  8:09 Sam James
2024-10-23 15:40 Sam James
2024-10-22 19:09 Sam James
2024-10-22 18:34 Sam James
2024-10-21 12:33 Sam James
2024-10-21 12:27 Sam James
2024-10-21 12:26 Sam James
2024-10-21 11:45 Sam James
2024-10-20 22:42 Sam James
2024-10-18 14:05 Sam James
2024-10-18 10:35 Sam James
2024-10-17 23:33 Sam James
2024-10-17 23:03 Sam James
2024-10-17  5:01 Sam James
2024-10-17  4:15 Sam James
2024-10-13 22:48 Sam James
2024-10-07  2:45 Sam James
2024-10-04 10:37 Sam James
2024-10-04  9:28 Sam James
2024-10-02 19:45 Sam James
2024-09-30 14:05 Sam James
2024-09-29 22:56 Sam James
2024-09-24  1:41 Sam James
2024-09-23 15:23 Sam James
2024-09-02  2:28 Sam James
2024-08-26 13:44 Sam James
2024-08-26  6:24 Sam James
2024-08-23 13:51 Sam James
2024-08-20 20:31 Sam James
2024-08-19 18:43 Sam James
2024-08-14  9:48 Sam James
2024-08-14  2:57 Sam James
2024-08-11 22:40 Sam James
2024-08-09 19:54 Sam James
2024-08-09 19:54 Sam James
2024-08-09 19:47 Sam James
2024-08-09 19:25 Sam James
2024-08-08 11:10 Sam James
2024-08-08 11:06 Sam James
2024-08-08 11:03 Sam James
2024-08-05  9:09 Sam James
2024-08-05  1:54 Sam James
2024-08-05  1:51 Sam James
2024-08-02 20:39 Sam James
2024-08-01 14:40 Sam James
2024-07-28 23:34 Sam James
2024-07-22  1:11 Sam James
2024-07-19 11:14 Sam James
2024-07-18  0:45 Sam James
2024-07-14 23:36 Sam James
2024-06-28 12:49 Sam James
2024-06-27  0:02 Sam James
2024-06-26 23:57 Sam James
2024-06-16 22:45 Sam James
2024-06-10 20:18 Sam James
2024-06-10 17:28 Sam James
2024-06-10 17:28 Sam James
2024-06-10  2:08 Sam James
2024-06-08 17:03 Sam James
2024-06-08 17:03 Sam James

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=1742555997.ebea0f72bf6bcc9c53105a689beb6263047b35c8.sam@gentoo \
    --to=sam@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.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