[PATCH] sccvn: Avoid UB in ao_ref_init_from_vn_reference [PR105533]

2024-03-06 Thread Jakub Jelinek
Hi! When compiling libgcc or on e.g. int a[64]; int p; void foo (void) { int s = 1; while (p) { s -= 11; a[s] != 0; } } sccvn invokes UB in the compiler as detected by ubsan: ../../gcc/poly-int.h:1089:5: runtime error: left shift of negative value -40 The problem is that

回复: RE: [PATCH] RISC-V: Fix ICE in riscv vector costs

2024-03-06 Thread juzhe.zh...@rivai.ai
I suggest open an PR with a PR id. juzhe.zh...@rivai.ai 发件人: Demin Han 发送时间: 2024-03-07 15:39 收件人: juzhe.zh...@rivai.ai; gcc-patches 抄送: kito.cheng; pan2.li; jeffreyalaw 主题: RE: [PATCH] RISC-V: Fix ICE in riscv vector costs OK. Which is better for testcase name? 1. ice-biggestmode.c or

RE: [PATCH] RISC-V: Fix ICE in riscv vector costs

2024-03-06 Thread Demin Han
OK. Which is better for testcase name? 1. ice-biggestmode.c or 2. Report a bug and name the testcase with PR id From: juzhe.zh...@rivai.ai Sent: 2024年3月7日 15:20 To: Demin Han ; gcc-patches Cc: kito.cheng ; pan2.li ; jeffreyalaw Subject: Re: [PATCH] RISC-V: Fix ICE in riscv vector

Re: [PATCH] RISC-V: Fix ICE in riscv vector costs

2024-03-06 Thread juzhe.zh...@rivai.ai
Could you plz add testcase ? I just noticed you didn't append a testcase (jpeg) in this patch. juzhe.zh...@rivai.ai From: demin.han Date: 2024-03-07 13:54 To: gcc-patches CC: juzhe.zhong; kito.cheng; pan2.li; jeffreyalaw Subject: [PATCH] RISC-V: Fix ICE in riscv vector costs The following

Re: [PATCH] RISC-V: Fix ICE in riscv vector costs

2024-03-06 Thread juzhe.zh...@rivai.ai
LGTM. juzhe.zh...@rivai.ai From: demin.han Date: 2024-03-07 13:54 To: gcc-patches CC: juzhe.zhong; kito.cheng; pan2.li; jeffreyalaw Subject: [PATCH] RISC-V: Fix ICE in riscv vector costs The following code can result in ICE: -march=rv64gcv_zba_zbb --param riscv-autovec-lmul=dynamic -O3 char

Re: [PATCH] Include safe-ctype.h after C++ standard headers, to avoid over-poisoning

2024-03-06 Thread Iain Sandoe
Hi Dimitry, folks, > On 6 Mar 2024, at 23:02, Dimitry Andric wrote: > > On 6 Mar 2024, at 15:57, FX Coudert wrote: >> >>> Hmm I recall trying it and finding a problem - was there some different fix >>> applied >>> in the end? >> >> The bug is still open, I don’t think a patch was applied,

RE: [PATCH] c++/c-common: Fix convert_vector_to_array_for_subscript for qualified vector types [PR89224]

2024-03-06 Thread Andrew Pinski (QUIC)
> -Original Message- > From: Andrew Pinski (QUIC) > Sent: Tuesday, February 20, 2024 7:06 PM > To: gcc-patches@gcc.gnu.org > Cc: Andrew Pinski (QUIC) > Subject: [PATCH] c++/c-common: Fix convert_vector_to_array_for_subscript > for qualified vector types [PR89224] > > After

[PATCH] RISC-V: Fix ICE in riscv vector costs

2024-03-06 Thread demin.han
The following code can result in ICE: -march=rv64gcv_zba_zbb --param riscv-autovec-lmul=dynamic -O3 char *jpeg_difference7_input_buf; void jpeg_difference7(int *diff_buf) { unsigned width; int samp, Rb; while (--width) { Rb = samp = *jpeg_difference7_input_buf; *diff_buf++ =

Re: [PATCH] LoongArch: Emit R_LARCH_RELAX for TLS IE with non-extreme code model to allow the IE to LE linker relaxation

2024-03-06 Thread chenglulu
在 2024/3/7 下午12:05, mengqinggang 写道: Hi, Thanks, this patch is LGTM. I don't have a problem either. Thanks. 在 2024/3/7 上午10:56, Xi Ruoyao 写道: On Thu, 2024-03-07 at 10:43 +0800, mengqinggang wrote: Hi, Whether to add an option to control the generation of R_LARCH_RELAX, similar to as

Re: [PATCH] LoongArch: Emit R_LARCH_RELAX for TLS IE with non-extreme code model to allow the IE to LE linker relaxation

2024-03-06 Thread mengqinggang
Hi, Thanks, this patch is LGTM. 在 2024/3/7 上午10:56, Xi Ruoyao 写道: On Thu, 2024-03-07 at 10:43 +0800, mengqinggang wrote: Hi, Whether to add an option to control the generation of R_LARCH_RELAX, similar to as -mrelax/-mno-relax. There are already -mrelax and -mno-relax, they can be checked

Re: [patch, libgfortran] Part 2: PR105456 Child I/O does not propage iostat

2024-03-06 Thread Jerry D
On 3/6/24 9:13 AM, Harald Anlauf wrote: Hi Jerry, can you please replace the user message in e.g. your new testcase pr105456-wf.f90 by say: piomsg="The users message containing % and %% and %s and other stuff" This behaves as expected with Intel, but dies horribly with gfortran after your

Re: [PATCH] c++: lambda capturing structured bindings [PR85889]

2024-03-06 Thread Jason Merrill
On 3/4/24 12:49, Marek Polacek wrote: On Fri, Mar 01, 2024 at 07:58:24PM -0500, Marek Polacek wrote: Bootstrapped/regtested on x86_64-pc-linux-gnu, ok for 15? (Or even trunk?) -- >8 -- clarifies that it's OK to capture structured bindings.

Re: [PATCH] c++: ICE with variable template and [[deprecated]] [PR110031]

2024-03-06 Thread Jason Merrill
On 3/4/24 17:11, Marek Polacek wrote: Bootstrapped/regtested on x86_64-pc-linux-gnu, ok for trunk/13? OK. -- >8 -- lookup_and_finish_template_variable already has and uses the complain parameter but it is not passing it down to mark_used so we got the default tf_warning_or_error, which

Re: [PATCH] c++/modules: member alias tmpl partial inst [PR103994]

2024-03-06 Thread Jason Merrill
On 3/4/24 17:26, Patrick Palka wrote: Bootstrapped and regtested on x86_64-pc-linux-gnu, does this look OK for trunk? -- >8 -- Alias templates are weird in that their specializations can appear in both decl_specializations and type_specializations. They appear in the latter only at parse time

Re: [PATCH] LoongArch: Emit R_LARCH_RELAX for TLS IE with non-extreme code model to allow the IE to LE linker relaxation

2024-03-06 Thread Xi Ruoyao
On Thu, 2024-03-07 at 10:43 +0800, mengqinggang wrote: > Hi, > > Whether to add an option to control the generation of R_LARCH_RELAX, > similar to as -mrelax/-mno-relax. There are already -mrelax and -mno-relax, they can be checked in the compiler code with TARGET_LINKER_RELAXATION. /* snip */

Re: [PATCH] LoongArch: Emit R_LARCH_RELAX for TLS IE with non-extreme code model to allow the IE to LE linker relaxation

2024-03-06 Thread mengqinggang
Hi, Whether to add an option to control the generation of R_LARCH_RELAX, similar to as -mrelax/-mno-relax. 在 2024/2/29 下午3:11, Xi Ruoyao 写道: In Binutils we need to make IE to LE relaxation only allowed when there is an R_LARCH_RELAX after R_LARCH_TLE_IE_PC_{HI20,LO12} so an invalid "partial"

Re: [PATCH] c++/modules: inline namespace abi_tag streaming [PR110730]

2024-03-06 Thread Patrick Palka
On Wed, 6 Mar 2024, Jason Merrill wrote: > On 3/6/24 14:10, Patrick Palka wrote: > > Tested on x86_64-pc-linux-gnu, does this look OK for trunk? > > > > -- >8 -- > > > > The unreduced testcase from this PR crashes at runtime ultimately > > because we don't stream the abi_tag attribute on inline

Re: [PATCH] c++: Fix ICE diagnosing incomplete type of overloaded function set [PR98356]

2024-03-06 Thread Jason Merrill
On 3/4/24 18:30, Nathaniel Shead wrote: Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? OK. -- >8 -- In the linked PR the result of 'get_first_fn' is a USING_DECL against the template parameter, to be filled in on instantiation. But we don't actually need to get the first

RE: [PATCH v2] Draft|Internal-fn: Introduce internal fn saturation US_PLUS

2024-03-06 Thread Li, Pan2
Thanks Richard for comments. > gen_int_libfunc will no longer make it emit libcalls for fixed point > modes, so this can't be correct > and there's no libgcc implementation for integer mode saturating ops, > so it's pointless to emit calls > to them. Got the pointer here, the

[PATCH] LoongArch: testsuite: Add compilation options to the regname-fp-s9.c.

2024-03-06 Thread Lulu Cheng
When the value of the macro DEFAULT_CFLAGS is set to '-ansi -pedantic-errors', regname-s9-fp.c will test to fail. To solve this problem, add the compilation option '-Wno-pedantic -std=gnu90' to this test case. gcc/testsuite/ChangeLog: * gcc.target/loongarch/regname-fp-s9.c: Add

Re: [PATCH] c++: Don't set DECL_CONTEXT to nested template-template parameters [PR98881]

2024-03-06 Thread Jason Merrill
On 3/5/24 00:24, Nathaniel Shead wrote: On Mon, Mar 04, 2024 at 10:07:33PM -0500, Patrick Palka wrote: On Tue, 5 Mar 2024, Nathaniel Shead wrote: On Mon, Mar 04, 2024 at 09:26:00PM -0500, Patrick Palka wrote: On Tue, 5 Mar 2024, Nathaniel Shead wrote: On Mon, Mar 04, 2024 at 07:14:54PM

Re: [PATCH] c++/modules: inline namespace abi_tag streaming [PR110730]

2024-03-06 Thread Jason Merrill
On 3/6/24 14:10, Patrick Palka wrote: Tested on x86_64-pc-linux-gnu, does this look OK for trunk? -- >8 -- The unreduced testcase from this PR crashes at runtime ultimately because we don't stream the abi_tag attribute on inline namespaces and so the filesystem::current_path() call resolves to

[PATCH v1] LoongArch: Fixed an issue with the implementation of the template atomic_compare_and_swapsi.

2024-03-06 Thread Lulu Cheng
If the hardware does not support LAMCAS, atomic_compare_and_swapsi needs to be implemented through "ll.w+sc.w". In the implementation of the instruction sequence, it is necessary to determine whether the two registers are equal. Since LoongArch's comparison instructions do not distinguish between

Re: [PATCH] c-family, c++, v2: Fix up handling of types which may have padding in __atomic_{compare_}exchange

2024-03-06 Thread Jason Merrill
On 2/20/24 05:02, Jakub Jelinek wrote: On Tue, Feb 20, 2024 at 09:01:10AM +0100, Richard Biener wrote: I'm not sure those would be really equivalent (MEM_REF vs. V_C_E as well as combined vs. split). It really depends how RTL expansion handles this (as you can see padding can be fun here). So

Re: [PATCH] dwarf2out, v3: Emit DW_AT_export_symbols on anon unions/structs [PR113918]

2024-03-06 Thread Jason Merrill
On 2/16/24 16:06, Jakub Jelinek wrote: On Fri, Feb 16, 2024 at 03:40:39PM -0500, Jason Merrill wrote: --- gcc/cp/cp-objcp-common.cc.jj2024-02-13 12:50:21.666846296 +0100 +++ gcc/cp/cp-objcp-common.cc 2024-02-16 20:40:51.374763528 +0100 @@ -410,6 +410,15 @@ cp_type_dwarf_attribute

Re: [PATCH] c++: Fix up parameter pack diagnostics on xobj vs. varargs functions [PR113802]

2024-03-06 Thread Jason Merrill
On 2/16/24 17:15, Jakub Jelinek wrote: On Fri, Feb 16, 2024 at 10:47:47PM +0100, Jakub Jelinek wrote: The following patch works. Or yet another option would be instead of (sometimes) clearing declarator->parameter_pack_p when we diagnose this bug for error recovery ignore the this specifier.

Re: [PATCH] Include safe-ctype.h after C++ standard headers, to avoid over-poisoning

2024-03-06 Thread Dimitry Andric
On 6 Mar 2024, at 15:57, FX Coudert wrote: > >> Hmm I recall trying it and finding a problem - was there some different fix >> applied >> in the end? > > The bug is still open, I don’t think a patch was applied, and I don’t find > any email to the list stating what the problem could be. The

[PATCH] lto-streamer: Ensure src_pwd is remapped

2024-03-06 Thread Morten Linderud
I've made an attempt at patching this issue as it produces unreproducible unreproducible binaries for Golang. I don't know C/C++ and it's my first gcc patch so please bear with me :) -- >8 -- When -flto is used with line macros containing bare symbols instead of absolute paths the full path is

Re: [C++ coroutines] Initial implementation pushed to master.

2024-03-06 Thread H.J. Lu
On Wed, Mar 6, 2024 at 1:03 AM Iain Sandoe wrote: > > > > > On 5 Mar 2024, at 17:31, H.J. Lu wrote: > > > > On Sat, Jan 18, 2020 at 4:54 AM Iain Sandoe wrote: > >> > > >> 2020-01-18 Iain Sandoe > >> > >>* Makefile.in: Add coroutine-passes.o. > >>* builtin-types.def

Re: [PATCH] arm: fix c23 0-named-args caller-side stdarg

2024-03-06 Thread Jakub Jelinek
On Wed, Mar 06, 2024 at 05:28:21PM -0300, Alexandre Oliva wrote: > On Mar 1, 2024, "Richard Earnshaw (lists)" wrote: > > > On 01/03/2024 04:38, Alexandre Oliva wrote: > >> Thanks for the review. > > > For closure, Jakub has just pushed a patch to the generic code, so I > > don't think we need

Re: [PATCH] arm: fix c23 0-named-args caller-side stdarg

2024-03-06 Thread Alexandre Oliva
On Mar 1, 2024, "Richard Earnshaw (lists)" wrote: > On 01/03/2024 04:38, Alexandre Oliva wrote: >> Thanks for the review. > For closure, Jakub has just pushed a patch to the generic code, so I > don't think we need this now. ACK. I see the c2x-stdarg-4.c test is now passing in our arm-eabi

[PATCH] vect: Do not peel epilogue for partial vectors [PR114196].

2024-03-06 Thread Robin Dapp
Hi, r14-7036-gcbf569486b2dec added an epilogue vectorization guard for early break but PR114196 shows that we also run into the problem without early break. Therefore remove early break from the conditions. gcc/ChangeLog: PR middle-end/114196 * tree-vect-loop-manip.cc

[committed] i386: Fix and improve insn constraint for V2QI arithmetic/shift insns

2024-03-06 Thread Uros Bizjak
optimize_function_for_size_p predicate is not stable during optab selection, because it also depends on node->count/node->frequency of the current function, which are updated during IPA, so they may change between early opts and late opts. Use optimize_size instead - optimize_size implies

Re: [PATCH v2] RISC-V: Introduce gcc attribute riscv_rvv_vector_bits for RVV

2024-03-06 Thread Vineet Gupta
On 3/5/24 23:27, pan2...@intel.com wrote: > From: Pan Li > > Update in v2: > * Cleanup some unused code. > * Fix some typo of commit log. > > Original log: > > This patch would like to introduce one new gcc attribute for RVV. > This attribute is used to define fixed-length variants of one >

[PATCH] c++/modules: inline namespace abi_tag streaming [PR110730]

2024-03-06 Thread Patrick Palka
Tested on x86_64-pc-linux-gnu, does this look OK for trunk? -- >8 -- The unreduced testcase from this PR crashes at runtime ultimately because we don't stream the abi_tag attribute on inline namespaces and so the filesystem::current_path() call resolves to the non-C++11 ABI version even though

[PATCH v8] C, ObjC: Add -Wunterminated-string-initialization

2024-03-06 Thread Alejandro Colomar
Warn about the following: char s[3] = "foo"; Initializing a char array with a string literal of the same length as the size of the array is usually a mistake. Rarely is the case where one wants to create a non-terminated character sequence from a string literal. In some cases, for writing

[PATCH] gomp: testsuite: improve compatibility of bad-array-section-3.c [PR113428]

2024-03-06 Thread Richard Earnshaw
This test generates different warnings on ilp32 targets because the size of an integer matches the size of a pointer. Avoid this by using signed char. gcc/testsuite: PR testsuite/113428 * gcc.dg/gomp/bad-array-section-c-3.c: Use signed char instead of int. --- I think

Re: [patch, libgfortran] Part 2: PR105456 Child I/O does not propage iostat

2024-03-06 Thread Harald Anlauf
Hi Jerry, can you please replace the user message in e.g. your new testcase pr105456-wf.f90 by say: piomsg="The users message containing % and %% and %s and other stuff" This behaves as expected with Intel, but dies horribly with gfortran after your patch! Cheers, Harald On 3/6/24 05:06,

Re: [PATCH] Fortran: error recovery while simplifying expressions [PR103707, PR106987]

2024-03-06 Thread Harald Anlauf
Hi Paul, thanks for reviewing the patch, and your trust in me :-) Backporting to 13-branch seems easily feasible (needs another small queued backport on which this patch depends), but going further is definitely out of the question... Will wait a couple of weeks though. Harald On 3/6/24

Re: [PATCH] OpenMP: warn about iteration var modifications in loop body

2024-03-06 Thread Frederik Harwath
Ping. The Linaro CI has kindly pointed me to two test regressions that I had missed. I have adjust the test expectations in the updated patch which I have attached. Frederik On 28.02.24 8:32 PM, Frederik Harwath wrote: Hi, this patch implements a warning about (some simple cases of direct)

[PR target/113001] Fix incorrect operand swapping in conditional move

2024-03-06 Thread Jeff Law
This bug totally fell off my radar. Sorry about that. We have some special casing the conditional move expander to simplify a conditional move when comparing a register against zero and that same register is one of the arms. Specifically a (eq (reg) (const_int 0)) where reg is also the true

[committed] i386: Eliminate common code from x86_32 TARGET_MACHO part in ix86_expand_move

2024-03-06 Thread Uros Bizjak
Eliminate common code from x86_32 TARGET_MACHO part in ix86_expand_move and use generic code instead. No functional changes. gcc/ChangeLog: * config/i386/i386-expand.cc (ix86_expand_move) [TARGET_MACHO]: Eliminate common code and use generic code instead. Bootstrapped and regression

Re: [PATCH] Include safe-ctype.h after C++ standard headers, to avoid over-poisoning

2024-03-06 Thread FX Coudert
> Hmm I recall trying it and finding a problem - was there some different fix > applied > in the end? The bug is still open, I don’t think a patch was applied, and I don’t find any email to the list stating what the problem could be. FX

Re: [PATCH] Include safe-ctype.h after C++ standard headers, to avoid over-poisoning

2024-03-06 Thread Iain Sandoe
> On 6 Mar 2024, at 13:54, Sam James wrote: > > FX Coudert writes: > >> I would like to patch this patch from September 2023: >> https://gcc.gnu.org/pipermail/gcc-patches/2023-September/631611.html >> >> This bug is now hitting macOS in the latest version of Xcode (it was >> originally

[PATCH v2 00/13] Add aarch64-w64-mingw32 target

2024-03-06 Thread Evgeny Karpov
Wednesday, March 6, 2024 LIU Hao wrote: > May I suggest you keep the mcf thread model for aarch-w64-mingw32? I > requested Martin Storsjö to test it on a physical Windows 11 on ARM machine > with Clang and all tests passed. I think it should work once the GCC support > is > complete. > > > --

Re: [PATCH] RISC-V: Use vmv1r.v instead of vmv.v.v for fma output reloads [PR114200].

2024-03-06 Thread 钟居哲
LGTM juzhe.zh...@rivai.ai From: Robin Dapp Date: 2024-03-06 21:44 To: gcc-patches; palmer; Kito Cheng; juzhe.zh...@rivai.ai CC: rdapp.gcc; jeffreyalaw Subject: [PATCH] RISC-V: Use vmv1r.v instead of vmv.v.v for fma output reloads [PR114200]. Hi, three-operand instructions like vmacc are

C++ patch ping

2024-03-06 Thread Jakub Jelinek
Hi! https://gcc.gnu.org/pipermail/gcc-patches/2024-February/thread.html#645781 [PATCH] c++: Fix up parameter pack diagnostics on xobj vs. varargs functions [PR113802] The thread contains two possible further versions of the patch.

Re: amdgcn: additional gfx1030/gfx1100 support: adjust test cases

2024-03-06 Thread Andrew Stubbs
On 06/03/2024 13:49, Thomas Schwinge wrote: Hi! On 2024-01-24T12:43:04+, Andrew Stubbs wrote: This [...] ... became commit 99890e15527f1f04caef95ecdd135c9f1a077f08 "amdgcn: additional gfx1030/gfx1100 support", and included the following: --- a/gcc/config/gcn/gcn-valu.md +++

Re: [PATCH] c++/modules: Prevent emission of really-extern vtables in importers [PR114229]

2024-03-06 Thread Jason Merrill
On 3/5/24 22:06, Nathaniel Shead wrote: Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? -- >8 -- Currently, reading a variable definition always marks that decl as DECL_NOT_REALLY_EXTERN, with anything else imported still being considered external. This is not sufficient for

Re: [PATCH] Include safe-ctype.h after C++ standard headers, to avoid over-poisoning

2024-03-06 Thread Sam James
FX Coudert writes: > I would like to patch this patch from September 2023: > https://gcc.gnu.org/pipermail/gcc-patches/2023-September/631611.html > > This bug is now hitting macOS in the latest version of Xcode (it was > originally seen on freebsd). > I confirm that the patch is restoring

amdgcn: additional gfx1030/gfx1100 support: adjust test cases (was: [PATCH] amdgcn: additional gfx1100 support)

2024-03-06 Thread Thomas Schwinge
Hi! On 2024-01-24T12:43:04+, Andrew Stubbs wrote: > This [...] ... became commit 99890e15527f1f04caef95ecdd135c9f1a077f08 "amdgcn: additional gfx1030/gfx1100 support", and included the following: > --- a/gcc/config/gcn/gcn-valu.md > +++ b/gcc/config/gcn/gcn-valu.md > @@ -3555,30 +3555,63

[PATCH] RISC-V: Use vmv1r.v instead of vmv.v.v for fma output reloads [PR114200].

2024-03-06 Thread Robin Dapp
Hi, three-operand instructions like vmacc are modeled with an implicit output reload when the output does not match one of the operands. For this we use vmv.v.v which is subject to length masking. In a situation where the current vl is less than the full vlenb and the fma's result value is used

Re: [PATCH] Include safe-ctype.h after C++ standard headers, to avoid over-poisoning

2024-03-06 Thread FX Coudert
I would like to patch this patch from September 2023: https://gcc.gnu.org/pipermail/gcc-patches/2023-September/631611.html This bug is now hitting macOS in the latest version of Xcode (it was originally seen on freebsd). I confirm that the patch is restoring bootstrap on x86_64-apple-darwin23

Re: [PATCH] match.pd, v2: Optimize a * !a to 0 [PR114009]

2024-03-06 Thread Richard Biener
On Wed, 6 Mar 2024, Jakub Jelinek wrote: > On Wed, Mar 06, 2024 at 11:45:42AM +0100, Richard Biener wrote: > > OK, though feel free to add ARG_UNUSED to 'captures' as well. > > Ok, done below. > > > I think the INTEGRAL_TYPE_P should be redundant - the pattern > > should work for vectors and

Re: Stabilize flaky GCN target/offloading testing

2024-03-06 Thread Richard Biener
On Wed, 6 Mar 2024, Andrew Stubbs wrote: > On 06/03/2024 12:09, Thomas Schwinge wrote: > > Hi! > > > > On 2024-02-21T17:32:13+0100, Richard Biener wrote: > >> Am 21.02.2024 um 13:34 schrieb Thomas Schwinge : > >>> [...] per my work on > >>> "libgomp make check time

[PATCH] match.pd, v2: Optimize a * !a to 0 [PR114009]

2024-03-06 Thread Jakub Jelinek
On Wed, Mar 06, 2024 at 11:45:42AM +0100, Richard Biener wrote: > OK, though feel free to add ARG_UNUSED to 'captures' as well. Ok, done below. > I think the INTEGRAL_TYPE_P should be redundant - the pattern > should work for vectors and complex as well (with integer components > which

Re: Stabilize flaky GCN target/offloading testing

2024-03-06 Thread Andrew Stubbs
On 06/03/2024 12:09, Thomas Schwinge wrote: Hi! On 2024-02-21T17:32:13+0100, Richard Biener wrote: Am 21.02.2024 um 13:34 schrieb Thomas Schwinge : [...] per my work on "libgomp make check time is excessive", all execution testing in libgomp is serialized in

[patch,avr.applied] Adjusted rtx costs of plus + zero_extend

2024-03-06 Thread Georg-Johann Lay
Adjusted rtx costs of (plus (zero_extend (...)) reg). Johann -- AVR: Adjust rtx cost of plus + zero_extend. gcc/ * config/avr/avr.cc (avr_rtx_costs_1) [PLUS+ZERO_EXTEND]: Adjust rtx cost. diff --git a/gcc/config/avr/avr.cc b/gcc/config/avr/avr.cc index

Stabilize flaky GCN target/offloading testing

2024-03-06 Thread Thomas Schwinge
Hi! On 2024-02-21T17:32:13+0100, Richard Biener wrote: > Am 21.02.2024 um 13:34 schrieb Thomas Schwinge : >> [...] per my work on >> "libgomp make check time is excessive", all execution testing in libgomp >> is serialized in

[PATCH] tree-optimizaton/114239 - rework reduction epilogue driving

2024-03-06 Thread Richard Biener
The following reworks vectorizable_live_operation to pass the live stmt to vect_create_epilog_for_reduction also for early breaks and a peeled main exit. This is to be able to figure the scalar definition to replace. This reverts the PR114192 fix as it is subsumed by this cleanup. Bootstrapped

Re: [PATCH] s390: Streamline NNPA builtins with POP mnemonics

2024-03-06 Thread Stefan Schulze Frielinghaus
Since there is no straight forward way to introduce an overload with different return types where we would expand differently depending on an immediate operand, lets drop this patch. On Fri, Mar 01, 2024 at 04:18:31PM +0100, Stefan Schulze Frielinghaus wrote: > At the moment there are no extended

Re: [PATCH] Fortran: error recovery while simplifying expressions [PR103707, PR106987]

2024-03-06 Thread Paul Richard Thomas
Hi Harald, This all looks good to me. OK for mainline and, according to intestinal fortitude on your part, earlier branches. Thanks Paul On Tue, 5 Mar 2024 at 21:24, Harald Anlauf wrote: > Dear all, > > error recovery on arithmetic errors during simplification has bugged > me for a long

Re: [PATCH] match.pd: Optimize a * !a to 0 [PR114009]

2024-03-06 Thread Richard Biener
On Wed, 6 Mar 2024, Jakub Jelinek wrote: > Hi! > > The following patch attempts to fix an optimization regression through > adding a simple simplification. We already have the > /* (m1 CMP m2) * d -> (m1 CMP m2) ? d : 0 */ > (if (!canonicalize_math_p ()) > (for cmp (tcc_comparison) >

RE: [PATCH] MAINTAINERS: Add myself to write after approval

2024-03-06 Thread Demin Han
Hi, I will commit the patch you mentioned with [NFC] added. And split and resubmit other patches after more check and discussion. Regards, Demin From: juzhe.zh...@rivai.ai Sent: 2024年3月6日 10:13 To: Demin Han ; gcc-patches Cc: kito.cheng Subject: Re: [PATCH] MAINTAINERS: Add myself to write

Re: [PATCH] Revert "Pass GUILE down to subdirectories"

2024-03-06 Thread Andrew Burgess
Tom Tromey writes: > This reverts commit b7e5a29602143b53267efcd9c8d5ecc78cd5a62f. > > This patch caused problems for some users when building gdb, because > it would cause 'guild' to be invoked with the wrong versin of guile. > On the whole it seems simpler to just back this out. Tom, After

[pushed] aarch64: Define out-of-class static constants

2024-03-06 Thread Richard Sandiford
While reworking the aarch64 feature descriptions, I forgot to add out-of-class definitions of some static constants. This could lead to a build failure with some compilers. This was seen with some WIP to increase the number of extensions beyond 64. It's latent on trunk though, and a regression

Re: [PATCH] arm: Support -mfdpic for more targets

2024-03-06 Thread Richard Earnshaw (lists)
On 06/03/2024 05:07, Fangrui Song wrote: > On Fri, Feb 23, 2024 at 7:33 PM Fangrui Song wrote: >> >> From: Fangrui Song >> >> Targets that are not arm*-*-uclinuxfdpiceabi can use -S -mfdpic, but -c >> -mfdpic does not pass --fdpic to gas.  This is an unnecessary >> restriction.  Just define the

Re: [PATCH] LoongArch: testsuite: Rewrite {x, }vfcmp-{d, f}.c to avoid named registers

2024-03-06 Thread chenglulu
This test case is so cleverly designed! I have no problem. Thank you! 在 2024/3/5 下午9:00, Xi Ruoyao 写道: Loops on named vector register are not vectorized (see comment 11 of PR113622), so the these test cases have been failing for a while. Rewrite them using check-function-bodies to remove hard

Re: [PATCH V3] rs6000: Don't ICE when compiling the __builtin_vsx_splat_2di built-in [PR113950]

2024-03-06 Thread Kewen.Lin
Hi, on 2024/3/4 02:55, jeevitha wrote: > Hi All, > > The following patch has been bootstrapped and regtested on powerpc64le-linux. > > When we expand the __builtin_vsx_splat_2di function, we were allowing > immediate

Re: [PATCH, rs6000] Add subreg patterns for SImode rotate and mask insert

2024-03-06 Thread Kewen.Lin
Hi, on 2024/3/1 10:41, HAO CHEN GUI wrote: > Hi, > This patch fixes regression cases in gcc.target/powerpc/rlwimi-2.c. In > combine pass, SImode (subreg from DImode) lshiftrt is converted to DImode > lshiftrt with an out AND. It matches a DImode rotate and mask insert on > rs6000. > > Trying 2

[PATCH] tree-optimization/114246 - invalid call argument from DSE

2024-03-06 Thread Richard Biener
The following makes sure to strip type conversions added by build_fold_addr_expr before placing the result in a call argument. Bootstrapped and tested on x86_64-unknown-linux-gnu, pushed. PR tree-optimization/114246 * tree-ssa-dse.cc (increment_start_addr): Strip useless

[PATCH] tree-optimization/114249 - ICE with BB reduction vectorization

2024-03-06 Thread Richard Biener
When we scrap the last def of an odd lane numbered BB reduction we can end up recording a pattern def which will later wreck code generation. The following puts this logic where it better belongs, avoiding this issue. Bootstrapped and tested on x86_64-unknown-linux-gnu, pushed. PR

Re: [C++ coroutines] Initial implementation pushed to master.

2024-03-06 Thread Iain Sandoe
> On 5 Mar 2024, at 17:31, H.J. Lu wrote: > > On Sat, Jan 18, 2020 at 4:54 AM Iain Sandoe wrote: >> >> 2020-01-18 Iain Sandoe >> >>* Makefile.in: Add coroutine-passes.o. >>* builtin-types.def (BT_CONST_SIZE): New. >>(BT_FN_BOOL_PTR): New. >>

[PATCH v1] LoongArch: testsuite:Fix problems with incorrect results in vector test cases.

2024-03-06 Thread chenxiaolong
In simd_correctness_check.h, the role of the macro ASSERTEQ_64 is to check the result of the passed vector values for the 64-bit data of each array element. It turns out that it uses the abs() function to check only the lower 32 bits of the data at a time, so it replaces abs() with the llabs()

Re: [PATCH v2 00/13] Add aarch64-w64-mingw32 target

2024-03-06 Thread LIU Hao
May I suggest you keep the mcf thread model for aarch-w64-mingw32? I requested Martin Storsjö to test it on a physical Windows 11 on ARM machine with Clang and all tests passed. I think it should work once the GCC support is complete. -- Best regards, LIU Hao OpenPGP_signature.asc

Re: [PATCH] i386: Fix up the vzeroupper REG_DEAD/REG_UNUSED note workaround [PR114190]

2024-03-06 Thread Uros Bizjak
On Wed, Mar 6, 2024 at 9:10 AM Jakub Jelinek wrote: > > Hi! > > When writing the rest_of_handle_insert_vzeroupper workaround to manually > remove all the REG_DEAD/REG_UNUSED notes from the IL, I've missed that > there is a df_analyze () call right after it and that the problems added > earlier in

[PATCH] match.pd: Optimize a * !a to 0 [PR114009]

2024-03-06 Thread Jakub Jelinek
Hi! The following patch attempts to fix an optimization regression through adding a simple simplification. We already have the /* (m1 CMP m2) * d -> (m1 CMP m2) ? d : 0 */ (if (!canonicalize_math_p ()) (for cmp (tcc_comparison) (simplify (mult:c (convert (cmp@0 @1 @2)) @3) (if

[PATCH] i386: Fix up the vzeroupper REG_DEAD/REG_UNUSED note workaround [PR114190]

2024-03-06 Thread Jakub Jelinek
Hi! When writing the rest_of_handle_insert_vzeroupper workaround to manually remove all the REG_DEAD/REG_UNUSED notes from the IL, I've missed that there is a df_analyze () call right after it and that the problems added earlier in the pass, like df_note_add_problem () done during mode switching,