Re: [PATCH] ipa: Remove ipa_bits

2023-10-05 Thread Richard Biener
On Thu, 5 Oct 2023, Jakub Jelinek wrote: > Hi! > > The following patch removes ipa_bits struct pointer/vector from ipa > jump functions and ipa cp transformations. > > The reason is because the struct uses widest_int to represent > mask/value pair, which in the RFC patches to allow larger

[Committed] RISC-V: Use stdint-gcc.h in rvv testsuite

2023-10-05 Thread Patrick O'Neill
Committed, thanks! Patrick On 10/5/23 17:51, Kito Cheng wrote: LGTM Patrick O'Neill 於 2023年10月6日 週五 07:46 寫道: stdint.h can be replaced with stdint-gcc.h to resolve some missing system headers in non-multilib installations. Tested using glibc rv32gcv and rv64gcv on

[Bug c++/111712] New: Syntax error when passing function parameter as NTTP in requires-clause

2023-10-05 Thread hewillk at gmail dot com via Gcc-bugs
requires { typename std::bool_constant; }; | ^ In file included from :1: /opt/compiler-explorer/gcc-trunk-20231005/include/c++/14.0.0/type_traits:120:11: note: 'template using std::bool_constant = std::__bool_constant<__v>' declared here

Re: [V3][PATCH 0/3] New attribute "counted_by" to annotate bounds for C99 FAM(PR108896)

2023-10-05 Thread Martin Uecker
Am Donnerstag, dem 05.10.2023 um 15:35 -0700 schrieb Kees Cook: > On Thu, Oct 05, 2023 at 04:08:52PM -0400, Siddhesh Poyarekar wrote: > > 2. How would you handle signedness of the size field? The size gets > > converted to sizetype everywhere it is used and overflows/underflows may > > produce

[Bug target/111260] arm: ice in maybe_legitimize_operand, at optabs.cc:8054

2023-10-05 Thread zsojka at seznam dot cz via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111260 --- Comment #4 from Zdenek Sojka --- (In reply to Andrew Pinski from comment #3) > (In reply to Zdenek Sojka from comment #2) ... > > ... > > That is 100% a different bug and should be filed separately. Than you for checking, I've created

[Bug rtl-optimization/111711] New: [14 Regression] ICE: in maybe_legitimize_operand, at optabs.cc:8046 at -O1 with division by zero

2023-10-05 Thread zsojka at seznam dot cz via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111711 Bug ID: 111711 Summary: [14 Regression] ICE: in maybe_legitimize_operand, at optabs.cc:8046 at -O1 with division by zero Product: gcc Version: 14.0 Status: UNCONFIRMED

[Bug target/111260] arm: ice in maybe_legitimize_operand, at optabs.cc:8054

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111260 --- Comment #3 from Andrew Pinski --- (In reply to Zdenek Sojka from comment #2) > Different testcase: > $ cat testcase.c > long > bar (long x) > { > x *= x == 0 / 0; > return (x); > } > > long > foo (void) > { > return bar (822920); > }

[Bug target/111260] arm: ice in maybe_legitimize_operand, at optabs.cc:8054

2023-10-05 Thread zsojka at seznam dot cz via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111260 Zdenek Sojka changed: What|Removed |Added CC||zsojka at seznam dot cz --- Comment #2

RE: [PATCH v1] RISC-V: Update comments for FP rounding related autovec

2023-10-05 Thread Li, Pan2
Committed, thanks Kito. Pan From: Kito Cheng Sent: Friday, October 6, 2023 11:09 AM To: Li, Pan2 Cc: GCC Patches ; 钟居哲 ; Wang, Yanzhang Subject: Re: [PATCH v1] RISC-V: Update comments for FP rounding related autovec LGTM mailto:pan2...@intel.com>> 於 2023年10月6日 週五 10:39 寫道: From: Pan Li

Re: [PATCH v1] RISC-V: Update comments for FP rounding related autovec

2023-10-05 Thread Kito Cheng
LGTM 於 2023年10月6日 週五 10:39 寫道: > From: Pan Li > > Some comment is out of date, this patch would like to fix it. > > gcc/ChangeLog: > > * config/riscv/autovec.md: Update comments. > > Signed-off-by: Pan Li > --- > gcc/config/riscv/autovec.md | 6 +- > 1 file changed, 5

[Bug ipa/111672] Inappropriate function splitting during pass_split_functions

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111672 --- Comment #12 from Andrew Pinski --- (In reply to Hanke Zhang from comment #11) > But I have never seen this '_FORTIFY_SOURCE' before. So I'm a confused as > well. And when I try gcc@11.4 built in the default ubuntu 22.04, it's the > same. So

[Bug ipa/111672] Inappropriate function splitting during pass_split_functions

2023-10-05 Thread hkzhang455 at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111672 --- Comment #11 from Hanke Zhang --- (In reply to Andrew Pinski from comment #10) > The difference between the 2 is the costing of the __printf_chk/puts: > _FORTIFY_SOURCE case: > freq:0.20 size: 3 time:2.43 __printf_chk (1, "Object code

[PATCH v1] RISC-V: Update comments for FP rounding related autovec

2023-10-05 Thread pan2 . li
From: Pan Li Some comment is out of date, this patch would like to fix it. gcc/ChangeLog: * config/riscv/autovec.md: Update comments. Signed-off-by: Pan Li --- gcc/config/riscv/autovec.md | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git

RE: [PATCH]middle-end: Recursively check is_trivially_copyable_or_pair in vec.h

2023-10-05 Thread Tamar Christina
> > On Thu, Oct 05, 2023 at 02:01:40PM +, Tamar Christina wrote: > > gcc/ChangeLog: > > > > * tree-if-conv.cc (INCLUDE_ALGORITHM): Remove. > > (typedef struct ifcvt_arg_entry): New. > > (cmp_arg_entry): New. > > (gen_phi_arg_condition, gen_phi_nest_statement, > >

[Bug c++/100825] function signature constraints are not a part of mangled name

2023-10-05 Thread jason at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100825 Jason Merrill changed: What|Removed |Added Status|NEW |ASSIGNED Assignee|unassigned

Re: [PATCH v2] RISC-V: Use stdint-gcc.h in rvv testsuite

2023-10-05 Thread Kito Cheng
LGTM Patrick O'Neill 於 2023年10月6日 週五 07:46 寫道: > stdint.h can be replaced with stdint-gcc.h to resolve some missing > system headers in non-multilib installations. > > Tested using glibc rv32gcv and rv64gcv on r14-4381-g7eb5ce7f58e. > > gcc/testsuite/ChangeLog: > > *

[PATCH v2] RISC-V: Use stdint-gcc.h in rvv testsuite

2023-10-05 Thread Patrick O'Neill
stdint.h can be replaced with stdint-gcc.h to resolve some missing system headers in non-multilib installations. Tested using glibc rv32gcv and rv64gcv on r14-4381-g7eb5ce7f58e. gcc/testsuite/ChangeLog: * gcc.target/riscv/rvv/autovec/cond/cond_convert_float2float-1.h: Replace

[Bug middle-end/111632] gcc fails to bootstrap when using libc++

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111632 Andrew Pinski changed: What|Removed |Added Summary|gcc's C++ components fail |gcc fails to bootstrap when

[Bug c++/111703] [12/13/14 Regression] [C++20]Compiler fails when using generic lambda in specific situation

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111703 Andrew Pinski changed: What|Removed |Added Last reconfirmed||2023-10-05

Re: [V3][PATCH 0/3] New attribute "counted_by" to annotate bounds for C99 FAM(PR108896)

2023-10-05 Thread Siddhesh Poyarekar
On 05-Oct-2023 18:35, Kees Cook wrote:On Thu, Oct 05, 2023 at 04:08:52PM -0400, Siddhesh Poyarekar wrote: > 2. How would you handle signedness of the size field?  The size gets > converted to sizetype everywhere it is used and overflows/underflows may > produce interesting results.  Do you

[Bug middle-end/111699] [14 Regression] ICE: SIGSEGV: infinite recursion in fold_build3_loc/fold_ternary_loc/generic_simplify_VEC_COND_EXPR

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111699 Andrew Pinski changed: What|Removed |Added Keywords||patch URL|

[PATCH] MATCH: Fix infinite loop between `vec_cond(vec_cond(a, b, 0), c, d)` and `a & b`

2023-10-05 Thread Andrew Pinski
Match has a pattern which converts `vec_cond(vec_cond(a,b,0), c, d)` into `vec_cond(a & b, c, d)` but since in this case a is a comparison fold will change `a & b` back into `vec_cond(a,b,0)` which causes an infinite loop. The best way to fix this is to enable the patterns for

Re: [PATCH] RISC-V: Use stdint-gcc.h in rvv testsuite

2023-10-05 Thread Jeff Law
On 10/3/23 14:58, Patrick O'Neill wrote: On 10/2/23 06:57, Kito Cheng wrote: On Tue, Sep 26, 2023 at 10:59 AM Patrick O'Neill wrote: stdint.h can be replaced with stdint-gcc.h to resolve some missing system headers in non-multilib installations. Tested using glibc rv32gcv and rv64gcv on

Re: [PATCH V2] Emit funcall external declarations only if actually used.

2023-10-05 Thread Jeff Law
On 10/5/23 16:17, Richard Sandiford wrote: "Jose E. Marchesi" writes: ping I don't know this code very well, and have AFAIR haven't worked with an assembler that requires external declarations, but since it's at a second ping :) ping [Differences from V1: - Prototype for

gcc-11-20231005 is now available

2023-10-05 Thread GCC Administrator via Gcc
Snapshot gcc-11-20231005 is now available on https://gcc.gnu.org/pub/gcc/snapshots/11-20231005/ and on various mirrors, see http://gcc.gnu.org/mirrors.html for details. This snapshot has been generated from the GCC 11 git branch with the following options: git://gcc.gnu.org/git/gcc.git branch

Re: [V3][PATCH 0/3] New attribute "counted_by" to annotate bounds for C99 FAM(PR108896)

2023-10-05 Thread Kees Cook
On Thu, Oct 05, 2023 at 04:08:52PM -0400, Siddhesh Poyarekar wrote: > 2. How would you handle signedness of the size field? The size gets > converted to sizetype everywhere it is used and overflows/underflows may > produce interesting results. Do you want to limit the types to unsigned or > do

[Bug c++/67343] C++ mangler does not follow ABI for unresolved names in expressions

2023-10-05 Thread jason at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67343 Jason Merrill changed: What|Removed |Added CC||yedeng.yd at linux dot alibaba.com ---

[Bug c++/109887] Different mangled name for template specialization for clang and gcc

2023-10-05 Thread jason at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109887 Jason Merrill changed: What|Removed |Added CC||jason at gcc dot gnu.org

[Committed] RISC-V: Test memcpy inlined on riscv_v

2023-10-05 Thread Patrick O'Neill
On 10/5/23 15:14, Jeff Law wrote: On 10/4/23 16:55, Patrick O'Neill wrote: Since r14-4358-g9464e72bcc9 riscv_v targets use vector instructions to perform a memcpy. We no longer expect memcpy for riscv_v targets. gcc/testsuite/ChangeLog: * gcc.dg/pr90263.c: Skip riscv_v targets. *

Re: [PATCH V2] Emit funcall external declarations only if actually used.

2023-10-05 Thread Richard Sandiford
"Jose E. Marchesi" writes: > ping I don't know this code very well, and have AFAIR haven't worked with an assembler that requires external declarations, but since it's at a second ping :) > >> ping >> >>> [Differences from V1: >>> - Prototype for call_from_call_insn moved before comment block.

Re: [PATCH v2] RISC-V: Test memcpy inlined on riscv_v

2023-10-05 Thread Jeff Law
On 10/4/23 16:55, Patrick O'Neill wrote: Since r14-4358-g9464e72bcc9 riscv_v targets use vector instructions to perform a memcpy. We no longer expect memcpy for riscv_v targets. gcc/testsuite/ChangeLog: * gcc.dg/pr90263.c: Skip riscv_v targets. *

[Bug c++/100135] [modules] ICE when using constants in a module

2023-10-05 Thread nicolas.werner at hotmail dot de via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100135 --- Comment #2 from Nicolas Werner --- Possibly the gcc behaviour here is correct. There is a clang bug open for it not rejecting calls to functions with default parameters, when the default parameter is not exported:

Re: [RFC] GNU Vector Extension -- Packed Boolean Vectors

2023-10-05 Thread Matthias Kretz
On Wednesday, 26 July 2023 06:33:41 MDT Richard Biener wrote: > Btw, how the experimental SIMD C++ standard library handles > these issue might be also interesting to research (author CCed) I only skimmed over this thread now. FWIW, I would really like better support for AVX-512 bitmasks for the

RE: [PATCH]AArch64 Add SVE implementation for cond_copysign.

2023-10-05 Thread Tamar Christina
> -Original Message- > From: Richard Sandiford > Sent: Thursday, October 5, 2023 9:26 PM > To: Tamar Christina > Cc: gcc-patches@gcc.gnu.org; nd ; Richard Earnshaw > ; Marcus Shawcroft > ; Kyrylo Tkachov > Subject: Re: [PATCH]AArch64 Add SVE implementation for cond_copysign. > > Tamar

Re: [PATCH]AArch64 Add SVE implementation for cond_copysign.

2023-10-05 Thread Andrew Pinski
On Thu, Oct 5, 2023 at 12:48 PM Tamar Christina wrote: > > > -Original Message- > > From: Richard Sandiford > > Sent: Thursday, October 5, 2023 8:29 PM > > To: Tamar Christina > > Cc: gcc-patches@gcc.gnu.org; nd ; Richard Earnshaw > > ; Marcus Shawcroft > > ; Kyrylo Tkachov > >

[Bug regression/111709] [13 Regression] Miscompilation of sysdeps/ieee754/dbl-64/s_fma.c

2023-10-05 Thread joseph at codesourcery dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111709 --- Comment #8 from joseph at codesourcery dot com --- Typically these sorts of issues result from floating-point operations being moved past environment manipulation (fesetround, feupdateenv, feholdexcept, etc.) - in either direction. This

[Bug c++/100135] [modules] ICE when using constants in a module

2023-10-05 Thread nicolas.werner at hotmail dot de via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100135 Nicolas Werner changed: What|Removed |Added CC||nicolas.werner at hotmail dot de ---

Re: [PATCH]AArch64 Add SVE implementation for cond_copysign.

2023-10-05 Thread Richard Sandiford
Tamar Christina writes: >> -Original Message- >> From: Richard Sandiford >> Sent: Thursday, October 5, 2023 8:29 PM >> To: Tamar Christina >> Cc: gcc-patches@gcc.gnu.org; nd ; Richard Earnshaw >> ; Marcus Shawcroft >> ; Kyrylo Tkachov >> Subject: Re: [PATCH]AArch64 Add SVE

[Bug c/108896] provide "element_count" attribute to give more context to __builtin_dynamic_object_size() and -fsanitize=bounds

2023-10-05 Thread muecker at gwdg dot de via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108896 --- Comment #48 from Martin Uecker --- Indicating a null terminated string should certainly use a different attribute name.

[committed] hppa: Delete MALLOC_ABI_ALIGNMENT define from pa32-linux.h

2023-10-05 Thread John David Anglin
In spite of what the comment says, the MALLOC_ALIGNMENT in glibc for 32-bit hppa-linux has always been 8, not 16. There is no reason to increase it as the old linux threads implementation has been removed. So, we can use default in pa.h. Dave --- Delete MALLOC_ABI_ALIGNMENT define from

Re: [V3][PATCH 0/3] New attribute "counted_by" to annotate bounds for C99 FAM(PR108896)

2023-10-05 Thread Siddhesh Poyarekar
On 2023-08-25 11:24, Qing Zhao wrote: This is the 3rd version of the patch, per our discussion based on the review comments for the 1st and 2nd version, the major changes in this version are: Hi Qing, I hope the review was helpful. Overall, a couple of things to consider: 1. How would you

Re: [V3][PATCH 2/3] Use the counted_by atribute info in builtin object size [PR108896]

2023-10-05 Thread Siddhesh Poyarekar
On 2023-08-25 11:24, Qing Zhao wrote: Use the counted_by atribute info in builtin object size to compute the subobject size for flexible array members. gcc/ChangeLog: PR C/108896 * tree-object-size.cc (addr_object_size): Use the counted_by attribute info. *

[Bug c/108896] provide "element_count" attribute to give more context to __builtin_dynamic_object_size() and -fsanitize=bounds

2023-10-05 Thread tg at mirbsd dot org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108896 Thorsten Glaser changed: What|Removed |Added CC||tg at mirbsd dot org --- Comment #47

RE: [PATCH]AArch64 Add SVE implementation for cond_copysign.

2023-10-05 Thread Tamar Christina
> -Original Message- > From: Richard Sandiford > Sent: Thursday, October 5, 2023 8:29 PM > To: Tamar Christina > Cc: gcc-patches@gcc.gnu.org; nd ; Richard Earnshaw > ; Marcus Shawcroft > ; Kyrylo Tkachov > Subject: Re: [PATCH]AArch64 Add SVE implementation for cond_copysign. > > Tamar

Re: [PATCH]AArch64 Add special patterns for creating DI scalar and vector constant 1 << 63 [PR109154]

2023-10-05 Thread Richard Sandiford
Tamar Christina writes: > Hi, > >> The lowpart_subreg should simplify this back into CONST0_RTX (mode), >> making it no different from: >> >> emti_move_insn (target, CONST0_RTX (mode)); >> >> If the intention is to share zeros between modes (sounds good!), then I think >> the subreg needs

Re: LRA for avr: Maintain live range info for pseudos assigned to FP?

2023-10-05 Thread Vladimir Makarov via Gcc
On 9/7/23 07:21, senthilkumar.selva...@microchip.com wrote: Hi, One more execution failure for the avr target, this time from gcc.c-torture/execute/bitfld-3.c. Steps to reproduce Enable LRA in avr.cc by removing TARGET_LRA_P hook, build with $ make all-host && make

Re: [V3][PATCH 1/3] Provide counted_by attribute to flexible array member field (PR108896)

2023-10-05 Thread Siddhesh Poyarekar
On 2023-10-05 14:51, Siddhesh Poyarekar wrote: On 2023-08-25 11:24, Qing Zhao wrote: Provide a new counted_by attribute to flexible array member field. The obligatory "I can't ack the patch but here's a review" disclaimer :) 'counted_by (COUNT)'   The 'counted_by' attribute may be

Re: [PATCH]AArch64 Add SVE implementation for cond_copysign.

2023-10-05 Thread Richard Sandiford
Tamar Christina writes: > Hi All, > > This adds an implementation for masked copysign along with an optimized > pattern for masked copysign (x, -1). It feels like we're ending up with a lot of AArch64-specific code that just hard-codes the observation that changing the sign is equivalent to

[Bug libstdc++/111685] Segfault while sorting on array element address

2023-10-05 Thread knoepfel at fnal dot gov via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111685 Kyle Knoepfel changed: What|Removed |Added Resolution|--- |INVALID Status|UNCONFIRMED

[Bug middle-end/111699] [14 Regression] ICE: SIGSEGV: infinite recursion in fold_build3_loc/fold_ternary_loc/generic_simplify_VEC_COND_EXPR

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111699 Andrew Pinski changed: What|Removed |Added Assignee|unassigned at gcc dot gnu.org |pinskia at gcc dot gnu.org

[COMMITTED 0/3] Add a FAST VRP pass.

2023-10-05 Thread Andrew MacLeod
the following set of 3 patches provide the infrastructure for a fast vrp pass. The pass is currently not invoked anywhere, but I wanted to get the infrastructure bits in place now... just in case we want to use it somewhere. It clearly bootstraps with no regressions since it isn't being

[COMMITTED 3/3] Create a fast VRP pass

2023-10-05 Thread Andrew MacLeod
This patch adds a fast VRP pass.  It is not invoked from anywhere, so should cause no issues. If you want to utilize it, simply add a new pass, ie: --- a/gcc/passes.def +++ b/gcc/passes.def @@ -92,6 +92,7 @@ along with GCC; see the file COPYING3.  If not see   NEXT_PASS (pass_phiprop);

[COMMITTED 1/3] Add outgoing range vector calculation API.

2023-10-05 Thread Andrew MacLeod
This patch adds 2 routine that can be called to generate GORI information. The primar API is: bool gori_on_edge (class ssa_cache , edge e, range_query *query = NULL, gimple_outgoing_range *ogr = NULL); This will populate an ssa-cache R with any ranges that are generated by edge E.   It will

[COMMITTED 2/3] Add a dom based ranger for fast VRP.

2023-10-05 Thread Andrew MacLeod
This patch adds a DOM based ranger that is intended to be used by a dom walk pass and provides basic ranges. It utilizes the new GORI edge API to find outgoing ranges on edges, and combines these with any ranges calculated during the walk up to this point.  When a query is made for a range

[Bug c++/111710] [modules] ICE when compiling module where a lambda is assigned to a field in an exported class

2023-10-05 Thread nicolas.werner at hotmail dot de via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111710 --- Comment #2 from Nicolas Werner --- I don't really have sufficient knowledge to push this patch forward, since that currently exceeds my skillset. As such I have no confidence this patch is actually doing something beneficial, which is why I

[Bug c++/111710] [modules] ICE when compiling module where a lambda is assigned to a field in an exported class

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111710 --- Comment #1 from Andrew Pinski --- Patches should be sent to gcc-patches@ after reading https://gcc.gnu.org/contribute.html .

Re: [V3][PATCH 1/3] Provide counted_by attribute to flexible array member field (PR108896)

2023-10-05 Thread Siddhesh Poyarekar
On 2023-08-25 11:24, Qing Zhao wrote: Provide a new counted_by attribute to flexible array member field. The obligatory "I can't ack the patch but here's a review" disclaimer :) 'counted_by (COUNT)' The 'counted_by' attribute may be attached to the flexible array member of a

[Bug c++/111710] New: [modules] ICE when compiling module where a lambda is assigned to a field in an exported class

2023-10-05 Thread nicolas.werner at hotmail dot de via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111710 Bug ID: 111710 Summary: [modules] ICE when compiling module where a lambda is assigned to a field in an exported class Product: gcc Version: 14.0 Status: UNCONFIRMED

Re: [PATCH]AArch64 Handle copysign (x, -1) expansion efficiently

2023-10-05 Thread Andrew Pinski
On Thu, Oct 5, 2023 at 11:22 AM Tamar Christina wrote: > > Hi All, > > copysign (x, -1) is effectively fneg (abs (x)) which on AArch64 can be > most efficiently done by doing an OR of the signbit. > > The middle-end will optimize fneg (abs (x)) now to copysign as the > canonical form and so this

[Bug regression/111709] [13 Regression] Miscompilation of sysdeps/ieee754/dbl-64/s_fma.c

2023-10-05 Thread danglin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111709 John David Anglin changed: What|Removed |Added CC||jsm28 at gcc dot gnu.org ---

[PATCH]AArch64 Add SVE implementation for cond_copysign.

2023-10-05 Thread Tamar Christina
Hi All, This adds an implementation for masked copysign along with an optimized pattern for masked copysign (x, -1). Bootstrapped Regtested on aarch64-none-linux-gnu and no issues. Ok for master? Thanks, Tamar gcc/ChangeLog: PR tree-optimization/109154 *

[PATCH]middle-end ifcvt: Add support for conditional copysign

2023-10-05 Thread Tamar Christina
Hi All, This adds a masked variant of copysign. Nothing very exciting just the general machinery to define and use a new masked IFN. Bootstrapped Regtested on aarch64-none-linux-gnu and no issues. Note: This patch is part of a testseries and tests for it are added in the AArch64 patch that

[PATCH]AArch64 Handle copysign (x, -1) expansion efficiently

2023-10-05 Thread Tamar Christina
Hi All, copysign (x, -1) is effectively fneg (abs (x)) which on AArch64 can be most efficiently done by doing an OR of the signbit. The middle-end will optimize fneg (abs (x)) now to copysign as the canonical form and so this optimizes the expansion. If the target has an inclusive-OR that takes

[PATCH]middle-end ifcvt: Allow any const IFN in conditional blocks

2023-10-05 Thread Tamar Christina
Hi All, When ifcvt was initially added masking was not a thing and as such it was rather conservative in what it supported. For builtins it only allowed C99 builtin functions which it knew it can fold away. These days the vectorizer is able to deal with needing to mask IFNs itself.

RE: [PATCH]AArch64 Add special patterns for creating DI scalar and vector constant 1 << 63 [PR109154]

2023-10-05 Thread Tamar Christina
Hi, > The lowpart_subreg should simplify this back into CONST0_RTX (mode), > making it no different from: > > emti_move_insn (target, CONST0_RTX (mode)); > > If the intention is to share zeros between modes (sounds good!), then I think > the subreg needs to be on the lhs instead. > > > +

RE: [PATCH]AArch64: Use SVE unpredicated LOGICAL expressions when Advanced SIMD inefficient [PR109154]

2023-10-05 Thread Tamar Christina
> >> > >> The WIP SME patches add a %Z modifier for 'z' register prefixes, > >> similarly to b/h/s/d for scalar FP. With that I think the alternative can > >> be: > >> > >> [w , 0 , ; * , sve ] \t%Z0., %Z0., #%2 > >> > >> although it would be nice to keep the hex constant. > > > >

[Bug c/111708] Calling external global function instead of local static function.

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111708 --- Comment #2 from Andrew Pinski --- Note ICC rejects this as invalid: ``` (14): error #172: external/internal linkage conflict with previous declaration at line 10 int f(int); ^ ``` Which is what I had expected to

RE: [PATCH]middle-end match.pd: optimize fneg (fabs (x)) to x | (1 << signbit(x)) [PR109154]

2023-10-05 Thread Tamar Christina
> I suppose the idea is that -abs(x) might be easier to optimize with other > patterns (consider a - copysign(x,...), optimizing to a + abs(x)). > > For abs vs copysign it's a canonicalization, but (negate (abs @0)) is less > canonical than copysign. > > > Should I try removing this? > > I'd

RE: [PATCH]middle-end match.pd: optimize fneg (fabs (x)) to x | (1 << signbit(x)) [PR109154]

2023-10-05 Thread Tamar Christina
> > b17e1136600a 100644 > > --- a/gcc/match.pd > > +++ b/gcc/match.pd > > @@ -9476,3 +9476,57 @@ and, > > } > > (if (full_perm_p) > > (vec_perm (op@3 @0 @1) @3 @2)) > > + > > +/* Transform fneg (fabs (X)) -> X | 1 << signbit (X). */ > > + > > +(simplify > > + (negate (abs

[Bug c/111708] Calling external global function instead of local static function.

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111708 Andrew Pinski changed: What|Removed |Added See Also||https://gcc.gnu.org/bugzill

[Bug regression/111709] [13 Regression] Miscompilation of sysdeps/ieee754/dbl-64/s_fma.c

2023-10-05 Thread danglin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111709 --- Comment #6 from John David Anglin --- Created attachment 56062 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=56062=edit Diff between s_fma_12.s and s_fma_13.s

[Bug regression/111709] [13 Regression] Miscompilation of sysdeps/ieee754/dbl-64/s_fma.c

2023-10-05 Thread danglin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111709 --- Comment #5 from John David Anglin --- Created attachment 56061 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=56061=edit non pic .s file for s_fma.c generated using gcc-13 without debug info

[Bug target/108396] [12/13 Regression] PPCLE: vec_vsubcuq missing since r12-5752-gd08236359eb229

2023-10-05 Thread carll at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108396 Carl Love changed: What|Removed |Added CC||carll at gcc dot gnu.org --- Comment #9

[Bug regression/111709] [13 Regression] Miscompilation of sysdeps/ieee754/dbl-64/s_fma.c

2023-10-05 Thread danglin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111709 --- Comment #4 from John David Anglin --- Created attachment 56060 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=56060=edit non pic .s file for s_fma.c generated using gcc-12 without debug info

[Bug regression/111709] [13 Regression] Miscompilation of sysdeps/ieee754/dbl-64/s_fma.c

2023-10-05 Thread danglin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111709 --- Comment #3 from John David Anglin --- Created attachment 56059 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=56059=edit .s file for s_fma.c generated using gcc-13

[Bug regression/111709] [13 Regression] Miscompilation of sysdeps/ieee754/dbl-64/s_fma.c

2023-10-05 Thread danglin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111709 --- Comment #2 from John David Anglin --- Created attachment 56058 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=56058=edit .s file for s_fma.c generated using gcc-12

[Bug regression/111709] [13 Regression] Miscompilation of sysdeps/ieee754/dbl-64/s_fma.c

2023-10-05 Thread danglin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111709 --- Comment #1 from John David Anglin --- Created attachment 56057 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=56057=edit Preprocessed source generated using gcc-13

[Bug middle-end/111699] [14 Regression] ICE: SIGSEGV: infinite recursion in fold_build3_loc/fold_ternary_loc/generic_simplify_VEC_COND_EXPR

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111699 Andrew Pinski changed: What|Removed |Added Keywords|needs-bisection | --- Comment #3 from Andrew Pinski

[Bug regression/111709] New: [13 Regression] Miscompilation of sysdeps/ieee754/dbl-64/s_fma.c

2023-10-05 Thread danglin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111709 Bug ID: 111709 Summary: [13 Regression] Miscompilation of sysdeps/ieee754/dbl-64/s_fma.c Product: gcc Version: 13.1.0 Status: UNCONFIRMED Severity: normal

[Bug libstdc++/92798] -fshort-enums can break iterators of std::map

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92798 --- Comment #5 from Andrew Pinski --- (In reply to Joseph Tilahun from comment #4) > Is there a reason why the _Rb_tree_color > enum does not have an explicit underlying type? Yes because it has to work with C++98 while enums with underlying

[Bug c/111708] New: Calling external global function instead of local static function.

2023-10-05 Thread k.frolov at samsung dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111708 Bug ID: 111708 Summary: Calling external global function instead of local static function. Product: gcc Version: 14.0 Status: UNCONFIRMED Severity: normal

[Bug libstdc++/92798] -fshort-enums can break iterators of std::map

2023-10-05 Thread josephttilahun at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92798 Joseph Tilahun changed: What|Removed |Added CC||josephttilahun at gmail dot com ---

[Bug middle-end/111699] [14 Regression] ICE: SIGSEGV: infinite recursion in fold_build3_loc/fold_ternary_loc/generic_simplify_VEC_COND_EXPR

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111699 --- Comment #2 from Andrew Pinski --- (simplify (vec_cond (vec_cond:s @0 @3 integer_zerop) @1 @2) (if (optimize_vectors_before_lowering_p () && types_match (@0, @3)) (vec_cond (bit_and @0 @3) @1 @2))) goes into an infinite loop with

[Patch] libgomp.texi: Document some of the device-memory routines

2023-10-05 Thread Tobias Burnus
I was checking one of those functions - and now ended up documenting some of them. Still to be documented are omp_target_{is_accessible,memcpy*}. I did run into some possibly questionable code for corner cases and have filed https://gcc.gnu.org/PR111707 for those. The documentation matches the

[Bug libgomp/111707] New: omp_target_alloc and omp_target_is_present - corner case handling & spec conformance

2023-10-05 Thread burnus at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111707 Bug ID: 111707 Summary: omp_target_alloc and omp_target_is_present - corner case handling & spec conformance Product: gcc Version: 14.0 Status: UNCONFIRMED

[Bug middle-end/111699] [14 Regression] ICE: SIGSEGV: infinite recursion in fold_build3_loc/fold_ternary_loc/generic_simplify_VEC_COND_EXPR

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111699 Andrew Pinski changed: What|Removed |Added Last reconfirmed||2023-10-05

[Bug target/111704] ICE in extract_insn, at recog.cc:2791 on aarch64-linux-gnu during RTL pass: cprop_hardreg

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111704 Andrew Pinski changed: What|Removed |Added Resolution|--- |DUPLICATE

[Bug target/111411] [14 regression] ICE when building opus-1.4, unrecognizable insn with -fstack-protector-strong

2023-10-05 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111411 Andrew Pinski changed: What|Removed |Added CC||Simon.Richter at hogyros dot de ---

Re: [PATCH][_GLIBCXX_INLINE_VERSION] Add missing symbols

2023-10-05 Thread Jonathan Wakely
On Thu, 5 Oct 2023 at 18:04, François Dumont wrote: > > Here is a patch to fix following test case in gcc: > > gcc/testsuite/g++.dg/cpp23/ext-floating13.C > > libstdc++: [_GLIBCXX_INLINE_VERSION] Add missing float symbols > > libstdc++-v3/ChangeLog: > > *

[PATCH][_GLIBCXX_INLINE_VERSION] Add missing symbols

2023-10-05 Thread François Dumont
Here is a patch to fix following test case in gcc: gcc/testsuite/g++.dg/cpp23/ext-floating13.C     libstdc++: [_GLIBCXX_INLINE_VERSION] Add missing float symbols     libstdc++-v3/ChangeLog:     * config/abi/pre/gnu-versioned-namespace.ver: Add missing symbols     for

Re: [PATCH V5 2/2] rs6000: use mtvsrws to move sf from si p9

2023-10-05 Thread David Edelsohn
On Thu, Oct 5, 2023 at 12:14 AM Jiufu Guo wrote: > Hi, > > As mentioned in PR108338, on p9, we could use mtvsrws to implement > the bitcast from SI to SF (or lowpart DI to SF). > > For example: > *(long long*)buff = di; > float f = *(float*)(buff); > > "sldi 9,3,32 ; mtvsrd 1,9 ; xscvspdpn

Re: [PATCH V5 1/2] rs6000: optimize moving to sf from highpart di

2023-10-05 Thread David Edelsohn
On Thu, Oct 5, 2023 at 12:50 AM Jiufu Guo wrote: > Hi, > > Currently, we have the pattern "movsf_from_si2" which was trying > to support moving high part DI to SF. > > But current pattern only accepts "ashiftrt": > XX:SF=bitcast:SF(subreg(YY:DI>>32),0), but actually "lshiftrt" should > also be

Re: [PATCH] RISC-V: xfail gcc.dg/pr90263.c for riscv_v

2023-10-05 Thread Patrick O'Neill
On 10/4/23 15:29, Jeff Law wrote: On 10/4/23 16:21, Patrick O'Neill wrote: On 10/4/23 15:14, Jeff Law wrote: On 10/4/23 15:57, Patrick O'Neill wrote: Since r14-4358-g9464e72bcc9 riscv_v targets use vector instructions to perform a memcpy. We no longer expect memcpy for riscv_v targets.

Re: [RFC] expr: don't clear SUBREG_PROMOTED_VAR_P flag for a promoted subreg [target/111466]

2023-10-05 Thread Jeff Law
On 10/5/23 07:33, Robin Dapp wrote: So I think Kenner's code is trying to prevent having a value in a SUBREG that is inconsistent with the SUBREG_PROMOTED* flag bits. But I think it's been unnecessary since Matz's rewrite in 2009. I couldn't really tell what the rewrite does entirely so I

[Bug ipa/111283] [14 Regression] gnat profilebootstrap broken on trunk 20230902 on 32bit targets

2023-10-05 Thread slyfox at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111283 Sergei Trofimovich changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|---

[Bug c/110368] Incorrect "is used uninitialized" warning message

2023-10-05 Thread clugstj at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110368 --- Comment #6 from Jon Clugston --- So, "undefined behavior" gives the compiler license to output any warning it wants? The warning message is utterly wrong and completely misleading.

[Bug gcov-profile/111559] [14 regression] ICE when building Python with PGO

2023-10-05 Thread slyfox at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111559 Sergei Trofimovich changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|---

Re: [PATCH] ira: Scale save/restore costs of callee save registers with block frequency

2023-10-05 Thread Vladimir Makarov
On 10/3/23 10:07, Surya Kumari Jangala wrote: ira: Scale save/restore costs of callee save registers with block frequency In assign_hard_reg(), when computing the costs of the hard registers, the cost of saving/restoring a callee-save hard register in prolog/epilog is taken into

[Bug gcov-profile/111559] [14 regression] ICE when building Python with PGO

2023-10-05 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111559 --- Comment #9 from CVS Commits --- The master branch has been updated by Sergei Trofimovich : https://gcc.gnu.org/g:043a6fcbc27f8721301eb2f72a7839f54f393003 commit r14-4421-g043a6fcbc27f8721301eb2f72a7839f54f393003 Author: Sergei Trofimovich

[Bug ipa/111283] [14 Regression] gnat profilebootstrap broken on trunk 20230902 on 32bit targets

2023-10-05 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111283 --- Comment #10 from CVS Commits --- The master branch has been updated by Sergei Trofimovich : https://gcc.gnu.org/g:043a6fcbc27f8721301eb2f72a7839f54f393003 commit r14-4421-g043a6fcbc27f8721301eb2f72a7839f54f393003 Author: Sergei

  1   2   3   >