Re: [PATCH] RISC-V: Clarify that Vector Crypto Extensions require Vector Extensions[PR116150]

2024-08-05 Thread Liao Shihua
在 2024/8/6 12:34, Jeff Law 写道: On 8/5/24 10:23 AM, Patrick O'Neill wrote: On 8/5/24 01:23, Liao Shihua wrote: PR 116150: Zvk* and Zvb* extensions requires v or zve* extension, but on gcc v is implied. gcc/ChangeLog: * common/config/riscv/riscv-common.cc: Removed the zv

[PATCH] c++/modules: Handle instantiating qualified template friend classes [PR115801]

2024-08-05 Thread Nathaniel Shead
Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? Another potential approach would be to go searching for this unexported type and load it, either with a new LOOK_want::ANY_REACHABLE flag or by expanding on the lookup_imported_temploid_friend hack. I'm still not exactly sure how na

Ping^6 [PATCH] add rlwinm pattern for DImode for constant building

2024-08-05 Thread Jiufu Guo
Hi, Gentle ping... BR, Jeff(Jiufu) Guo Jiufu Guo writes: > Hi, > > Gentle ping... > > BR, > Jeff(Jiufu) Guo > > Jiufu Guo writes: > >> Hi, >> >> Gentle ping. >> >> BR, >> Jeff(Jiufu) Guo >> >> Jiufu Guo writes: >> >>> Hi, >>> >>> Gentle ping ... >>> >>> Jiufu Guo writes: >>> Hi,

Re: [PATCH] RISC-V: Minimal support for Zimop extension.

2024-08-05 Thread Nelson Chu
On Tue, Aug 6, 2024 at 11:17 AM Jeff Law wrote: > > On 8/5/24 8:17 PM, Nelson Chu wrote: > > 2.43 was released over an weekend. Is it possible to let it be > > supported after 2.44? cc Nick and jan. > I don't think it's critical enough to backport to 2.43. I'd just put it > on the trunk so that

Re: [PATCH, rs6000] Add const_vector into any_operand predicate

2024-08-05 Thread HAO CHEN GUI
Thanks for reviewing the patch. Committed as r15-2740. 在 2024/7/31 17:10, Kewen.Lin 写道: > Hi Haochen, > > on 2024/7/25 11:34, HAO CHEN GUI wrote: >> Hi, >> This patch add const_vector into any_operand predicate. From my >> understanding, any_operand should include all kinds of operands. >> The

Re: [PATCH] RISC-V: Clarify that Vector Crypto Extensions require Vector Extensions[PR116150]

2024-08-05 Thread Jeff Law
On 8/5/24 10:23 AM, Patrick O'Neill wrote: On 8/5/24 01:23, Liao Shihua wrote: PR 116150: Zvk* and Zvb* extensions requires v or zve* extension, but on gcc v is implied. gcc/ChangeLog: * common/config/riscv/riscv-common.cc: Removed the zvk extension's implicit expansion

Re: sched1 pathology on RISC-V : PR/114729

2024-08-05 Thread Jeff Law
On 8/5/24 5:35 PM, Vineet Gupta wrote: Hi Richard, I'm reaching out for some insight on PR/114729. Apologies in advance for the long email. On RISC-V we are hitting sched1 pathology on SPEC2017 Cactu where codegen spills are overwhelming the execution: disabling sched1 shaves off 1.3 trillio

Re: [PATCH 3/3] RISC-V: Fix typos in code

2024-08-05 Thread Jeff Law
On 8/5/24 4:29 PM, Patrick O'Neill wrote: This fixes typos in function names and executed code. gcc/ChangeLog: * config/riscv/riscv-target-attr.cc (num_occurences_in_str): Rename... (num_occurrences_in_str): here. (riscv_process_target_attr): Update num_occurences_in_

Re: [PATCH 1/3] RISC-V: Fix comment typos

2024-08-05 Thread Jeff Law
On 8/5/24 4:29 PM, Patrick O'Neill wrote: This fixes most of the typos I found when reading various parts of the RISC-V backend. Comment typos are always OK to fix under the "obvious" rule. No need to wait for an ACK. Jeff

Re: [PATCH] RISC-V: Minimal support for Zimop extension.

2024-08-05 Thread Jeff Law
On 8/5/24 8:17 PM, Nelson Chu wrote: 2.43 was released over an weekend.  Is it possible to let it be supported after 2.44? cc Nick and jan. I don't think it's critical enough to backport to 2.43. I'd just put it on the trunk so that it's available in 2.44. jeff

Re: [PATCH] RISC-V: Minimal support for Zimop extension.

2024-08-05 Thread Nelson Chu
2.43 was released over an weekend. Is it possible to let it be supported after 2.44? cc Nick and jan. Thanks Nelson On Mon, Aug 5, 2024 at 11:24 PM Jeff Law wrote: > > > On 8/5/24 9:21 AM, Jiawei wrote: > > > > > Thanks Jeff! I think I do not have the permissions in the binutils repo, > > let

Re: [PATCH] c++: remove function/var concepts code

2024-08-05 Thread Patrick Palka
On Fri, 2 Aug 2024, Marek Polacek wrote: > Bootstrapped/regtested on x86_64-pc-linux-gnu. Comments? > > -- >8 -- > This patch removes vestigial Concepts TS code as discussed in > . Yay! FWIW I think we can also remove the concept

RE: [PATCH v1] Match: Add type_has_mode_precision_p check for SAT_TRUNC [PR116202]

2024-08-05 Thread Li, Pan2
> Well that means the caller (vectorizer pattern recog?) wrongly used a > vector of QImode in > the first place, so it needs to check the scalar mode as well? Current vect pattern recog only check the vector mode of define_expand pattern implemented or not. Similar as below without scalar part.

RE: [PATCH v1] Match: Support form 1 for scalar signed integer .SAT_ADD

2024-08-05 Thread Li, Pan2
Hi Richard, It looks like the plus will have additional convert to unsigned in int8 and int16, see below example in test.c.006t.gimple. And we need these convert ops in one matching pattern to cover all int scalar types. I am not sure if there is a better way here, given convert in matching pat

Re: Re: [PATCH] RISC-V: Minimal support for Zimop extension.

2024-08-05 Thread Xiao Zeng
2024-08-05 23:21  Jiawei wrote: > > >在 2024/8/5 22:15, Jeff Law 写道: >> >> >> On 8/4/24 8:20 PM, Jiawei wrote: >>> >>> 在 2024/8/5 8:45, Jeff Law 写道: On 8/2/24 9:32 AM, Jiawei wrote: > https://github.com/riscv/riscv-isa-manual/blob/main/src/zimop.adoc > > gcc/ChangeLog: >>

Re: [PATCH] sh: Don't call make_insn_raw in sh_recog_treg_set_expr [PR116189]

2024-08-05 Thread Oleg Endo
On Mon, 2024-08-05 at 14:15 -0700, Andrew Pinski wrote: > This was an interesting compare debug failure to debug. The first symptom > was in gcse which would produce different order of creating psedu-registers. > This > was caused by a different order of a hashtable walk, due to the hash table

libbacktrace patch committed: Avoid -Wpointer-arith errors

2024-08-05 Thread Ian Lance Taylor
This patch, based on one by Kirill Müller, adds -Wpointer-arith to the libbacktrace warning options, and adds casts to avoid the cases where the warning currently fires. Bootstrapped and ran libbacktrace testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian * configure.ac (ACX_PROG_CC_WA

Re: [PATCH 3/3] RISC-V: Fix typos in code

2024-08-05 Thread Christoph Müllner
On Tue, Aug 6, 2024 at 12:29 AM Patrick O'Neill wrote: > > This fixes typos in function names and executed code. > > gcc/ChangeLog: > > * config/riscv/riscv-target-attr.cc (num_occurences_in_str): Rename... > (num_occurrences_in_str): here. > (riscv_process_target_attr): Up

sched1 pathology on RISC-V : PR/114729

2024-08-05 Thread Vineet Gupta
Hi Richard, I'm reaching out for some insight on PR/114729. Apologies in advance for the long email. On RISC-V we are hitting sched1 pathology on SPEC2017 Cactu where codegen spills are overwhelming the execution: disabling sched1 shaves off 1.3 trillion dynamic icounts which is about half of tot

Go patch committed: Panic arguments have empty interface type

2024-08-05 Thread Ian Lance Taylor
This patch to the Go frontend determines that panic arguments are empty interfaces. After https://go.dev/cl//536643 passing NULL as the expected type permitted an untyped constant expression to remain untyped. This change will fix them to take on the empty interface type. The panic and print/prin

[Committed] RISC-V: Add deprecation warning to LP64E abi

2024-08-05 Thread Patrick O'Neill
On 8/5/24 07:21, Jeff Law wrote: On 7/30/24 6:32 PM, Patrick O'Neill wrote: gcc/ChangeLog: PR 116152 * config/riscv/riscv.cc (riscv_option_override): Add deprecation warning. gcc/testsuite/ChangeLog: * gcc.target/riscv/predef-9.c: Add check for warning. OK jeff Rebased

[Committed] RISC-V: Add deprecation warning to LP64E abi

2024-08-05 Thread Patrick O'Neill
gcc/ChangeLog: PR target/116152 * config/riscv/riscv.cc (riscv_option_override): Add deprecation warning. gcc/testsuite/ChangeLog: * gcc.target/riscv/predef-9.c: Add check for warning. Signed-off-by: Patrick O'Neill --- gcc/config/riscv/riscv.cc

[PATCH 2/3] RISC-V: Fix non-obvious comment typos

2024-08-05 Thread Patrick O'Neill
This fixes the remainder of the typos I found when reading various parts of the RISC-V backend. gcc/ChangeLog: * config/riscv/riscv-v.cc (legitimize_move): extrac -> extract. (expand_vec_cmp_float): Remove duplicate vmnor.mm. * config/riscv/riscv-vector-builtins.cc: ins ->

[PATCH 1/3] RISC-V: Fix comment typos

2024-08-05 Thread Patrick O'Neill
This fixes most of the typos I found when reading various parts of the RISC-V backend. gcc/ChangeLog: * config/riscv/arch-canonicalize: Fix typos in comments. * config/riscv/autovec.md: Ditto. * config/riscv/riscv-avlprop.cc (avl_can_be_propagated_p): Ditto. (pass_

[PATCH 3/3] RISC-V: Fix typos in code

2024-08-05 Thread Patrick O'Neill
This fixes typos in function names and executed code. gcc/ChangeLog: * config/riscv/riscv-target-attr.cc (num_occurences_in_str): Rename... (num_occurrences_in_str): here. (riscv_process_target_attr): Update num_occurences_in_str callsite. * config/riscv/riscv-v.cc

Re: [PATCH] c++: permit errors inside uninstantiated templates [PR116064]

2024-08-05 Thread Patrick Palka
On Mon, 5 Aug 2024, Jason Merrill wrote: > On 8/5/24 3:47 PM, Patrick Palka wrote: > > On Mon, 5 Aug 2024, Jason Merrill wrote: > > > > > On 8/5/24 1:14 PM, Patrick Palka wrote: > > > > On Mon, 5 Aug 2024, Jason Merrill wrote: > > > > > > > > > On 8/2/24 4:18 PM, Patrick Palka wrote: > > > > > >

Re: [PATCH] c++: permit errors inside uninstantiated templates [PR116064]

2024-08-05 Thread Jason Merrill
On 8/5/24 3:47 PM, Patrick Palka wrote: On Mon, 5 Aug 2024, Jason Merrill wrote: On 8/5/24 1:14 PM, Patrick Palka wrote: On Mon, 5 Aug 2024, Jason Merrill wrote: On 8/2/24 4:18 PM, Patrick Palka wrote: On Fri, 2 Aug 2024, Patrick Palka wrote: On Fri, 2 Aug 2024, Jason Merrill wrote: On

Re: [PATCH] c++: remove function/var concepts code

2024-08-05 Thread Jason Merrill
On 8/5/24 4:00 PM, Marek Polacek wrote: On Mon, Aug 05, 2024 at 02:52:32PM -0400, Jason Merrill wrote: On 8/5/24 2:44 PM, Marek Polacek wrote: On Mon, Aug 05, 2024 at 12:00:04PM -0400, Jason Merrill wrote: I think we also want to adjust the 'concept bool' handling in cp_parser_decl_specifier

[PATCH] sh: Don't call make_insn_raw in sh_recog_treg_set_expr [PR116189]

2024-08-05 Thread Andrew Pinski
This was an interesting compare debug failure to debug. The first symptom was in gcse which would produce different order of creating psedu-registers. This was caused by a different order of a hashtable walk, due to the hash table having different number of entries. Which in turn was due to the n

Re: [PATCH] rs6000, document built-ins vec_test_lsbb_all_ones and, vec_test_lsbb_all_zeros

2024-08-05 Thread Steven Munroe
Looking at the latest version of the Power Vector Intrinsic Programming Reference (Revision 2.0.0_prd, Bill slipped this to me for review), I see that vec_test_lsbb_all_ones vec_test_lsbb_all_zeros both specify vector unsigned char, only. On Mon, Aug 5, 2024 at 1:15 AM Kewen.Lin wrote: > on 2024

Re: [RFC v3 3/3] c: Add __lengthof__() operator

2024-08-05 Thread Alejandro Colomar
Hi Qing, On Mon, Aug 05, 2024 at 10:41:43PM GMT, Martin Uecker wrote: > Am Montag, dem 05.08.2024 um 20:10 + schrieb Qing Zhao: > > On Aug 5, 2024, at 06:33, Martin Uecker wrote: > > > > > > Am Montag, dem 05.08.2024 um 11:50 +0200 schrieb Jakub Jelinek: > > > > On Mon, Aug 05, 2024 at 11:45

Re: [RFC v3 3/3] c: Add __lengthof__() operator

2024-08-05 Thread Martin Uecker
Am Montag, dem 05.08.2024 um 20:10 + schrieb Qing Zhao: > On Aug 5, 2024, at 06:33, Martin Uecker wrote: > > > > Am Montag, dem 05.08.2024 um 11:50 +0200 schrieb Jakub Jelinek: > > > On Mon, Aug 05, 2024 at 11:45:56AM +0200, Alejandro Colomar wrote: > > > > [CC += Kees, Qing] > > > > > > > >

Re: [PATCH 1/8] fortran: Add tests covering inline MINLOC/MAXLOC without DIM [PR90608]

2024-08-05 Thread Mikael Morin
Hello, Le 05/08/2024 à 21:25, Harald Anlauf a écrit : Is there a reason you do not use the ieee intrinsic module way to get a quiet nan?  Otherwise, how do you prevent exceptions to happen, possibly leading to a failing test? (The test cases need a workaround to run with NAG). indeed, I didn't

Re: [PATCH ver 3] rs6000, Add new overloaded vector shift builtin int128, variants

2024-08-05 Thread Carl Love
Kewen: On 8/4/24 11:13 PM, Kewen.Lin wrote: Hi Carl, on 2024/8/2 03:35, Carl Love wrote: GCC developers: Version 3, updated the testcase dg-do link to dg-do compile.  Moved the new documentation again.  Retested on Power 10 LE and BE to verify the dg arguments disable the test on Power10BE

[RFC] libstdc++: Replace Ryu with Teju Jagua for float.

2024-08-05 Thread Cassio Neri
Implement the template function teju_jagua which finds the shortest representation of a floating-point number. The floating-point type is a template parameter and the implementation is generic enough to handle all floating-point types of interest, namely, IEEE 754, std::bfloat16_t, x86 80-bit and I

[PATCH v2] Explicitly document that the "counted_by" attribute is only supported in C.

2024-08-05 Thread Qing Zhao
Compared to the first version, the major changes are: 1. Changed the error as a warning with -Wattributes per Jakub and Jason's comments. 2. Update documentation accordingly. 3. Move the testing case to g++.dg/ext Add one more new testing case for C++11 Adjust the testing case according t

Re: [RFC v3 3/3] c: Add __lengthof__() operator

2024-08-05 Thread Qing Zhao
On Aug 5, 2024, at 06:33, Martin Uecker wrote: > > Am Montag, dem 05.08.2024 um 11:50 +0200 schrieb Jakub Jelinek: >> On Mon, Aug 05, 2024 at 11:45:56AM +0200, Alejandro Colomar wrote: >>> [CC += Kees, Qing] >>> >>> Hi Joseph, >>> >>> On Sun, Aug 04, 2024 at 08:34:24PM GMT, Alejandro Colomar wr

Re: [PATCH] c++: remove function/var concepts code

2024-08-05 Thread Marek Polacek
On Mon, Aug 05, 2024 at 02:52:32PM -0400, Jason Merrill wrote: > On 8/5/24 2:44 PM, Marek Polacek wrote: > > On Mon, Aug 05, 2024 at 12:00:04PM -0400, Jason Merrill wrote: > > > > I think we also want to adjust the 'concept bool' handling in > > > cp_parser_decl_specifier_seq: > > > > > > >

Re: [PATCH] c++: permit errors inside uninstantiated templates [PR116064]

2024-08-05 Thread Patrick Palka
On Mon, 5 Aug 2024, Jason Merrill wrote: > On 8/5/24 1:14 PM, Patrick Palka wrote: > > On Mon, 5 Aug 2024, Jason Merrill wrote: > > > > > On 8/2/24 4:18 PM, Patrick Palka wrote: > > > > On Fri, 2 Aug 2024, Patrick Palka wrote: > > > > > > > > > On Fri, 2 Aug 2024, Jason Merrill wrote: > > > > >

Re: [PATCH 1/8] fortran: Add tests covering inline MINLOC/MAXLOC without DIM [PR90608]

2024-08-05 Thread Harald Anlauf
Hi Mikael, I had only a quick glance at this patch, but am a little concerned about the tests involving nans. E.g.: + subroutine check_all_nans() +real, allocatable :: a(:,:,:) +real :: nan +integer, allocatable :: m(:) +nan = 0 +nan = nan / nan +allocate(a(3,3,3), sou

[pushed] wwwdocs: gcc-3.4: Switch GNU Classpath link to https

2024-08-05 Thread Gerald Pfeifer
Pushed. Gerald --- htdocs/gcc-3.4/changes.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/gcc-3.4/changes.html b/htdocs/gcc-3.4/changes.html index 76b4ce87..64042080 100644 --- a/htdocs/gcc-3.4/changes.html +++ b/htdocs/gcc-3.4/changes.html @@ -735,7 +735,7 @@ and

[pushed] wwwdocs: news: Switch MMIX links to https

2024-08-05 Thread Gerald Pfeifer
Pushed. Gerald --- htdocs/news.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/news.html b/htdocs/news.html index bb04a682..a8850dd4 100644 --- a/htdocs/news.html +++ b/htdocs/news.html @@ -1228,7 +1228,7 @@ GCC 3.0.3 has been released. November 3, 2001 Hans-Pe

[PATCH] doc: Rephrase GM2 Limitations section

2024-08-05 Thread Gerald Pfeifer
I noticed a non-working link, then some other details in that section. Here is a suggestion to rework it a bit. Okay? Gerald >From 83e856355a94bd78afbf19eed32ca1726658f581 Mon Sep 17 00:00:00 2001 From: Gerald Pfeifer Date: Mon, 5 Aug 2024 21:06:20 +0200 Subject: [PATCH] doc: Rephrase GM2 Li

Re: [PATCH] c++: remove function/var concepts code

2024-08-05 Thread Jason Merrill
On 8/5/24 2:44 PM, Marek Polacek wrote: On Mon, Aug 05, 2024 at 12:00:04PM -0400, Jason Merrill wrote: I think we also want to adjust the 'concept bool' handling in cp_parser_decl_specifier_seq: /* Warn for concept as a decl-specifier. We'll rewrite these as concept declarations l

Re: [PATCH] c++: remove function/var concepts code

2024-08-05 Thread Marek Polacek
On Mon, Aug 05, 2024 at 12:00:04PM -0400, Jason Merrill wrote: > On 8/2/24 2:12 PM, Marek Polacek wrote: > > Bootstrapped/regtested on x86_64-pc-linux-gnu. Comments? > > > > -- >8 -- > > This patch removes vestigial Concepts TS code as discussed in > >

Re: [PATCH] Explicitly document that the "counted_by" attribute is only supported in C

2024-08-05 Thread Qing Zhao
On Aug 5, 2024, at 13:54, Jakub Jelinek wrote: On Mon, Aug 05, 2024 at 01:48:25PM -0400, Jason Merrill wrote: On 8/5/24 9:53 AM, Jakub Jelinek wrote: On Mon, Aug 05, 2024 at 01:33:01PM +, Qing Zhao wrote: As discussed in PR116016:https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116016#c48 We s

Re: [PATCH,c++,wwwdocs] bugs: Remove old "export" non-bug

2024-08-05 Thread Gerald Pfeifer
On Mon, 22 Jul 2024, Jonathan Wakely wrote: >> We have been carrying this note on the "original" export feature for ages, >> and I believe it's not actually a FAQ, if it ever was. >> >> Jonathan moved this down when adding a note on ADL last fall. >> >> I now propose to drop it. > Sounds good to me

[PATCH] testsuite: Fix struct size check [PR116155]

2024-08-05 Thread Dimitar Dimitrov
The size of "struct only_fam_2" is dependent on the alignment of the flexible array member "b", and not on the type of the preceding bit-fields. For most targets the two are equal. But on default_packed targets like pru-unknown-elf, the alignment of int is not equal to the size of int, so the tes

[pushed] wwwdocs: news: Adjust link to 2015 ACM Software System Award

2024-08-05 Thread Gerald Pfeifer
Pushed. Gerald --- htdocs/news.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/news.html b/htdocs/news.html index 6fac4ea5..bb04a682 100644 --- a/htdocs/news.html +++ b/htdocs/news.html @@ -196,7 +196,7 @@ [2016-06-03] wwwdocs: -http://awards.acm.org/a

Re: [PATCH] Explicitly document that the "counted_by" attribute is only supported in C

2024-08-05 Thread Jakub Jelinek
On Mon, Aug 05, 2024 at 01:48:25PM -0400, Jason Merrill wrote: > On 8/5/24 9:53 AM, Jakub Jelinek wrote: > > On Mon, Aug 05, 2024 at 01:33:01PM +, Qing Zhao wrote: > > > As discussed in > > > PR116016:https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116016#c48 > > > > > > We should explicitly doc

Re: [PATCH] Explicitly document that the "counted_by" attribute is only supported in C

2024-08-05 Thread Jason Merrill
On 8/5/24 9:53 AM, Jakub Jelinek wrote: On Mon, Aug 05, 2024 at 01:33:01PM +, Qing Zhao wrote: As discussed in PR116016:https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116016#c48 We should explicitly document this limitation and issue error messages for C++. The "counted_by" attribute current

Re: [RFC v3 3/3] c: Add __lengthof__() operator

2024-08-05 Thread Alejandro Colomar
Hi Martin, On Mon, Aug 05, 2024 at 06:05:15PM GMT, Martin Uecker wrote: > > > > However, if I turn on -Wvla, both get a warning: > > > > len.c: At top level: > > len.c:288:1: warning: ISO C90 forbids variable length array ‘x’ [-Wvla] > > 288 | void foo(char (*a)[3][*], int (*x)[__l

Re: [PATCH] c++: permit errors inside uninstantiated templates [PR116064]

2024-08-05 Thread Jason Merrill
On 8/5/24 1:14 PM, Patrick Palka wrote: On Mon, 5 Aug 2024, Jason Merrill wrote: On 8/2/24 4:18 PM, Patrick Palka wrote: On Fri, 2 Aug 2024, Patrick Palka wrote: On Fri, 2 Aug 2024, Jason Merrill wrote: On 8/1/24 2:52 PM, Patrick Palka wrote: In recent versions of GCC we've been diagnosin

Re: [PATCH] Explicitly document that the "counted_by" attribute is only supported in C

2024-08-05 Thread Qing Zhao
> On Aug 5, 2024, at 12:51, Jakub Jelinek wrote: > > On Mon, Aug 05, 2024 at 04:46:09PM +, Qing Zhao wrote: >> So, you want me to add counted_by test-suite for C23? (Which should be >> supported) >> Okay, but I will do it in another separate patch since this patch is for C++. >>> The C++11

Re: [PATCH] c++: permit errors inside uninstantiated templates [PR116064]

2024-08-05 Thread Patrick Palka
On Mon, 5 Aug 2024, Jason Merrill wrote: > On 8/2/24 4:18 PM, Patrick Palka wrote: > > On Fri, 2 Aug 2024, Patrick Palka wrote: > > > > > On Fri, 2 Aug 2024, Jason Merrill wrote: > > > > > > > On 8/1/24 2:52 PM, Patrick Palka wrote: > > > > > In recent versions of GCC we've been diagnosing more

Re: [PATCH] Explicitly document that the "counted_by" attribute is only supported in C

2024-08-05 Thread Jakub Jelinek
On Mon, Aug 05, 2024 at 04:46:09PM +, Qing Zhao wrote: > So, you want me to add counted_by test-suite for C23? (Which should be > supported) > Okay, but I will do it in another separate patch since this patch is for C++. > > The C++11/C23 standard attributes are more strict on where they can

Re: [PATCH] Explicitly document that the "counted_by" attribute is only supported in C

2024-08-05 Thread Qing Zhao
> On Aug 5, 2024, at 09:53, Jakub Jelinek wrote: > > On Mon, Aug 05, 2024 at 01:33:01PM +, Qing Zhao wrote: >> As discussed in >> PR116016:https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116016#c48 >> >> We should explicitly document this limitation and issue error messages for >> C++. >>

Re: [PATCH] RISC-V: Clarify that Vector Crypto Extensions require Vector Extensions[PR116150]

2024-08-05 Thread Patrick O'Neill
On 8/5/24 01:23, Liao Shihua wrote: PR 116150: Zvk* and Zvb* extensions requires v or zve* extension, but on gcc v is implied. gcc/ChangeLog: * common/config/riscv/riscv-common.cc: Removed the zvk extension's implicit expansion of v extension. * config/riscv/arch-

Re: [RFC][PATCH] SVE intrinsics: Fold svdiv (svptrue, x, x) to ones

2024-08-05 Thread Kyrylo Tkachov
> On 5 Aug 2024, at 18:00, Richard Sandiford wrote: > > External email: Use caution opening links or attachments > > > Kyrylo Tkachov writes: >>> On 5 Aug 2024, at 12:01, Richard Sandiford >>> wrote: >>> >>> External email: Use caution opening links or attachments >>> >>> >>> Jennifer S

[COMMITTED, BPF] bpf: do not emit BPF non-fetching atomic instructions

2024-08-05 Thread Jose E. Marchesi
When GCC finds a call to one of the __atomic_OP_fetch built-ins in which the return value is not used it optimizes it into the corresponding non-fetching atomic operation. Up to now we had definitions in gcc/config/bpf/atomic.md to implement both atomic_OP and atomic_fetch_OP sets of insns: ato

Re: [RFC v3 3/3] c: Add __lengthof__() operator

2024-08-05 Thread Martin Uecker
Am Montag, dem 05.08.2024 um 17:27 +0200 schrieb Alejandro Colomar: > Hi Martin, > ... > > But I think you might make it unnecessarily complicated. It > > should be sufficient to look at the outermost size. You > > can completely ignore thatever happens There > > should be three cases if I am n

Re: [RFC][PATCH] SVE intrinsics: Fold svdiv (svptrue, x, x) to ones

2024-08-05 Thread Richard Sandiford
Kyrylo Tkachov writes: >> On 5 Aug 2024, at 12:01, Richard Sandiford wrote: >> >> External email: Use caution opening links or attachments >> >> >> Jennifer Schmitz writes: >>> This patch folds the SVE intrinsic svdiv into a vector of 1's in case >>> 1) the predicate is svptrue and >>> 2) div

Re: [PATCH] c++: remove function/var concepts code

2024-08-05 Thread Jason Merrill
On 8/2/24 2:12 PM, Marek Polacek wrote: Bootstrapped/regtested on x86_64-pc-linux-gnu. Comments? -- >8 -- This patch removes vestigial Concepts TS code as discussed in . In particular, it removes code related to function/variable

[x86_64 PATCH] Support memory destinations and wide immediate constants in STV.

2024-08-05 Thread Roger Sayle
Hi Uros, Very many thanks for the quick review and approval. Here's another. This patch implements two improvements/refinements to the i386 backend's Scalar-To-Vector (STV) pass. The first is to support memory destinations in binary logic operations, and the second is to provide more accurate c

Re: [PATCH] testsuite: Add RISC-V to targets not xfailing gcc.dg/attr-alloc_size-11.c:50, 51.

2024-08-05 Thread Jiawei
在 2024/8/5 23:21, Jeff Law 写道: On 8/5/24 6:26 AM, Jiawei wrote: The test has been observed to pass on most architectures including RISC-V: https://godbolt.org/z/8nYEvW6n1 Origin issue see: https://gcc.gnu.org/PR79356#c11 Update RISC-V target to to pass list. gcc/testsuite/ChangeLog:    

Re: [PATCH v2] c++: fix -Wdangling-reference false positive [PR115987]

2024-08-05 Thread Jason Merrill
On 8/2/24 3:22 PM, Marek Polacek wrote: On Thu, Aug 01, 2024 at 05:20:43PM -0400, Jason Merrill wrote: On 8/1/24 4:19 PM, Marek Polacek wrote: Bootstrapped/regtested on x86_64-pc-linux-gnu, ok for trunk? -- >8 -- This fixes another false positive. When a function is taking a temporary of scal

Re: [PATCH] c++: permit errors inside uninstantiated templates [PR116064]

2024-08-05 Thread Jason Merrill
On 8/2/24 4:18 PM, Patrick Palka wrote: On Fri, 2 Aug 2024, Patrick Palka wrote: On Fri, 2 Aug 2024, Jason Merrill wrote: On 8/1/24 2:52 PM, Patrick Palka wrote: In recent versions of GCC we've been diagnosing more and more kinds of errors inside a template ahead of time. This is a largely

Re: [PATCH v2] c++, coroutines: Simplify separation of the user function body and ramp.

2024-08-05 Thread Jason Merrill
On 8/3/24 11:40 AM, Iain Sandoe wrote: On 2 Aug 2024, at 15:19, Jason Merrill wrote: On 8/2/24 6:50 AM, Iain Sandoe wrote: This version simplifies the process by extrating the second case directly typo thanks, fixed. +static bool +use_eh_spec_block (tree fn) +{ + return (flag_excepti

Re: [PATCH v2] Hard register constraints

2024-08-05 Thread Georg-Johann Lay
Am 05.08.24 um 15:59 schrieb Stefan Schulze Frielinghaus: On Mon, Aug 05, 2024 at 02:19:50PM +0200, Georg-Johann Lay wrote: Am 05.08.24 um 12:28 schrieb Stefan Schulze Frielinghaus: This is rather unfortunate but I couldn't find a way how to validate register names during genoutput. If no one

Re: [RFC v3 3/3] c: Add __lengthof__() operator

2024-08-05 Thread Alejandro Colomar
Hi Martin, On Mon, Aug 05, 2024 at 03:35:06PM GMT, Martin Uecker wrote: > > > > > > For incomplete arrays, basically we have the following different > > > > > > variants for arrays: > > > > > > > > > > > > T[ ] incomplete: !TYPE_DOMAIN > > > > > > T[1] constant size: TYPE_MAX_VALUE == INTEGER_CS

Re: [PATCH] RISC-V: Minimal support for Zimop extension.

2024-08-05 Thread Jeff Law
On 8/5/24 9:21 AM, Jiawei wrote: Thanks Jeff! I think I do not have the permissions in the binutils repo, let me contact Nelson to ask him give  some help. Sounds good. Thanks for taking care of this. I just wish I'd noticed the patch a month ago so that we could have included it in the

Re: [PATCH] RISC-V: Minimal support for Zimop extension.

2024-08-05 Thread Jiawei
在 2024/8/5 22:15, Jeff Law 写道: On 8/4/24 8:20 PM, Jiawei wrote: 在 2024/8/5 8:45, Jeff Law 写道: On 8/2/24 9:32 AM, Jiawei wrote: https://github.com/riscv/riscv-isa-manual/blob/main/src/zimop.adoc gcc/ChangeLog: * common/config/riscv/riscv-common.cc: New extension. * config/riscv

Re: [PATCH] testsuite: Add RISC-V to targets not xfailing gcc.dg/attr-alloc_size-11.c:50, 51.

2024-08-05 Thread Jeff Law
On 8/5/24 6:26 AM, Jiawei wrote: The test has been observed to pass on most architectures including RISC-V: https://godbolt.org/z/8nYEvW6n1 Origin issue see: https://gcc.gnu.org/PR79356#c11 Update RISC-V target to to pass list. gcc/testsuite/ChangeLog: * gcc.dg/attr-alloc_size-11.c

Re: [PATCH] Fix Wstringop-overflow-47.c warning in RISC-V target.

2024-08-05 Thread Jeff Law
On 7/15/24 10:08 PM, Jiawei wrote: 在 2024/07/16 8:28, Jeff Law 写道: IIRC these fails are dependent upon whether or not the statements turn into vector stores or not. So to remove the xfail don't you have to know if vector is enabled/ disabled? I am not sure, I tried to enable with RVV,

Re: [PATCHv2, expand] Add const0 move checking for CLEAR_BY_PIECES optabs

2024-08-05 Thread Jeff Law
On 7/26/24 2:55 AM, HAO CHEN GUI wrote: Hi Jeff, 在 2024/7/24 5:57, Jeff Law 写道: On 7/21/24 7:58 PM, HAO CHEN GUI wrote: Hi,    This patch adds const0 move checking for CLEAR_BY_PIECES. The original vec_duplicate handles duplicates of non-constant inputs. But 0 is a constant. So even a pl

Re: Ping^4 [PATCH-3v2] Value Range: Add range op for builtin isnormal

2024-08-05 Thread Jeff Law
On 7/21/24 8:09 PM, HAO CHEN GUI wrote: Hi, Gently ping it. https://gcc.gnu.org/pipermail/gcc-patches/2024-May/653095.html Also OK. jeff

Re: Ping^4 [PATCH-2v4] Value Range: Add range op for builtin isfinite

2024-08-05 Thread Jeff Law
On 7/21/24 8:10 PM, HAO CHEN GUI wrote: Hi, Gently ping it. https://gcc.gnu.org/pipermail/gcc-patches/2024-May/653094.html OK. Sorry for the delays. jeff

Re: [PATCH-1v4] Value Range: Add range op for builtin isinf

2024-08-05 Thread Jeff Law
On 7/23/24 4:39 PM, Andrew MacLeod wrote: the range is in r, and is set to [0,0].  this is the false part of what is being returned for the range. the "return true" indicates we determined a range, so use what is in R. returning false means we did not find a range to return, so r is garbage

Re: [RFC][PATCH] SVE intrinsics: Fold svdiv (svptrue, x, x) to ones

2024-08-05 Thread Kyrylo Tkachov
> On 5 Aug 2024, at 12:01, Richard Sandiford wrote: > > External email: Use caution opening links or attachments > > > Jennifer Schmitz writes: >> This patch folds the SVE intrinsic svdiv into a vector of 1's in case >> 1) the predicate is svptrue and >> 2) dividend and divisor are equal. >>

Re: Support streaming of poly_int for offloading when it's degree <= accel's NUM_POLY_INT_COEFFS

2024-08-05 Thread Jakub Jelinek
On Mon, Aug 05, 2024 at 02:24:00PM +, Prathamesh Kulkarni wrote: > gcc/ChangeLog: > PR ipa/96265 > PR ipa/111937 > * data-streamer-in.cc (streamer_read_poly_uint64): Remove code for > streaming, and call poly_int_read_common instead. > (streamer_read_poly_int64):

Re: [PATCH] PR tree-optimization/57371: Optimize (float)i == 16777222.0f sometimes.

2024-08-05 Thread Jeff Law
On 7/28/24 6:01 AM, Roger Sayle wrote: This patch improves the tree-level optimization of (fptype)ivar != CST in match.pd (historically tracked under PR 57371). Joseph Myers' description in comment #1 provides an excellent overview of the issues, that historically it's the trapping behaviour

RE: Support streaming of poly_int for offloading when it's degree <= accel's NUM_POLY_INT_COEFFS

2024-08-05 Thread Prathamesh Kulkarni
> -Original Message- > From: Jakub Jelinek > Sent: Friday, August 2, 2024 5:43 PM > To: Prathamesh Kulkarni > Cc: Richard Biener ; Richard Sandiford > ; gcc-patches@gcc.gnu.org > Subject: Re: Support streaming of poly_int for offloading when it's > degree <= accel's NUM_POLY_INT_COEFFS

Re: [PATCH v2] RISC-V: Add deprecation warning to LP64E abi

2024-08-05 Thread Jeff Law
On 7/30/24 6:32 PM, Patrick O'Neill wrote: gcc/ChangeLog: PR 116152 * config/riscv/riscv.cc (riscv_option_override): Add deprecation warning. gcc/testsuite/ChangeLog: * gcc.target/riscv/predef-9.c: Add check for warning. OK jeff

Re: [PATCH v2] RISC-V: Add support to vector stack-clash protection

2024-08-05 Thread Jeff Law
On 8/1/24 2:16 PM, Raphael Zinsly wrote: On Thu, Aug 1, 2024 at 3:40 PM Jeff Law wrote: On 8/1/24 6:01 AM, Raphael Moreira Zinsly wrote: +/* Both prologue temp registers are used in the vector probe loop for when + stack-clash protection is enabled, so we need to copy SP to a new register

Re: [PATCH] middle-end/111821 - compile-time/memory-hog with large copy

2024-08-05 Thread Jeff Law
On 8/2/24 6:50 AM, Richard Biener wrote: The following fixes a compile-time/memory-hog when performing a large aggregate copy to a small object allocated to a register. While store_bit_field_1 called by store_integral_bit_field will do nothign for accesses outside of the target the loop over t

Re: [PATCH] RISC-V: Minimal support for Zimop extension.

2024-08-05 Thread Jeff Law
On 8/4/24 8:20 PM, Jiawei wrote: 在 2024/8/5 8:45, Jeff Law 写道: On 8/2/24 9:32 AM, Jiawei wrote: https://github.com/riscv/riscv-isa-manual/blob/main/src/zimop.adoc gcc/ChangeLog: * common/config/riscv/riscv-common.cc: New extension. * config/riscv/riscv.opt: New mask. gcc/testsu

Re: [PATCH] vect: Multistep float->int conversion only with no trapping math

2024-08-05 Thread Juergen Christ
Am Mon, Aug 05, 2024 at 01:00:31PM +0200 schrieb Richard Biener: > On Fri, Aug 2, 2024 at 2:43 PM Juergen Christ wrote: > > > > Do not convert floats to ints in multiple step if trapping math is > > enabled. This might hide some inexact signals. > > > > Also use correct sign (the sign of the targ

Re: [PATCH v2] Hard register constraints

2024-08-05 Thread Stefan Schulze Frielinghaus
On Mon, Aug 05, 2024 at 02:19:50PM +0200, Georg-Johann Lay wrote: > Am 05.08.24 um 12:28 schrieb Stefan Schulze Frielinghaus: > > This is a follow-up of > > https://gcc.gnu.org/pipermail/gcc-patches/2024-June/654013.html > > > > What has changed? > > > > - Rebased and fixed an issue in constrain_

Re: [PATCH] Explicitly document that the "counted_by" attribute is only supported in C

2024-08-05 Thread Jakub Jelinek
On Mon, Aug 05, 2024 at 01:33:01PM +, Qing Zhao wrote: > As discussed in > PR116016:https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116016#c48 > > We should explicitly document this limitation and issue error messages for > C++. > > The "counted_by" attribute currently is only supported in C,

Re: [PATCH v1] RISC-V: Update .SAT_TRUNC dump check due to middle-end change

2024-08-05 Thread Jeff Law
On 8/5/24 2:01 AM, pan2...@intel.com wrote: From: Pan Li Due to recent middle-end change, update the .SAT_TRUNC expand dump check from 2 to 4. gcc/testsuite/ChangeLog: * gcc.target/riscv/rvv/autovec/unop/vec_sat_u_trunc-1.c: Adjust asm check times from 2 to 4. OK jeff

RE: [PATCH v1] Match: Support form 1 for scalar signed integer .SAT_ADD

2024-08-05 Thread Li, Pan2
Thanks Richard for comments. > The convert looks odd to me given @0 is involved in both & operands. The convert is introduced as the GIMPLE IL is somehow different for int8_t when compares to int32_t or int64_t. There are some additional ops convert to unsigned for plus, see below line 8-9 and

[patch,avr,v2] PR115830: Make better use of SREG

2024-08-05 Thread Georg-Johann Lay
This is a second take on improving SREG (condition code) usage for avr. The difference to the 1st patch is that I added a paragraph to avr.md that explains why we don't use cmpelim: - The achievable compare mode may depend on the availability of a scratch register. SELECT_CC_MODE doesn't prov

Re: [PATCH v1] Match: Add type_has_mode_precision_p check for SAT_TRUNC [PR116202]

2024-08-05 Thread Richard Biener
On Mon, Aug 5, 2024 at 3:04 PM Li, Pan2 wrote: > > > Isn't that now handled by the direct_internal_fn_supported_p check? That > > is, > > by the caller which needs to verify the matched operation is supported by > > the target? > > type_strictly_matches_mode_p doesn't help here (include the un-c

Re: [RFC v3 3/3] c: Add __lengthof__() operator

2024-08-05 Thread Martin Uecker
Am Montag, dem 05.08.2024 um 13:59 +0200 schrieb Alejandro Colomar: > On Mon, Aug 05, 2024 at 01:58:18PM GMT, Alejandro Colomar wrote: > > On Mon, Aug 05, 2024 at 01:57:35PM GMT, Alejandro Colomar wrote: > > > On Mon, Aug 05, 2024 at 01:55:50PM GMT, Alejandro Colomar wrote: > > > > Hi Martin, > > >

[PATCH] Explicitly document that the "counted_by" attribute is only supported in C

2024-08-05 Thread Qing Zhao
As discussed in PR116016:https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116016#c48 We should explicitly document this limitation and issue error messages for C++. The "counted_by" attribute currently is only supported in C, mention this explicitly in documentation and also issue error when see "cou

Re: [x86_64 PATCH] Refactor V2DI arithmetic right shift expansion for STV.

2024-08-05 Thread Uros Bizjak
On Mon, Aug 5, 2024 at 12:22 PM Roger Sayle wrote: > > > This patch refactors ashrv2di RTL expansion into a function so that it may > be reused by a pre-reload splitter, such that DImode right shifts may be > considered candidates during the Scalar-To-Vector (STV) pass. Currently > DImode arithme

[PATCH] c++/modules: Fix merging of GM entities in partitions [PR114950]

2024-08-05 Thread Nathaniel Shead
Bootstrapped and regtested (so far just modules.exp) on x86_64-pc-linux-gnu, OK for trunk if full regtest passes? -- >8 -- Currently name lookup generally seems to assume that all entities declared within a named module (partition) are attached to said module, which is not true for GM entities (e

RE: [PATCH v1] Match: Add type_has_mode_precision_p check for SAT_TRUNC [PR116202]

2024-08-05 Thread Li, Pan2
> Isn't that now handled by the direct_internal_fn_supported_p check? That is, > by the caller which needs to verify the matched operation is supported by > the target? type_strictly_matches_mode_p doesn't help here (include the un-committed one). It will hit below case and return true directly a

Re: [PATCH] AArch64: Set instruction attribute of TST to logics_imm

2024-08-05 Thread Jennifer Schmitz
Pushed to trunk: 7268d7249b3ca31bf322de99b1d59baf06f83eb3 > On 30 Jul 2024, at 13:39, Richard Sandiford wrote: > > External email: Use caution opening links or attachments > > > Jennifer Schmitz mailto:jschm...@nvidia.com>> writes: >> As suggested in >> https://gcc.gnu.org/pipermail/gcc-patche

[COMMITED] gimple ssa: Fix a typo in gimple-ssa-sccopy.cc

2024-08-05 Thread Filip Kastl
Hello, just commited this as obvious. Filip Kastl -- 8< -- Fixes a misplaced comment in gimple-ssa-sccopy.cc. The comment belongs to a bitmap definition but was instead placed before the beginning of a namespace block. gcc/ChangeLog: * gimple-ssa-sccopy.cc: Move a misplaced comment.

  1   2   >