Re: [PATCH] c++/modules: Ensure deduction guides are always reachable [PR115231]

2024-06-15 Thread Nathaniel Shead
On Sun, Jun 16, 2024 at 12:29:23PM +1000, Nathaniel Shead wrote: > Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? > > This probably isn't the most efficient approach, since we need to do > name lookup to find deduction guides for a type which will also > potentially do a bunch of

[PATCH v5] gcc, libcpp: Add warning switch for "#pragma once in main file" [PR89808]

2024-06-15 Thread Ken Matsui
This patch adds a warning switch for "#pragma once in main file". The warning option name is Wpragma-once-outside-header, which is the same as Clang provides. PR preprocessor/89808 gcc/c-family/ChangeLog: * c.opt (Wpragma_once_outside_header): Define new option. * c.opt.

[committed] Fix minor SH scan-asm failure after recent IOR->ADD changes

2024-06-15 Thread Jeff Law
This fixes minor fallout from the IOR->ADD change for rotates that I installed a little while ago. Basically the SH backend has a special pattern for setting the T register that has elements similar to a rotate. With the IOR->ADD change that pattern no longer matches and we get scan-asm failu

[PATCH] c++/modules: Ensure deduction guides are always reachable [PR115231]

2024-06-15 Thread Nathaniel Shead
Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? This probably isn't the most efficient approach, since we need to do name lookup to find deduction guides for a type which will also potentially do a bunch of pointless lazy loading from imported modules, but I wasn't able to work ou

[PATCH] c++: Simplify uses of LAMBDA_EXPR_EXTRA_SCOPE

2024-06-15 Thread Nathaniel Shead
No functional change intended; OK for trunk? -- >8 -- I noticed there already exists a getter to get the scope of a lambda from its type directly rather than needing to go via CLASSTYPE_LAMBDA_EXPR, we may as well use it. gcc/cp/ChangeLog: * module.cc (trees_out::get_merge_kind): Use

Re: [PATCH v3 1/3] diagnostics: Enable escape sequence processing on windows consoles

2024-06-15 Thread Jonathan Yong
On 6/3/24 17:07, Peter Damianov wrote: Since windows 10 release v1511, the windows console has had support for VT100 escape sequences. We should try to enable this, and utilize it where possible. Thank you. Patches look good to me, pushed to master branch.

[PATCH v4] gcc, libcpp: Add warning switch for "#pragma once in main file" [PR89808]

2024-06-15 Thread Ken Matsui
This patch adds a warning switch for "#pragma once in main file". The warning option name is Wpragma-once-outside-header, which is the same as Clang provides. PR preprocessor/89808 gcc/c-family/ChangeLog: * c.opt (Wpragma_once_outside_header): Define new option. * c.opt.

Re: [PATCH v3] gcc, libcpp: Add warning switch for "#pragma once in main file" [PR89808]

2024-06-15 Thread Ken Matsui
On Thu, Jun 13, 2024 at 7:44 AM Jason Merrill wrote: > > On 6/13/24 10:31, Ken Matsui wrote: > > This patch adds a warning switch for "#pragma once in main file". The > > warning option name is Wpragma-once-outside-header, which is the same > > as Clang. > > > > PR preprocessor/89808 > > >

Re: [PATCH] libstdc++: Fix build for AVR [PR115481, PR111639]

2024-06-15 Thread Detlef Vollmann
On 6/15/24 10:30, Georg-Johann Lay wrote: Am 14.06.24 um 21:11 schrieb Detlef Vollmann: I actually plan anyway to run a test with the built libstdc++ on simulavr. As an aside, simulavr tries to simulate an exact match of the hardware including internal I/O like timers, IRQs, etc. For GCC reg

Re: [PATCH] DOCUMENTATION_ROOT_URL vs. release branches [PR114738]

2024-06-15 Thread Jakub Jelinek
On Sat, Jun 15, 2024 at 09:47:04PM +0200, Gerald Pfeifer wrote: > There should be *very* few user visible changes such as new options or > substantially different behaviors on release branches - pretty much by > definition. In reality there are tons of changes, people add new options even on rel

Re: [PATCH] DOCUMENTATION_ROOT_URL vs. release branches [PR114738]

2024-06-15 Thread Gerald Pfeifer
On Tue, 23 Apr 2024, David Malcolm wrote: > My hope is that the URL suffixes don't change: we shouldn't be adding > new command-line options on the release branches, and I'd hope that > texinfo doesn't change the generated anchors from run to run. Already before this thread, but definitely now, I

Re: [PATCH v1] RISC-V: Add testcases for vector unsigned SAT_SUB form 2

2024-06-15 Thread Jeff Law
On 6/15/24 6:56 AM, pan2...@intel.com wrote: From: Pan Li The previous RISC-V backend .SAT_SUB enabling patch missed the form 2 testcases of vector modes. Aka: Form 2: #define DEF_VEC_SAT_U_SUB_FMT_2(T) \ void __attribute__((noinline))

[PATCH v2] LoongArch: Tweak IOR rtx_cost for bstrins

2024-06-15 Thread Xi Ruoyao
Consider c &= 0xfff; a &= ~0xfff; b &= ~0xfff; a |= c; b |= c; This can be done with 2 bstrins instructions. But we need to recognize it in loongarch_rtx_costs or the compiler will not propagate "c & 0xfff" forward. gcc/ChangeLog: * config/loongarch/loongarch.cc:

Re: [C PATCH, v3] Fix for redeclared enumerator initialized with different type [PR115109]

2024-06-15 Thread Martin Uecker
The patch fails on arm because the tests make assumptions about enums that are not true everywhere. Should we just  limit the tests to x86? Martin Am Montag, dem 03.06.2024 um 17:37 + schrieb Joseph Myers: > On Sat, 1 Jun 2024, Martin Uecker wrote: > > > This is a new version of the patch.

Re: [PATCH] LoongArch: Tweak IOR rtx_cost for bstrins

2024-06-15 Thread Xi Ruoyao
On Sat, 2024-06-15 at 21:44 +0800, Xi Ruoyao wrote: > +     for (int i = 0; i < 2; i++) > +   *total += set_src_cost (XEXP (op0, i), mode, > speed); Oops this is wrong. I need to fix this and regtest again. -- Xi Ruoyao School of Aerospace Science and Technology, Xi

[PATCH] LoongArch: Only transform move/move/bstrins to srai/bstrins when -Os

2024-06-15 Thread Xi Ruoyao
The first form has a lower latency (due to the special handling of "move" in LA464 and LA664) despite it's longer. gcc/ChangeLog: * config/loongarch/loongarch.md (define_peephole2): Require optimize_insn_for_size_p () for move/move/bstrins => srai/bstrins transform. --- B

[PATCH] LoongArch: Tweak IOR rtx_cost for bstrins

2024-06-15 Thread Xi Ruoyao
Consider c &= 0xfff; a &= ~0xfff; b &= ~0xfff; a |= c; b |= c; This can be done with 2 bstrins instructions. But we need to recognize it in loongarch_rtx_costs or the compiler will not propagate "c & 0xfff" forward. gcc/ChangeLog: * config/loongarch/loongarch.cc:

Re: [PATCH] libstdc++: Do not use memset _Hashtable buckets allocation

2024-06-15 Thread François Dumont
Here is the simplified patch then.     libstdc++: Do not use memset in _Hashtable buckets allocation     Using memset is incorrect if the __bucket_ptr type is non-trivial, or     does not use an all-zero bit pattern for its null value.     Replace the use of memset with std::__uinitialized_defa

Re: [PATCH v1] RISC-V: Add testcases for vector unsigned SAT_SUB form 2

2024-06-15 Thread ??????
lgtm --Reply to Message-- On Sat, Jun 15, 2024 20:56 PM Li, Pan2

[PATCH v1] RISC-V: Add testcases for vector unsigned SAT_SUB form 2

2024-06-15 Thread pan2 . li
From: Pan Li The previous RISC-V backend .SAT_SUB enabling patch missed the form 2 testcases of vector modes. Aka: Form 2: #define DEF_VEC_SAT_U_SUB_FMT_2(T) \ void __attribute__((noinline)) \ vec_sat_u_sub_##T##_fmt_

Ping^2: [PATCH 0/3] Recover in-tree libiconv build support

2024-06-15 Thread Arsen Arsenović
Hi! Another gentle ping on this patch series. Could it be merged into trunk? TIA, have a lovely day! -- Arsen Arsenović signature.asc Description: PGP signature

[wwwdocs,pushed] backends.html - Update weblinks to AVR simulators

2024-06-15 Thread Georg-Johann Lay
Applied this one: backends.html - Update weblinks to AVR simulators. diff --git a/htdocs/backends.html b/htdocs/backends.html index bdaf29ad..1f7c85d7 100644 --- a/htdocs/backends.html +++ b/htdocs/backends.html @@ -120,9 +120,19 @@ visium | B g t s xtensa | C

Re: [PATCH] riscv: Allocate enough space to strcpy() string

2024-06-15 Thread Kito Cheng
Ok for gcc 14 too :) Christoph Müllner 於 2024年6月15日 週六 15:14 寫道: > > > On Sat, Jun 15, 2024, 08:25 Kito Cheng wrote: > >> Oooops, thanks for catching that! It's LGTM:) >> > > Also OK for the GCC 14 branch? > > >> Christoph Müllner 於 2024年6月15日 週六 04:58 寫道: >> >>> I triggered an ICE on Ubuntu 2

Re: [PATCH V4] Add warning options -W[no-]compare-distinct-pointer-types

2024-06-15 Thread Gerald Pfeifer
On Thu, 17 Aug 2023, Jose E. Marchesi via Gcc-patches wrote: > [Changes from V3: : > LLVM supports an option -W[no-]compare-distinct-pointer-types that can > be used in order to enable or disable the emission of such warnings. It looks this went in, alas is not covered in gcc-14/changes.html? Was

Re: [PATCH] libstdc++: Fix build for AVR [PR115481, PR111639]

2024-06-15 Thread Georg-Johann Lay
Am 14.06.24 um 21:11 schrieb Detlef Vollmann: I actually plan anyway to run a test with the built libstdc++ on simulavr.   Detlef As an aside, simulavr tries to simulate an exact match of the hardware including internal I/O like timers, IRQs, etc. For GCC regression testing, no internal I/O

[pushed] wwwdocs: news: Drop links to old OpenMP standard PDFs

2024-06-15 Thread Gerald Pfeifer
We still have newer ones and general links to the specifications. Pushed. Gerald --- htdocs/news.html | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/htdocs/news.html b/htdocs/news.html index 4a24a4ad..7d793add 100644 --- a/htdocs/news.html +++ b/htdocs/news.html @@

Re: [RFC v2] RISC-V: Promote Zaamo/Zalrsc to a when using an old binutils

2024-06-15 Thread Andreas Schwab
../../gcc/common/config/riscv/riscv-common.cc: In member function 'std::string riscv_subset_list::to_string(bool, bool) const': ../../gcc/common/config/riscv/riscv-common.cc:997:37: error: 'a_subset' may be used uninitialized [-Werror=maybe-uninitialized] 997 | if (subset_cmp (a_subse

[pushed] doc: Remove pointer to old versions of binutils

2024-06-15 Thread Gerald Pfeifer
The oldest release in the advertised location dates back to August 2002, which is way older than we remotely want to cover here. gcc: PR target/69374 * doc/install.texi (Specific): Remove pointer to old versions of binutils. --- gcc/doc/install.texi | 4 1 file change

Re: [PATCH] riscv: Allocate enough space to strcpy() string

2024-06-15 Thread Christoph Müllner
On Sat, Jun 15, 2024, 08:25 Kito Cheng wrote: > Oooops, thanks for catching that! It's LGTM:) > Also OK for the GCC 14 branch? > Christoph Müllner 於 2024年6月15日 週六 04:58 寫道: > >> I triggered an ICE on Ubuntu 24.04 when compiling code that uses >> function attributes. Looking into the sources s