[PATCH] C and CPP: Add flag to generate resolver at default version implementation.

2024-10-30 Thread alfie.richards
Hi all, This patch adds the TARGET_CREATE_FMV_DISPATCHER_AT_DEFAULT_IMPL hook which changes FMV behavior for target_version functions to match the Arm C Language Extension. The functional differences consist of: 1. Generating the resolver for the dispatched symbol at the site of the default ve

Re: [PATCH #6/7] ifcombine across noncontiguous blocks (was: Re: [PATCH] fold fold_truth_andor field merging into ifcombine)

2024-10-30 Thread Richard Biener
On Fri, Oct 25, 2024 at 4:39 PM Alexandre Oliva wrote: > > > Rework ifcombine to support merging conditions from noncontiguous > blocks. This depends on earlier preparation changes. > > The function that attempted to ifcombine a block with its immediate > predecessor, tree_ssa_ifcombine_bb, now l

[PATCH v3 0/2][RFC]Provide more contexts for -Warray-bounds warning messages

2024-10-30 Thread Qing Zhao
Hi, This is the 3rd version of the patch for fixing PR109071. Thanks a lot for San James's help to test the previous 2nd version of the patch on a lot of packages in the wild and provide detailed analysis and filed new bugs. (PR117179, PR117180, etc). >From his testing results, we all feel that

Re: [PATCH v3 1/2][RFC] Provide more contexts for -Warray-bounds, -Wstringop-* warning messages due to code movements from compiler transformation [PR109071]

2024-10-30 Thread David Malcolm
On Wed, 2024-10-30 at 14:34 +, Sam James wrote: > Qing Zhao writes: > > > Control this with a new option -fdiagnostics-details. > > > > [...] > > The patch doesn't apply for me on very latest trunk -- I think > David's > recent diag refactoring means it needs a slight rebase. Could you > se

Re: [PATCH 1/4] sched1: hookize pressure scheduling spilling agressiveness

2024-10-30 Thread Richard Sandiford
Jeff Law writes: > On 10/30/24 4:05 AM, Richard Sandiford wrote: >> Vineet Gupta writes: >>> On 10/29/24 11:51, Wilco Dijkstra wrote: Hi Vineet, > I agree the NARROW/WIDE stuff is obfuscating things in technicalities. Is there evidence this change would make things significantly wor

Re: [PATCH v2 9/9] aarch64: Handle alignment when it is bigger than BIGGEST_ALIGNMENT

2024-10-30 Thread Richard Sandiford
Evgeny Karpov writes: > Tuesday, October 29, 2024 > Richard Sandiford wrote: > >> Hmm, I see. I think this is surprising enough that it would be worth >> a comment. How about: >> >> /* Since the assembly directive only specifies a size, and not an >> alignment, we need to follow the defaul

[PATCH] Remove vectorizer finish_cost wrapper

2024-10-30 Thread Richard Biener
The inline function wraps the vector_cost class API and no longer is a good representation of the query style of that class which makes it also difficult to extend. Boostrapped and tested on x86_64-unknown-linux-gnu, pushed. * tree-vectorizer.h (finish_cost): Inline everywhere and remove.

Re: [PATCH 1/4] sched1: hookize pressure scheduling spilling agressiveness

2024-10-30 Thread Jeff Law
On 10/30/24 8:44 AM, Richard Sandiford wrote: But the data from the BPI (spacemit k1 chip) is an in-order core. Granted we don't have a good model of its pipeline, but it's definitely in-order. Damn :) (I did try to clarify what was being tested earlier, but the response wasn't clear.) So

Re: [PATCH] libstdc++: Add align_alloc attribute to aligned operator new

2024-10-30 Thread Jonathan Wakely
On Wed, 30 Oct 2024 at 21:54, Jakub Jelinek wrote: > > On Wed, Oct 30, 2024 at 09:24:05PM +, Jonathan Wakely wrote: > > The aligned versions of operator new should use the align_alloc > > attribute to help the compiler. > > > > PR c++/86878 requests that the compiler would use the attribute to

Re: *PING* [PATCH 0/7] fortran: Inline MINLOC/MAXLOC with DIM [PR90608]

2024-10-30 Thread Harald Anlauf
Hi Mikael, Am 30.10.24 um 11:23 schrieb Mikael Morin: *PING* The first series of patches was pushed, the second (and last) one [1][2] is awaiting review. [1] https://gcc.gnu.org/pipermail/gcc-patches/2024-October/665360.html [2] https://gcc.gnu.org/pipermail/fortran/2024-October/061180.html

Re: [PATCH] libstdc++: Add align_alloc attribute to aligned operator new

2024-10-30 Thread Jakub Jelinek
On Wed, Oct 30, 2024 at 09:58:56PM +, Jonathan Wakely wrote: > I suppose the "not implicitly convertible to an integer" rule for > scoped enums is just a language constraint, the compiler sees scoped > enumerations like any other integral value. Sure. This is used in the middle-end and for it

Re: [PATCH] RISC-V: fix const interleaved stepped vector with a scalar pattern

2024-10-30 Thread Jeff Law
On 10/29/24 6:11 PM, Vineet Gupta wrote: When bisecting for ICE in PR/117353, commit 771256bcb9dd ("RISC-V: Emit costs for bool and stepped const vectors") uncovered yet another latent issue (first noted [1]) [1] https://github.com/patrick-rivos/gcc-postcommit-ci/issues/1625 This patch

[PATCH] libstdc++: Add align_alloc attribute to aligned operator new

2024-10-30 Thread Jonathan Wakely
The aligned versions of operator new should use the align_alloc attribute to help the compiler. PR c++/86878 requests that the compiler would use the attribute to warn about invalid attributes, so an XFAILed test is added for that. libstdc++-v3/ChangeLog: * libsupc++/new (operator new):

Re: [PATCH] libstdc++: Add align_alloc attribute to aligned operator new

2024-10-30 Thread Jonathan Wakely
On Wed, 30 Oct 2024 at 21:26, Jonathan Wakely wrote: > > The aligned versions of operator new should use the align_alloc > attribute to help the compiler. > > PR c++/86878 requests that the compiler would use the attribute to warn > about invalid attributes, so an XFAILed test is added for that. >

Re: [PATCH] [APX PPX] Avoid generating unmatched pushp/popp in pro/epilogue

2024-10-30 Thread Hongtao Liu
On Thu, Jul 4, 2024 at 11:00 AM Hongtao Liu wrote: > > On Tue, Jul 2, 2024 at 11:24 AM Hongyu Wang wrote: > > > > Hi, > > > > According to APX spec, the pushp/popp pairs should be matched, > > otherwise the PPX hint cannot take effect and cause performance loss. > > > > In the ix86_expand_epilogu

Re: [PATCH 6/7] RISC-V: Make vectorized memset handle more cases

2024-10-30 Thread Jeff Law
On 10/30/24 11:21 AM, Craig Blackmore wrote: Consider that a short term problem, at least for glibc.  I've got the magic ifunc bits which introduce vector versions and also check for fast unaligned support.    Does that change the calculus in your mind? Yes, with those bits in place it wo

[committed] libstdc++: Fix some typos and grammatical errors in docs

2024-10-30 Thread Jonathan Wakely
Also remove some redundant 'void' parameters from code examples. libstdc++-v3/ChangeLog: * doc/xml/manual/using_exceptions.xml: Fix typos and grammatical errors. * doc/html/manual/using_exceptions.html: Regenerate. --- Pushed to trunk. libstdc++-v3/doc/html/manual/using_

Re: [PATCH] libstdc++: Add align_alloc attribute to aligned operator new

2024-10-30 Thread Jakub Jelinek
On Wed, Oct 30, 2024 at 09:24:05PM +, Jonathan Wakely wrote: > The aligned versions of operator new should use the align_alloc > attribute to help the compiler. > > PR c++/86878 requests that the compiler would use the attribute to warn > about invalid attributes, so an XFAILed test is added f

Re: [PATCH v2] c++: Fix crash during NRV optimization with invalid input [PR117099, PR117129]

2024-10-30 Thread Simon Martin
Hi Jason, On 22 Oct 2024, at 17:07, Jason Merrill wrote: > On 10/17/24 10:30 AM, Simon Martin wrote: >> Hi, >> >> The issue reported in PR117129 is pretty similar to the one in >> PR117099, >> >> so here’s an updated version of the patch that fixes both issues, >> by >> ensuring that finish_ret

[r15-4787 Regression] FAIL: gcc.dg/vect/bb-slp-77.c scan-tree-dump-times slp1 "optimized: basic block" 1 on Linux/x86_64

2024-10-30 Thread haochen.jiang
On Linux/x86_64, acba8b3d8dec0124c8b3a7e112b3a784a5091214 is the first bad commit commit acba8b3d8dec0124c8b3a7e112b3a784a5091214 Author: Kugan Vivekanandarajah Date: Thu Oct 31 07:23:10 2024 +1100 [PATCH] Fix SLP when ifcvt versioned loop is not vectorized caused FAIL: gcc.dg/vect/bb-sl

Re: [PATCH 3/4] sched1: model: only promote true dependecies in predecessor promotion

2024-10-30 Thread Jeff Law
On 10/20/24 1:40 PM, Vineet Gupta wrote: Background -- sched1 runs a preliminary "model schedular" ahead of the main list schedular. Its sole purpose is to keep register pressure to mimimum [1] and it uses DFA register depenendency tracking to arrange insns. [1] https://gcc.gnu.or

[committed] libstdc++: Fix copy&paste comments in vector range tests

2024-10-30 Thread Jonathan Wakely
These comments were copied from the std::vector tests, but the value_type is not bool in these ones. libstdc++-v3/ChangeLog: * testsuite/23_containers/vector/cons/from_range.cc: Fix copy & paste error in comment. * testsuite/23_containers/vector/modifiers/append_range.cc:

[PATCH] libstdc++: Add P1206R7 from_range members to std::list and std::forward_list [PR111055]

2024-10-30 Thread Jonathan Wakely
This is another piece of P1206R7, adding new members to std::list and std::forward_list. libstdc++-v3/ChangeLog: PR libstdc++/111055 * include/bits/forward_list.h (forward_list(from_range, R&&, const Alloc&), assign_range) (prepend_range, insert_range_after): Defin

Re: [PATCH] RISC-V: fix const interleaved stepped vector with a scalar pattern

2024-10-30 Thread Vineet Gupta
On 10/30/24 14:13, Jeff Law wrote: > On 10/29/24 6:11 PM, Vineet Gupta wrote: >> When bisecting for ICE in PR/117353, commit 771256bcb9dd ("RISC-V: Emit >> costs for >> bool and stepped const vectors") uncovered yet another latent issue (first >> noted [1]) >> >>[1] https://github.com/patrick

Re: [Patch, fortran] PR115700 - comment 5: uninitialized string length in ASSOCIATE

2024-10-30 Thread Paul Richard Thomas
You see, Jerry, it's the tmp4 that might have been or, perhaps, was and is no more :-) The comment will be changed. Thanks for the review. Paul On Wed, 30 Oct 2024 at 17:01, Jerry D wrote: > On 10/30/24 9:58 AM, Steve Kargl wrote: > > On Wed, Oct 30, 2024 at 04:41:40PM +, Paul Richard Tho

[PATCH] testsuite: add testcase for fixed PR106073

2024-10-30 Thread Sam James
This was fixed by r12-8835-ge8d5f3a1b5a583 which surely made it latent but richi points out it was likely an instance of PR90348. -fstack-reuse continues to be a menace, so let's add the testcase. gcc/testsuite/ChangeLog: PR middle-end/90348 PR tree-optimization/106073 * g

[RISC-V] Reorder the ready queue to avoid extraneous vsetvls

2024-10-30 Thread Jeff Law
So this patch is a very conservative approach to eliminate more vsetvl instructions. As we know, scheduling can scramble the instruction stream based on a variety of factors and can easily result in an instruction sequence where we ping-pong between different vector configurations, thus resul

[committed] testsuite: fix syntax in Wstringop-overflow-59.c

2024-10-30 Thread Sam James
Fix quoting issues, escaping, and dg directive types. There were two issues here: 1) The incorrect quoting in an earlier dg-message was covering up that the syntax in the next part was wrong; 2) Fix dg-warning -> dg-message to correctly pick up the notes. Once 1) was fixed, this was exposed. With

[PATCH] RISC-V: allow -fno-plt to disable PLT

2024-10-30 Thread Yangyu Chen
Currently, the RISC-V target uses the target specific mplt option to control PLT generation. This patch deprecates the target specific mplt option and uses the common fplt option instead. This allows users to use the same option for most targets. Since both fplt and mplt are initialized to 1, it's

[PATCH v2 07/10] Test: Add testcases for form 5 of unsigned integer SAT_ADD simplify

2024-10-30 Thread pan2 . li
From: Pan Li The phiopt2 pass will also try the gimple_simplify for the form 5 of unsigned integer SAT_ADD. Thus add the testcase to make sure it will be performed in phiopt2 pass. gcc/testsuite/ChangeLog: * gcc.dg/sat_arith_simplify.h: Add test helper macros. * gcc.dg/sat_u_ad

[PATCH v2 02/10] Match: Simplify branch form 7 of unsigned SAT_ADD into branchless

2024-10-30 Thread pan2 . li
From: Pan Li There are sorts of forms for the unsigned SAT_ADD. Some of them are complicated while others are cheap. This patch would like to simplify the complicated form into the cheap ones. For example as below: >From the form 7 (branch): SAT_U_ADD = x <= (T)(x + y) ? (x + y) : -1. To (

[PATCH v2 01/10] Match: Simplify branch form 4 of unsigned SAT_ADD into branchless

2024-10-30 Thread pan2 . li
From: Pan Li There are sorts of forms for the unsigned SAT_ADD. Some of them are complicated while others are cheap. This patch would like to simplify the complicated form into the cheap ones. For example as below: >From the form 4 (branch): SAT_U_ADD = (X + Y) < x ? -1 : (X + Y). To (bran

[PATCH v2 05/10] Match: Update the comments of unsigned integer SAT_ADD [NFC]

2024-10-30 Thread pan2 . li
From: Pan Li Sorts of comments of unsigned integer SAT_ADD matching is not updated to date. This patch would like to refine it. The below test suites are passed for this patch: 1. The rv64gcv fully regression tests. 2. The x86 bootstrap tests. 3. The x86 fully regression tests. gcc/ChangeLog:

[PATCH v2 04/10] Match: Remove usadd_left_part_1 as it has only one reference [NFC]

2024-10-30 Thread pan2 . li
From: Pan Li In previous, we extract matching usadd_left_part_1 to avoid duplication. After we simplify some usadd patterns into cheap form, there will be only one reference to this matching. Thus, remove this matching pattern and unfold it to the reference place. The below test suites are pass

[PATCH v2 10/10] Test: Add testcases for form 8 of unsigned integer SAT_ADD simplify

2024-10-30 Thread pan2 . li
From: Pan Li The phiopt2 pass will also try the gimple_simplify for the form 8 of unsigned integer SAT_ADD. Thus add the testcase to make sure it will be performed in phiopt2 pass. gcc/testsuite/ChangeLog: * gcc.dg/sat_arith_simplify.h: Add test helper macros. * gcc.dg/sat_u_ad

[PATCH v2 09/10] Test: Add testcases for form 7 of unsigned integer SAT_ADD simplify

2024-10-30 Thread pan2 . li
From: Pan Li The phiopt2 pass will also try the gimple_simplify for the form 7 of unsigned integer SAT_ADD. Thus add the testcase to make sure it will be performed in phiopt2 pass. gcc/testsuite/ChangeLog: * gcc.dg/sat_arith_simplify.h: Add test helper macros. * gcc.dg/sat_u_ad

[PATCH v2 03/10] Match: Simplify branch form 8 of unsigned SAT_ADD into branchless

2024-10-30 Thread pan2 . li
From: Pan Li There are sorts of forms for the unsigned SAT_ADD. Some of them are complicated while others are cheap. This patch would like to simplify the complicated form into the cheap ones. For example as below: >From the form 8 (branch): SAT_U_ADD = x > (T)(x + y) ? -1 : (x + y). To (b

[PATCH v2 06/10] Test: Move unsigned integer SAT_ADD simplify testcases to gcc.dg

2024-10-30 Thread pan2 . li
From: Pan Li As suggested by Richard, move the SAT_ADD simplify testcases from the tree-ssa to gcc.dg. gcc/testsuite/ChangeLog: * gcc.dg/sat_arith_simplify.h: Add test macros. * gcc.dg/tree-ssa/sat_u_add-simplify-1-u16.c: Move to... * gcc.dg/sat_u_add-simplify-1-u16.c: .

Re: [PATCH] Allow BB vectorisation of scalar loop when ifcvt versioned loop is not vectorized

2024-10-30 Thread Kugan Vivekanandarajah
Hi Richard, > On 29 Oct 2024, at 8:33 pm, Richard Biener wrote: > > External email: Use caution opening links or attachments > > > On Tue, Oct 29, 2024 at 9:24 AM Kugan Vivekanandarajah > wrote: >> >> Hi Richard, >> Thanks for the review. >> >>> On 28 Oct 2024, at 9:18 pm, Richard Biener >>> w

Re: [PATCH] function: Call do_pending_stack_adjust in assign_parms [PR117296]

2024-10-30 Thread Eric Botcazou
> Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? > > 2024-10-30 Jakub Jelinek > > PR target/117296 > * function.cc (assign_parms): Call do_pending_stack_adjust. > > * gcc.target/i386/pr117296.c: New test. Looks good to me. -- Eric Botcazou

[PATCH] function: Call do_pending_stack_adjust in assign_parms [PR117296]

2024-10-30 Thread Jakub Jelinek
Hi! Functions called by assign_parms call emit_block_move in two places, so on some targets can be expanded as calls and can result in pending stack adjustment. Now, during expansion we normally call do_pending_stack_adjust at the end of expansion of each basic block or before emitting code that

[PATCH] genmatch: Fix build on hppa64-hpux [PR117348]

2024-10-30 Thread Jakub Jelinek
Hi! Apparently autoconf defines the HAVE_DECL_* macros to 0 rather than not defining them at all, so defined(HAVE_DECL_FMEMOPEN) test doesn't do much. The following patch fixes it by testing HAVE_DECL_FMEMOPEN for being non-zero instead. Bootstrapped/regtested on x86_64-linux and i686-linux, ok

Re: [PATCH v2 5/8] aarch64: Add masked-load else operands.

2024-10-30 Thread Robin Dapp
> Is that what you tried? That's what I tried, yes, but it seems that either I had a mistake in my version or I hadn't done a full rebuild. I re-built it now and it appears to work, thanks. Now just chasing an aarch64 SLP ICE with my patches still. -- Regards Robin

Re: [RFC PATCH 1/5] vect: Force alignment peeling to vectorize more early break loops

2024-10-30 Thread Richard Biener
On Tue, 29 Oct 2024, Alex Coplan wrote: > On 29/10/2024 13:39, Richard Biener wrote: > > On Mon, 28 Oct 2024, Alex Coplan wrote: > > > > > This allows us to vectorize more loops with early exits by forcing > > > peeling for alignment to make sure that we're guaranteed to be able to > > > safely r

[committed] MAINTAINERS: Added myself to write after approval and DCO.

2024-10-30 Thread Soumya AR
Pushed to trunk: 91577f0c8d955bc670ee76d1a8851df336bf240c Signed-off-by: Soumya AR ChangeLog: * MAINTAINERS: Add myself to write after approval and DCO. 0001-MAINTAINERS-Add-myself-to-write-after-approval-and-D.patch Description: 0001-MAINTAINERS-Add-myself-to-write-after-approval-an

<    1   2