Re: [PATCH v4 2/2] aarch64: Add codegen support for AdvSIMD faminmax

2024-08-20 Thread Kyrylo Tkachov
> On 20 Aug 2024, at 17:44, saurabh@arm.com wrote: > > External email: Use caution opening links or attachments > > > The AArch64 FEAT_FAMINMAX extension is optional from Armv9.2-a and > mandatory from Armv9.5-a. It introduces instructions for computing the > floating point absolute maxim

Re: [PATCH v4 1/2] aarch64: Add AdvSIMD faminmax intrinsics

2024-08-20 Thread Kyrylo Tkachov
Hi Saurabh, > On 20 Aug 2024, at 17:44, saurabh@arm.com wrote: > > External email: Use caution opening links or attachments > > > The AArch64 FEAT_FAMINMAX extension is optional from Armv9.2-a and > mandatory from Armv9.5-a. It introduces instructions for computing the > floating point abso

Re: [PATCH 3/8] tree-ifcvt: Enforce zero else value after maskload.

2024-08-20 Thread Robin Dapp
> > > When predicating a load we implicitly assume that the else value is > > > zero. In order to formalize this this patch queries the target for > > > its supported else operand and uses that for the maskload call. > > > Subsequently, if the else operand is nonzero, a cond_expr enforcing > > > a

Re: [PATCH] aarch64: Fix caller saves of VNx2QI [PR116238]

2024-08-20 Thread Kyrylo Tkachov
> On 20 Aug 2024, at 20:10, Richard Sandiford wrote: > > External email: Use caution opening links or attachments > > > The testcase contains a VNx2QImode pseudo that is live across a call > and that cannot be allocated a call-preserved register. LRA quite > reasonably tried to save it befo

[PATCH] optabs-query: Guard smallest_int_mode_for_size [PR115495].

2024-08-20 Thread Robin Dapp
Hi, in get_best_extraction_insn we use smallest_int_mode_for_size with struct_bits as size argument. In PR115495 struct_bits = 256 and we don't have a mode for that. This patch just bails for such cases. This does not happen on the current trunk anymore (so the test passes unpatched) but we've

Re: [PATCH] PR target/116365: Add user-friendly arguments to --param aarch64-autovec-preference=N

2024-08-20 Thread Kyrylo Tkachov
> On 20 Aug 2024, at 19:11, Richard Sandiford wrote: > > External email: Use caution opening links or attachments > > > Jennifer Schmitz writes: >> The param aarch64-autovec-preference=N is a useful tool for testing >> auto-vectorisation in GCC as it allows the user to force a particular >>

Re: [PATCH v4] RISC-V: Supports Profiles in '-march' option.

2024-08-20 Thread Jiawei
在 2024/8/21 3:23, Palmer Dabbelt 写道: On Mon, 19 Aug 2024 21:53:54 PDT (-0700), jia...@iscas.ac.cn wrote: Supports RISC-V profiles[1] in -march option. Default input set the profile before other formal extensions. V2: Fixes some format errors and adds code comments for parse function Thanks f

Re: [PATCH] Build/Cross: Look for target headers from include if sys-include doesn't exist

2024-08-20 Thread Sam James
YunQiang Su writes: > YunQiang Su 于2024年7月5日周五 16:14写道: >> >> Ping again. > > Ping. I can test it next week but I can't approve it. Remind me then?

Re: [PATCH] Build/Cross: Look for target headers from include if sys-include doesn't exist

2024-08-20 Thread YunQiang Su
YunQiang Su 于2024年7月5日周五 16:14写道: > > Ping again. Ping.

[PATCH] Align ix86_{move_max,store_max} with vectorizer.

2024-08-20 Thread liuhongt
When none of mprefer-vector-width, avx256_optimal/avx128_optimal, avx256_store_by_pieces/avx512_store_by_pieces is specified, GCC will set ix86_{move_max,store_max} as max available vector length except for AVX part. if (TARGET_AVX512F_P (opts->x_ix86_isa_flags) &&

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

2024-08-20 Thread Hongtao Liu
On Tue, Aug 20, 2024 at 2:50 PM Hongtao Liu wrote: > > On Tue, Aug 20, 2024 at 2:12 PM HAO CHEN GUI wrote: > > > > Hi, > > Add Hongtao Liu as the patch affects x86. > > > > 在 2024/8/20 6:32, Richard Sandiford 写道: > > > HAO CHEN GUI writes: > > >> Hi, > > >> This patch adds const0 move checki

[PATCH V5] fsra: gimple final sra pass for paramters and returns

2024-08-20 Thread Jiufu Guo
Hi, There are a few PRs (meta-bug PR101926) about accessing aggregate parameters/returns which are passed through registers. A major reason of those issues is when access the aggregate, the temporary stack slots are used without leverage the information about the incoming/outgoing registers. We

RE: [r15-3000 Regression] FAIL: gcc.target/i386/avx10_2-rounding-3.c (test for excess errors) on Linux/x86_64

2024-08-20 Thread Jiang, Haochen
The three avx10.2 related test regression are all related to the usage of -mavx10.2 -march=cascadelake, which is unavoidable warning. I am considering to change -march=cascadelake to a arch with AVX10 in the future to avoid these false alarms. Thx, Haochen > -Original Message- > From: ha

[PATCH 1/2] libstdc++: Implement P2609R3 changes to the indirect invocability concepts

2024-08-20 Thread Patrick Palka
Tested on x86_64-pc-linux-gnu, does this look OK for trunk and perhaps 14? -- >8 -- This implements the changes of this C++23 paper as a DR against C++20. Note that since the later P2538R1 "ADL-proof std::projected" which we already implement, we can't use a simple partial specialization to matc

[PATCH 2/2] libstdc++: Implement P2997R1 changes to the indirect invocability concepts

2024-08-20 Thread Patrick Palka
Tested on x86_64-pc-linux-gnu, does this look OK for trunk and perhaps 14? -- >8 -- This implements the changes of this C++26 paper as a DR against C++20. libstdc++-v3/ChangeLog: * include/bits/iterator_concepts.h (indirectly_unary_invocable): Relax as per P2997R1. (indi

Re: [PATCH v3 02/12] OpenMP: middle-end support for metadirectives

2024-08-20 Thread Sandra Loosemore
On 8/10/24 02:02, Jakub Jelinek wrote: On Sat, Aug 10, 2024 at 09:18:24AM +0200, Jakub Jelinek wrote: On Fri, Aug 09, 2024 at 07:12:48PM +0200, Jakub Jelinek wrote: --- a/gcc/gimple.def +++ b/gcc/gimple.def @@ -398,6 +398,13 @@ DEFGSCODE(GIMPLE_OMP_TEAMS, "gimple_omp_teams", GSS_OMP_PARALLEL_L

Re: [PATCH 2/2] aarch64: Implement popcountti2 pattern [PR113042]

2024-08-20 Thread Andrew Pinski
On Tue, Aug 20, 2024 at 11:18 AM Richard Sandiford wrote: > > Richard Sandiford writes: > > Andrew Pinski writes: > >> When CSSC is not enabled, 128bit popcount can be implemented > >> just via the vector (v16qi) cnt instruction followed by a reduction, > >> like how the 64bit one is currently i

Re: [PATCH 1/2] builtins: Don't expand bit query builtins for __int128_t if the target supports an optab for it

2024-08-20 Thread Andrew Pinski
On Tue, Aug 20, 2024 at 9:46 AM Richard Sandiford wrote: > > Andrew Pinski writes: > > On aarch64 (without !CSSC instructions), since popcount is implemented > > using the SIMD instruction cnt, > > instead of using two SIMD cnt (V8QI mode), it is better to use one 128bit > > cnt (V16QI mode). A

Re: [PATCH v2] ASAN: call initialize_sanitizer_builtins for hwasan [PR115205]

2024-08-20 Thread Andrew Pinski
On Sun, Aug 11, 2024 at 9:36 PM Andrew Pinski wrote: > > Sometimes initialize_sanitizer_builtins is not called before emitting > the asan builtins with hwasan. In the case of the bug report, there > was a path with the fortran front-end where it was not called. > So let's call it in asan_instrumen

[PATCH v2] aarch64: Implement popcountti2 pattern [PR113042]

2024-08-20 Thread Andrew Pinski
When CSSC is not enabled, 128bit popcount can be implemented just via the vector (v16qi) cnt instruction followed by a reduction, like how the 64bit one is currently implemented instead of splitting into 2 64bit popcount. Changes since v1: * v2: Make operand 0 be DImode instead of TImode and simpl

Re: [PATCH 0/7] v3 of libdiagnostics

2024-08-20 Thread David Malcolm
On Tue, 2024-08-20 at 11:49 +0200, Richard Biener wrote: > On Thu, Aug 15, 2024 at 8:13 PM David Malcolm > wrote: > > > > Here's v3 of my patch kit for "libdiagnostics", which makes GCC's > > diagnostics subsystem available as a shared library; see: > >   https://gcc.gnu.org/wiki/libdiagnostics >

[PATCH 3/3] c++/modules: Support decloned cdtors

2024-08-20 Thread Nathaniel Shead
Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? -- >8 -- When compiling with '-fdeclone-ctor-dtor' (enabled by default with -Os), we run into issues where we don't correctly emit the underlying functions. We also need to ensure that COMDAT constructors are marked as such before

[PATCH 2/3] c++/modules: Prevent maybe_clone_decl being called multiple times [PR115007]

2024-08-20 Thread Nathaniel Shead
Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? -- >8 -- The ICE in the linked PR is caused because maybe_clone_decl is not prepared to be called on a declaration that has already had clones created; what happens otherwise is that start_preparsed_function early exits and never se

[PATCH 1/3] c++: Handle ABI for non-polymorphic dynamic classes

2024-08-20 Thread Nathaniel Shead
Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? -- >8 -- The Itanium ABI has specific rules for when virtual tables for dynamic classes should be emitted. However we didn't consider structures with virtual inheritance but no virtual members as dynamic classes for ABI purposes; t

[pushed] doc: Specifically link to GPL v3.0 for GM2

2024-08-20 Thread Gerald Pfeifer
The generic GPL link redirects to GPL v3.0 right now, but may redirect to a different version at one point. Specifically link to the version we are using Pushed as (probably) the last change for the GM2 documentation I am aware of. Gerald gcc: * doc/gm2.texi (License): Specifically lin

Re: [PATCH v2 2/2] match: Reject non-ssa name/min invariants in gimple_extract [PR116412]

2024-08-20 Thread Jeff Law
On 8/20/24 1:14 PM, Andrew Pinski wrote: After the conversion for phiopt's conditional operand to use maybe_push_res_to_seq, it was found that gimple_extract will extract out from REALPART_EXPR/IMAGPART_EXPR/VCE and BIT_FIELD_REF, a memory load. But that extraction was not needed as memory loa

[committed] libstdc++: Remove redundant reclaration of std::optional

2024-08-20 Thread Jonathan Wakely
Tested x86_64-linux. Pushed to trunk. -- >8 -- We've already declared optional at the top of the header, so don't need to do it again. libstdc++-v3/ChangeLog: * include/std/optional: Remove redundant redeclaration. --- libstdc++-v3/include/std/optional | 3 --- 1 file changed, 3 deleti

[committed] libstdc++: Adjust testcase for constexpr placement new [PR115744]

2024-08-20 Thread Jonathan Wakely
Tested x86_64-linux. Pushed to trunk. -- >8 -- This test now fails in C++26 mode because the declaration in is constexpr and the one in the test isn't. Add constexpr to the test. libstdc++-v3/ChangeLog: PR libstdc++/115744 * testsuite/18_support/headers/new/synopsis.cc [C++26]:

[committed] libstdc++: Fix indentation of lines that follow a [[likely]] attribute

2024-08-20 Thread Jonathan Wakely
Tested x86_64-linux. Pushed to trunk. -- >8 -- libstdc++-v3/ChangeLog: * include/std/text_encoding: Fix indentation. --- libstdc++-v3/include/std/text_encoding | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libstdc++-v3/include/std/text_encoding b/libstdc++-v3/

Re: [Fortran, Patch, PR86468, v1] Fix propagation of corank to array components in derived types.

2024-08-20 Thread Harald Anlauf
Hi Andre, Am 20.08.24 um 13:52 schrieb Andre Vehreschild: Hi all, attached patch fixes an ICE in gimplify by assuring that the corank of a non-pointer, non-coarray array component in a derived type is zero. Previously (erroneously) the full corank of the type has been used. There is one excepti

Re: [PATCH v2 1/2] phi-opt: Fix for failing maybe_push_res_to_seq in factor_out_conditional_operation [PR 116409]

2024-08-20 Thread Jeff Law
On 8/20/24 1:14 PM, Andrew Pinski wrote: The code was assuming that maybe_push_res_to_seq would not fail if the gimple_extract_op returned true. But for some cases when the function is pure rather than const, then it can fail. This change moves around the code to check the result of maybe_pu

Re: [PATCH v4] RISC-V: Supports Profiles in '-march' option.

2024-08-20 Thread Palmer Dabbelt
On Mon, 19 Aug 2024 21:53:54 PDT (-0700), jia...@iscas.ac.cn wrote: Supports RISC-V profiles[1] in -march option. Default input set the profile before other formal extensions. V2: Fixes some format errors and adds code comments for parse function Thanks for Jeff Law's review and comments. V3:

[PATCH v2 2/2] match: Reject non-ssa name/min invariants in gimple_extract [PR116412]

2024-08-20 Thread Andrew Pinski
After the conversion for phiopt's conditional operand to use maybe_push_res_to_seq, it was found that gimple_extract will extract out from REALPART_EXPR/IMAGPART_EXPR/VCE and BIT_FIELD_REF, a memory load. But that extraction was not needed as memory loads are not simplified in match and simplify. S

[PATCH v2 1/2] phi-opt: Fix for failing maybe_push_res_to_seq in factor_out_conditional_operation [PR 116409]

2024-08-20 Thread Andrew Pinski
The code was assuming that maybe_push_res_to_seq would not fail if the gimple_extract_op returned true. But for some cases when the function is pure rather than const, then it can fail. This change moves around the code to check the result of maybe_push_res_to_seq instead of assuming it will alw

Re: [PATCH v11 1/4] contrib/: Add support for Cc: and Link: tags

2024-08-20 Thread Alejandro Colomar
Hi, On Tue, Aug 20, 2024 at 08:41:28PM GMT, Alejandro Colomar wrote: > contrib/ChangeLog: > > * gcc-changelog/git_commit.py: (GitCommit): There's a spurious ':' in the line above (before the '('). I've removed it for an eventual v12. > Add support for 'Cc: ' and 'Link: ' tags. > >

[PATCH v11 3/4] Merge definitions of array_type_nelts_top()

2024-08-20 Thread Alejandro Colomar
There were two identical definitions, and none of them are available where they are needed for implementing __nelementsof__. Merge them, and provide the single definition in gcc/tree.{h,cc}, where it's available for __nelementsof__, which will be added in the following commit. gcc/ChangeLog:

[PATCH v11 4/4] c: Add __nelementsof__ operator

2024-08-20 Thread Alejandro Colomar
This operator is similar to sizeof but can only be applied to an array, and returns its number of elements. FUTURE DIRECTIONS: - We should make it work with array parameters to functions, and somehow magically return the number of elements of the array, regardless of it being really a poin

[PATCH v11 2/4] gcc/: Rename array_type_nelts() => array_type_nelts_minus_one()

2024-08-20 Thread Alejandro Colomar
The old name was misleading. While at it, also rename some temporary variables that are used with this function, for consistency. Link: gcc/ChangeLog: *

[PATCH v11 1/4] contrib/: Add support for Cc: and Link: tags

2024-08-20 Thread Alejandro Colomar
contrib/ChangeLog: * gcc-changelog/git_commit.py: (GitCommit): Add support for 'Cc: ' and 'Link: ' tags. Cc: Jason Merrill Signed-off-by: Alejandro Colomar --- contrib/gcc-changelog/git_commit.py | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/contrib/gc

[PATCH v11 0/4] c: Add __nelementsof__ operator

2024-08-20 Thread Alejandro Colomar
Hi! v11 changes: - Add patch for the commit checker, to allow Cc: and Link: tags. - CC += Doug, Jason - Fix changelog entries to pass the checker, following advice from Jason to remove some colons. - Move Cc: and Link: tags to below the changelog, since thanks to the new patch 1/4 th

[PATCH] gm2: export all libc number conversion functions

2024-08-20 Thread Wilken Gottwalt
Export all string to integral and floating point number conversion functions (atof, atoi, atol, atoll, strtod, strtof, strtold, strtol, strtoll, strtoul, strtoull). gcc/gm2: * gm2-libs/libc.def: Export all string to number conversion functions. Signed-off-by: Wilken Gottwalt --- gcc/m2/

Re: [PATCH 2/2] aarch64: Implement popcountti2 pattern [PR113042]

2024-08-20 Thread Richard Sandiford
Richard Sandiford writes: > Andrew Pinski writes: >> When CSSC is not enabled, 128bit popcount can be implemented >> just via the vector (v16qi) cnt instruction followed by a reduction, >> like how the 64bit one is currently implemented instead of >> splitting into 2 64bit popcount. >> >> Build a

Re: [Committed] RISC-V: Remove testcase XFAIL

2024-08-20 Thread Edwin Lu
Thanks! Edwin On 8/19/2024 1:17 PM, Jeff Law wrote: On 8/19/24 2:14 PM, Edwin Lu wrote: The testcase has been modified to include the -fwrapv flag which now causes the test to pass. Remove the xfail exception gcc/testsuite/ChangeLog: * gcc.dg/signbit-5.c: Remove riscv xfail exception

[PATCH] aarch64: Fix caller saves of VNx2QI [PR116238]

2024-08-20 Thread Richard Sandiford
The testcase contains a VNx2QImode pseudo that is live across a call and that cannot be allocated a call-preserved register. LRA quite reasonably tried to save it before the call and restore it afterwards. Unfortunately, the target told it to do that in SImode, even though punning between SImode a

Re: [PATCH v10 1/3] gcc/: Rename array_type_nelts() => array_type_nelts_minus_one()

2024-08-20 Thread Alejandro Colomar
Hi Jason, On Mon, Aug 19, 2024 at 12:46:13PM GMT, Jason Merrill wrote: > On 8/19/24 6:58 AM, Alejandro Colomar wrote: > > > > Link: > > https://inbox.sourceware.org/gcc-patches/9fffd80-dca-2c7e-14b-6c9b509a7...@redhat.com/T/#m2f661c67c8f7b2c405c8c7fc3152dd85dc729120 > > Cc: Gabriel Ravier > > C

Re: [PATCH] Do not emit a redundant DW_TAG_lexical_block for inlined subroutines

2024-08-20 Thread Bernd Edlinger
On 8/20/24 13:00, Richard Biener wrote: > On Fri, Aug 16, 2024 at 12:49 PM Bernd Edlinger > wrote: >> >> While this already works correctly for the case when an inlined >> subroutine contains only one subrange, a redundant DW_TAG_lexical_block >> is still emitted when the subroutine has multiple b

Re: [PATCH v2 10/10] fortran: Add -finline-intrinsics flag for MINLOC/MAXLOC [PR90608]

2024-08-20 Thread Harald Anlauf
Hi Mikael, Am 20.08.24 um 11:51 schrieb Mikael Morin: Hello, Le 19/08/2024 à 21:44, Harald Anlauf a écrit : Hi Mikael, apart from patch #04/10, which did not apply cleanly here, I was able to test your patch.  It seems to work with a manual workaround (-fno-frontend-optimize) to work around t

Re: [PATCH] libcpp, v3: Add support for gnu::base64 #embed parameter

2024-08-20 Thread Joseph Myers
On Thu, 15 Aug 2024, Jakub Jelinek wrote: > +#embed __FILE__ gnu::base64(1) prefix() suffix() /* { dg-error "expected > character string literal" } */ > +#embed __FILE__ gnu::base64() prefix() suffix() /* { dg-error "expected > character string literal" } */ Maybe also test this error with a no

Re: [PATCH] PR target/116365: Add user-friendly arguments to --param aarch64-autovec-preference=N

2024-08-20 Thread Richard Sandiford
Jennifer Schmitz writes: > The param aarch64-autovec-preference=N is a useful tool for testing > auto-vectorisation in GCC as it allows the user to force a particular > strategy. So far, N could be an numerical value between 0 and 4. > This patch adds more user-friendly names to distinguish the op

Re: [PATCH 2/2] aarch64: Implement popcountti2 pattern [PR113042]

2024-08-20 Thread Richard Sandiford
Andrew Pinski writes: > When CSSC is not enabled, 128bit popcount can be implemented > just via the vector (v16qi) cnt instruction followed by a reduction, > like how the 64bit one is currently implemented instead of > splitting into 2 64bit popcount. > > Build and tested for aarch64-linux-gnu. >

[PATCH] Libquadmath: update doc for some constants

2024-08-20 Thread FX Coudert
As reported by Peter Randall, the description of three constants in libquadmath is wrong. Attached patch fixes them. OK to push? FX libquadmath/ChangeLog: * libquadmath.texi (M_LOG2Eq, M_LOG10Eq, M_2_PIq): Fix description of these constants. 0001-Libquadmath-update-doc-for

Re: [PATCH 1/2] builtins: Don't expand bit query builtins for __int128_t if the target supports an optab for it

2024-08-20 Thread Richard Sandiford
Andrew Pinski writes: > On aarch64 (without !CSSC instructions), since popcount is implemented using > the SIMD instruction cnt, > instead of using two SIMD cnt (V8QI mode), it is better to use one 128bit cnt > (V16QI mode). And only one > reduction addition instead of 2. Currently fold_builtin_

Re: [Ping x2 , Fortran, Patch, PR77518, (coarray), v4] Fix ICE in sizeof(coarray)

2024-08-20 Thread Jerry D
On 8/20/24 5:35 AM, Andre Vehreschild wrote: Hi all, pinging this patch. Regtests ok on x86_64-pc-linux-gnu / Fedora 39. Ok for mainline? Regards, Andre Your approach looks reasonable so I think OK to push. Thanks, Jerry

[r15-2997 Regression] FAIL: gcc.target/i386/avx10_2-rounding-2.c (test for excess errors) on Linux/x86_64

2024-08-20 Thread haochen.jiang
On Linux/x86_64, 6e231f8504874828b23bbe89f3ef4086dcc15a44 is the first bad commit commit 6e231f8504874828b23bbe89f3ef4086dcc15a44 Author: Hu, Lin1 Date: Mon Aug 19 10:08:59 2024 +0800 AVX10.2 ymm rounding: Support vcvtqq2p{s,d,h} and vcvttpd2{,u}{dq,qq} intrins caused FAIL: gcc.target/i

[r15-3000 Regression] FAIL: gcc.target/i386/avx10_2-rounding-3.c (test for excess errors) on Linux/x86_64

2024-08-20 Thread haochen.jiang
On Linux/x86_64, 3d1b5530ea1d23e26dc5ab70aa4a2e7b9dc19b50 is the first bad commit commit 3d1b5530ea1d23e26dc5ab70aa4a2e7b9dc19b50 Author: Hu, Lin1 Date: Mon Aug 19 10:09:03 2024 +0800 AVX10.2 ymm rounding: Support vcvt{,u}w2ph and vdivp{s,d,h} intrins caused FAIL: gcc.target/i386/avx10_2

[r15-2991 Regression] FAIL: gcc.target/i386/avx10_2-rounding-1.c (test for excess errors) on Linux/x86_64

2024-08-20 Thread haochen.jiang
On Linux/x86_64, e22e3af1954469c40b139b7cfa8e7708592f4bfd is the first bad commit commit e22e3af1954469c40b139b7cfa8e7708592f4bfd Author: Hu, Lin1 Date: Mon Aug 19 10:08:51 2024 +0800 AVX10.2 ymm rounding: Support vadd{s,d,h} and vcmp{s,d,h} intrins caused FAIL: gcc.target/i386/avx10_2-r

Re: [PATCH v3 2/7] OpenMP: middle-end support for dispatch + adjust_args

2024-08-20 Thread Paul-Antoine Arras
Hi Tobias, Thanks for the review. Please find attached an updated patch following your comments. Since further adjustments to other patches of the series were required, I'll post them shortly. See also my replies below. On 09/08/2024 13:51, Tobias Burnus wrote: Paul-Antoine Arras wrote: Thi

[PATCH] c++: local class memfn synth from noexcept context [PR113063]

2024-08-20 Thread Patrick Palka
Bootstrapped and regtested on x86_64-pc-linux-gnu, does this look OK for trunk only? -- >8 -- Extending the PR113063 testcase to additionally constant evaluate the <=> expression causes us to trip over the assert in cxx_eval_call_expression /* We used to shortcut trivial constructor/op= here,

[PATCH v4 2/2] aarch64: Add codegen support for AdvSIMD faminmax

2024-08-20 Thread saurabh.jha
The AArch64 FEAT_FAMINMAX extension is optional from Armv9.2-a and mandatory from Armv9.5-a. It introduces instructions for computing the floating point absolute maximum and minimum of the two vectors element-wise. This patch adds code generation support for famax and famin in terms of existing R

[PATCH v4 1/2] aarch64: Add AdvSIMD faminmax intrinsics

2024-08-20 Thread saurabh.jha
The AArch64 FEAT_FAMINMAX extension is optional from Armv9.2-a and mandatory from Armv9.5-a. It introduces instructions for computing the floating point absolute maximum and minimum of the two vectors element-wise. This patch introduces AdvSIMD faminmax intrinsics. The intrinsics of this extensio

[PATCH v4 0/2] Add support for AdvSIMD faminmax

2024-08-20 Thread saurabh.jha
From: Saurabh Jha This patch series is a respin of the previous patch here: https://gcc.gnu.org/pipermail/gcc-patches/2024-August/659749.html. This new version is rebased with latest master after the merging of this patch series: https://gcc.gnu.org/pipermail/gcc-patches/2024-August/660532.html.

Re: [PATCH v1] RISC-V: Fix one typo in .SAT_TRUNC test func name [NFC]

2024-08-20 Thread Jeff Law
On 8/20/24 7:11 AM, pan2...@intel.com wrote: From: Pan Li Fix one typo `sat_truc` to `sat_trunc`, as well as `SAT_TRUC` to `SAT_TRUNC`. gcc/testsuite/ChangeLog: * gcc.target/riscv/sat_arith.h: Fix SAT_TRUNC typo. * gcc.target/riscv/sat_u_trunc-1.c: Ditto. * gcc.targ

Re: [PATCH v2] c++/modules: Remove unnecessary errors when not writing compiled module

2024-08-20 Thread Jason Merrill
On 8/20/24 3:02 AM, Nathaniel Shead wrote: On Mon, Aug 19, 2024 at 12:55:22PM -0400, Jason Merrill wrote: On 8/18/24 8:11 AM, Nathaniel Shead wrote: Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? Or should we even just remove the warning entirely? I'm not sure it really adds

Re: [PATCH v4] Improve bad error message with stray semicolon in initializer (and related) [PR101232]

2024-08-20 Thread Jason Merrill
On 8/20/24 9:11 AM, Franciszek Witt wrote: Thanks for the feedback. I am attatching fixed patch as a file. Pushed, thanks. Regards Franciszek On Mon, 19 Aug 2024, 18:32 Jason Merrill, > wrote: On 8/19/24 12:01 PM, Jason Merrill wrote: > On 8/19/24 6:01 AM,

[pushed] doc: Normalize reference to binutils version for C6X

2024-08-20 Thread Gerald Pfeifer
We generally do not use a hyphen between project name and version. gcc: * doc/install.texi (Specific) : Normalize reference to binutils. --- gcc/doc/install.texi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/doc/install.texi b/gcc/doc/install.texi index 4

[PATCH] ifcvt: Do not overwrite results in noce_convert_multiple_sets [PR116372, PR116405]

2024-08-20 Thread Manolis Tsamis
Now that more operations are allowed for noce_convert_multiple_sets, it is possible that the same register appears multiple times as target in a basic block. After noce_convert_multiple_sets_1 is called we potentially also emit register moves from temporaries back to the original targets. In some

Re: [PATCH 3/8] tree-ifcvt: Enforce zero else value after maskload.

2024-08-20 Thread Richard Biener
On Tue, 13 Aug 2024, Jeff Law wrote: > > > On 8/11/24 3:00 PM, Robin Dapp wrote: > > When predicating a load we implicitly assume that the else value is > > zero. In order to formalize this this patch queries the target for > > its supported else operand and uses that for the maskload call. > >

Re: Subject: [PATCH 0/8] Masked load else operand.

2024-08-20 Thread Richard Biener
On Sun, 11 Aug 2024, Robin Dapp wrote: > I figured it's easier to parse this as a series rather than one big > patch, in particular since target-specific code is involved. > > This adds an else operand to masked-load operations in order to avoid > implicit dependencies on zeroed masked-out elemen

Re: [RFC] early vector boolean lowering

2024-08-20 Thread Richard Biener
On Tue, 20 Aug 2024, Tamar Christina wrote: > Hi, > > As you know I've been working on removing the code that demotes GIMPLE > COND_EXPR to GENERIC during vect_recog_bool_pattern. > > To restate why, The issue we currently have today is that the mask (boolean > argument of a COND_EXPR) is not al

Re: [PATCH v1] Provide new GCC builtin __builtin_get_counted_by [PR116016]

2024-08-20 Thread Qing Zhao
> On Aug 20, 2024, at 05:58, Richard Biener wrote: > > On Tue, Aug 13, 2024 at 5:34 PM Qing Zhao wrote: >> >> With the addition of the 'counted_by' attribute and its wide roll-out >> within the Linux kernel, a use case has been found that would be very >> nice to have for object allocators: b

Re: [wwwdocs] gcc-15: Mention c++ header dependency changes () in porting_to.html

2024-08-20 Thread Jonathan Wakely
On Wed, 7 Aug 2024 at 08:09, Filip Kastl wrote: > > On Tue 2024-08-06 17:00:24, Gerald Pfeifer wrote: > > > + > > > +The following headers are used less widely in libstdc++ and may need to I like Gerald's suggestion to change this to "within libstdc++" as that is more precise about that change.

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

2024-08-20 Thread Juergen Christ
Am Tue, Aug 20, 2024 at 02:51:02PM +0200 schrieb Richard Biener: > On Tue, Aug 20, 2024 at 11:16 AM Juergen Christ wrote: > > > > Am Tue, Aug 20, 2024 at 10:15:22AM +0200 schrieb Richard Biener: > > > On Fri, Aug 9, 2024 at 2:58 PM Juergen Christ > > > wrote: > > > > > > > > Am Thu, Aug 08, 2024

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

2024-08-20 Thread Jonathan Wakely
On Mon, 5 Aug 2024 at 19:36, Gerald Pfeifer wrote: > > 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 AD

Re: [PATCH 5/5] libstdc++: Restore unrolling in std::find using pragma [PR116140]

2024-08-20 Thread Jonathan Wakely
On Fri, 9 Aug 2024 at 10:29, Alex Coplan wrote: > > Together with the preparatory compiler patches, this patch restores > unrolling in std::__find_if, but this time relying on the compiler to do > it by using: > > #pragma GCC unroll 4 > > which should restore the majority of the regression relat

Re: [PATCH] Update LDPT_REGISTER_CLAIM_FILE_HOOK_V2 linker plugin hook

2024-08-20 Thread H.J. Lu
On Tue, Aug 20, 2024 at 2:03 AM Richard Biener wrote: > > On Wed, Aug 14, 2024 at 3:15 PM H.J. Lu wrote: > > > > The new hook allows the linker plugin to distinguish calls to > > claim_file_handler that know the object is being used by the linker > > (from ldmain.c:add_archive_element), from call

Re: [PATCH] (Re: Splitting up 27_io/basic_istream/ignore/wchar_t/94749.cc (takes too long))

2024-08-20 Thread Jonathan Wakely
On Wed, 14 Aug 2024 at 15:47, Hans-Peter Nilsson wrote: > > > From: Vaseeharan Vinayagamoorthy > > Date: Sat, 22 Jun 2024 01:38:09 + > > Sorry for the late reply. I sort of hoped somebody else > would chime in. Maybe the issue has resolved itself in the > meantime? > > > Hi, > > > > I have

[PATCH v1] RISC-V: Fix one typo in .SAT_TRUNC test func name [NFC]

2024-08-20 Thread pan2 . li
From: Pan Li Fix one typo `sat_truc` to `sat_trunc`, as well as `SAT_TRUC` to `SAT_TRUNC`. gcc/testsuite/ChangeLog: * gcc.target/riscv/sat_arith.h: Fix SAT_TRUNC typo. * gcc.target/riscv/sat_u_trunc-1.c: Ditto. * gcc.target/riscv/sat_u_trunc-13.c: Ditto. * gcc.ta

Re: [PATCH v4] Improve bad error message with stray semicolon in initializer (and related) [PR101232]

2024-08-20 Thread Franciszek Witt
Thanks for the feedback. I am attatching fixed patch as a file. Regards Franciszek On Mon, 19 Aug 2024, 18:32 Jason Merrill, wrote: > On 8/19/24 12:01 PM, Jason Merrill wrote: > > On 8/19/24 6:01 AM, Jonathan Wakely wrote: > >> On 05/08/24 09:32 +0200, Franciszek Witt wrote: > >>> Author: Franc

Re: [PATCH] testsuite: i386: Fix g++.target/i386/pr116275-2.C on Solaris/x86

2024-08-20 Thread Uros Bizjak
On Tue, Aug 20, 2024 at 3:06 PM Rainer Orth wrote: > > The new g++.target/i386/pr116275-2.C test FAILs on 32-bit Solaris/x86: > > FAIL: g++.target/i386/pr116275-2.C scan-assembler vpslld > > This happens because Solaris defaults to -mstackrealign, disabling -mstv. > > Fixed by disabling the for

[PATCH 2/2]middle-end: use two's complement equality when comparing IVs during candidate selection [PR114932]

2024-08-20 Thread Tamar Christina
Hi All, IVOPTS normally uses affine trees to perform comparisons between different IVs, but these seem to have been missing in two key spots and instead normal tree equivalencies used. In some cases where we have a two-complements equivalence but not a strict signedness equivalencies we end up ge

[PATCH 1/2]middle-end: refactor type to be explicit in operand_equal_p [PR114932]

2024-08-20 Thread Tamar Christina
Hi All, This is a refactoring with no expected behavioral change. The goal with this is to make the type of the expressions being used explicit. I did not change all the recursive calls to operand_equal_p () to recurse directly to the new function but instead this goes through the top level call

[PATCH] testsuite: i386: Fix g++.target/i386/pr116275-2.C on Solaris/x86

2024-08-20 Thread Rainer Orth
The new g++.target/i386/pr116275-2.C test FAILs on 32-bit Solaris/x86: FAIL: g++.target/i386/pr116275-2.C scan-assembler vpslld This happens because Solaris defaults to -mstackrealign, disabling -mstv. Fixed by disabling the former and enabling the latter. Tested on i386-pc-solaris2.11 and x8

RE: [PATCH V3 10/10] autovectorizer: Test autovectorization of different dot-prod modes.

2024-08-20 Thread Tamar Christina
> -Original Message- > From: Richard Biener > Sent: Tuesday, August 20, 2024 1:54 PM > To: Tamar Christina > Cc: Victor Do Nascimento ; gcc- > patc...@gcc.gnu.org; claz...@gmail.com; hongtao@intel.com; > s...@gcc.gnu.org; bernds_...@t-online.de; al...@redhat.com; Victor Do > Nasciment

Re: [PATCH V3 10/10] autovectorizer: Test autovectorization of different dot-prod modes.

2024-08-20 Thread Richard Biener
On Tue, Aug 20, 2024 at 12:04 PM Tamar Christina wrote: > > > -Original Message- > > From: Richard Biener > > Sent: Tuesday, August 20, 2024 10:37 AM > > To: Victor Do Nascimento > > Cc: gcc-patches@gcc.gnu.org; Tamar Christina ; > > claz...@gmail.com; hongtao@intel.com; s...@gcc.gnu

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

2024-08-20 Thread Richard Biener
On Tue, Aug 20, 2024 at 11:16 AM Juergen Christ wrote: > > Am Tue, Aug 20, 2024 at 10:15:22AM +0200 schrieb Richard Biener: > > On Fri, Aug 9, 2024 at 2:58 PM Juergen Christ wrote: > > > > > > Am Thu, Aug 08, 2024 at 02:06:44PM +0200 schrieb Richard Biener: > > > > On Mon, Aug 5, 2024 at 4:02 PM

RE: [PATCH] testsuite: Add -fwrapv to signbit-5.c

2024-08-20 Thread Tamar Christina
> -Original Message- > From: Richard Biener > Sent: Tuesday, August 20, 2024 12:33 PM > To: Torbjorn SVENSSON > Cc: Jeff Law ; gcc-patches@gcc.gnu.org; Richard > Earnshaw ; quic_apin...@quicinc.com; > yvan.r...@foss.st.com; Tamar Christina > Subject: Re: [PATCH] testsuite: Add -fwrapv to

Re: [Ping x2 , Fortran, Patch, PR77518, (coarray), v4] Fix ICE in sizeof(coarray)

2024-08-20 Thread Andre Vehreschild
Hi all, pinging this patch. Regtests ok on x86_64-pc-linux-gnu / Fedora 39. Ok for mainline? Regards, Andre On Fri, 9 Aug 2024 16:30:52 +0200 Andre Vehreschild wrote: > Ping! > > @Paul, you already had a look at this patch, but I made some changes. Or they > ok? > > - Andre > > On Fri

Re: [PATCH 1/2] phi-opt: Fix for non-const functions for factor_out_conditional_operation [PR 116409]

2024-08-20 Thread Richard Biener
On Mon, Aug 19, 2024 at 8:38 PM Andrew Pinski wrote: > > Currently maybe_push_res_to_seq does not handle non-const builtins (it does > handle internal > functions though). I think it simply assumes they are const ... if we can indeed verify this we should make it match the builtin behavior. > S

Re: [PATCH 2/2] phiopt: Reject non gimple val inside factor_out_conditional_operation [PR116412]

2024-08-20 Thread Richard Biener
On Mon, Aug 19, 2024 at 8:38 PM Andrew Pinski wrote: > > After the conversion to use maybe_push_res_to_seq, sometimes (REALPART_EXPR > and IMAGPART_EXPR and VCE) the argument will not be a gimple value and > then phiopt here would create an invalid PHI. > Just add a check for gimple val is the way

Re: [PATCH] Re-add calling emit_clobber in lower-subreg.cc's resolve_simple_move.

2024-08-20 Thread Xianmiao Qu
On Fri, Aug 16, 2024 at 10:29:23PM +0800, Xianmiao Qu wrote: > On Tue, Aug 13, 2024 at 09:58:31PM -0600, Jeff Law wrote: > > Note this changes target independent code. So it needs to be bootstrapped > > and regression tested on one of the primary platforms: > > > > > The primary platforms are: >

Re: [RFC/RFA][PATCH v3 06/12] aarch64: Implement new expander for efficient CRC computation

2024-08-20 Thread Mariam Arutunian
I sent the new version and added you as a co-author. Thanks, Mariam On Fri, Aug 16, 2024 at 7:25 PM Mariam Arutunian wrote: > > > On Fri, Aug 9, 2024 at 7:22 PM Richard Sandiford < > richard.sandif...@arm.com> wrote: > >> Sorry again for the slow review. :( >> >> I only really looked at the unr

[PATCH] PR target/116365: Add user-friendly arguments to --param aarch64-autovec-preference=N

2024-08-20 Thread Jennifer Schmitz
The param aarch64-autovec-preference=N is a useful tool for testing auto-vectorisation in GCC as it allows the user to force a particular strategy. So far, N could be an numerical value between 0 and 4. This patch adds more user-friendly names to distinguish the options. For backwards compatibility

[RFC/RFA][PATCH v4 06/12] aarch64: Implement new expander for efficient CRC computation

2024-08-20 Thread Mariam Arutunian
This patch introduces two new expanders for the aarch64 backend, dedicated to generate optimized code for CRC computations. The new expanders are designed to leverage specific hardware capabilities to achieve faster CRC calculations, particularly using the crc32, crc32c and pmull instructions when

[Fortran, Patch, PR86468, v1] Fix propagation of corank to array components in derived types.

2024-08-20 Thread Andre Vehreschild
Hi all, attached patch fixes an ICE in gimplify by assuring that the corank of a non-pointer, non-coarray array component in a derived type is zero. Previously (erroneously) the full corank of the type has been used. There is one exception for pointer typed array components in coarray derived type

Re: [PATCH v1] Vect: Promote unsigned .SAT_ADD constant operand for vectorizable_call

2024-08-20 Thread Richard Biener
On Sat, Aug 17, 2024 at 11:18 PM Jakub Jelinek wrote: > > On Sat, Aug 17, 2024 at 05:03:14AM +, Li, Pan2 wrote: > > Please feel free to let me know if there is anything I can do to fix this > > issue. Thanks a lot. > > There is no bug. The operands of .{ADD,SUB,MUL}_OVERFLOW don't have to ha

Re: [PATCH] libcpp: Adjust lang_defaults

2024-08-20 Thread Richard Biener
On Fri, Aug 16, 2024 at 7:58 PM Jakub Jelinek wrote: > > Hi! > > Here it is in patch form, at the same time I've turned it into bit-fields. > On x86_64-linux, this reduced .rodata by 532 bytes (so 5.75x reduction > of the variable) and grew the cpp_set_lang function by 26 bytes (8.4% > growth). >

Re: [RFC/RFA] [PATCH v2 09/12] Add symbolic execution support.

2024-08-20 Thread Richard Biener
On Fri, Aug 16, 2024 at 4:33 PM Jeff Law wrote: > > > > On 8/12/24 5:13 AM, Matevos Mehrabyan wrote: > > > > On Fri, Aug 2, 2024, 14:25 Richard Biener > > mailto:richard.guent...@gmail.com>> wrote: > > > On Wed, Jul 31, 2024 at 12:42 PM Mariam Arutunian > > > mailto:mariamarutun.

Re: [PATCH] testsuite: Add -fwrapv to signbit-5.c

2024-08-20 Thread Richard Biener
On Fri, Aug 16, 2024 at 4:30 PM Torbjorn SVENSSON wrote: > > > > On 2024-08-16 16:07, Jeff Law wrote: > > > > > > On 8/16/24 4:12 AM, Torbjörn SVENSSON wrote: > >> Ok for trunk and releases/gcc-14? > >> > >> Verified this on x86_64 and arm-none-eabi. > >> Don't know if the other "truth type" dg-li

Re: [PATCH] Align predicates for operands[1] between mov and *mov_internal.

2024-08-20 Thread Uros Bizjak
On Tue, Aug 20, 2024 at 12:25 PM liuhongt wrote: > > From [1] > > > It's not obvious to me why movv16qi requires a nonimmediate_operand > > > source, especially since ix86_expand_vector_mode does have code to > > > cope with constant operand[1]s. emit_move_insn_1 doesn't check the > > > predicate

Re: [PATCH] Do not emit a redundant DW_TAG_lexical_block for inlined subroutines

2024-08-20 Thread Richard Biener
On Fri, Aug 16, 2024 at 12:49 PM Bernd Edlinger wrote: > > While this already works correctly for the case when an inlined > subroutine contains only one subrange, a redundant DW_TAG_lexical_block > is still emitted when the subroutine has multiple blocks. Huh. The point is that the inline conte

  1   2   >