RE: [PATCH] x86: Skip if the mode size is smaller than its natural size

2025-05-05 Thread Liu, Hongtao
> -Original Message- > From: H.J. Lu > Sent: Tuesday, May 6, 2025 2:16 PM > To: Liu, Hongtao > Cc: GCC Patches ; Uros Bizjak > > Subject: Re: [PATCH] x86: Skip if the mode size is smaller than its natural > size > > On Tue, May 6, 2025 at 10:54 AM Liu, Hongtao > wrote: > > > > > > >

Re: [PATCH] libgomp: Update SVE test

2025-05-05 Thread Tejas Belagod
On 5/2/25 1:11 AM, Jakub Jelinek wrote: On Thu, May 01, 2025 at 08:38:57PM +0100, Richard Sandiford wrote: Tejas Belagod writes: Fix udr-sve.c target test that to check for the correct results based on the OpenMP clauses used. The test was first written with a misunderstood functionality of t

Re: [PATCH] x86: Skip if the mode size is smaller than its natural size

2025-05-05 Thread H.J. Lu
On Tue, May 6, 2025 at 10:54 AM Liu, Hongtao wrote: > > > > > -Original Message- > > From: H.J. Lu > > Sent: Thursday, May 1, 2025 6:39 AM > > To: GCC Patches ; Uros Bizjak > > ; Liu, Hongtao > > Subject: [PATCH] x86: Skip if the mode size is smaller than its natural size > > > > When ge

Re: [to-be-committed][RISC-V][PR target/119971] Avoid losing shift count masking

2025-05-05 Thread Bernhard Reutner-Fischer
On 5 May 2025 20:42:34 CEST, Jeff Law wrote: diff --git a/gcc/testsuite/gcc.target/riscv/pr119971.c b/gcc/testsuite/gcc.target/riscv/pr119971.c new file mode 100644 index 000..c3f23b05ec3 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/pr119971.c @@ -0,0 +1,24 @@ +/* { dg-do compile

RE: [PATCH] cobol: Rewrite exception handling. Partially refactor subscript/refmod calculations.

2025-05-05 Thread Robert Dubner
> -Original Message- > From: Rainer Orth > Sent: Monday, May 5, 2025 16:53 > To: Robert Dubner > Cc: Iain Sandoe ; GCC Patches patc...@gcc.gnu.org>; Jakub Jelinek ; James K. Lowden > > Subject: Re: [PATCH] cobol: Rewrite exception handling. Partially refactor > subscript/refmod calcu

[patch, fortram] Bug 120049 - ICE when using IS_C_ASSOCIATED ()

2025-05-05 Thread Jerry D
Attached patch fixes this by checking for BT_VOID and EXPR_FUNCTION. Thank you for guidance from Steve in the PR and Vincent for identifying the problem. Two test case files added to the testsuite. Regression tested on x86_64. OK for mainline? Since this breakage impacts gtk-fortran I would a

RE: [PATCH] x86: Skip if the mode size is smaller than its natural size

2025-05-05 Thread Liu, Hongtao
> -Original Message- > From: H.J. Lu > Sent: Thursday, May 1, 2025 6:39 AM > To: GCC Patches ; Uros Bizjak > ; Liu, Hongtao > Subject: [PATCH] x86: Skip if the mode size is smaller than its natural size > > When generating a SUBREG from V16QI to V2HF, validate_subreg fails since > the

[to-be-committed][RISC-V][PR middle-end/114512] Recognize more bext idioms for RISC-V

2025-05-05 Thread Jeff Law
This is Shreya's next chunk of work. When I was looking for good bugs for her to chase down I cam across PR114512. While the bug isn't necessarily a RISC-V specific bug, its testcases did show how we were failing to recognize certain bit extraction idioms and how the lispy nature of RTL allow

RE: [PATCH v1 1/5] RISC-V: Add new option --param=rvv-gr2vr-cost= for rvv insn

2025-05-05 Thread Li, Pan2
Thanks Jeff. > Make sure to include a function comment in the final patch. Otherwise > nothing to add above and beyond Robin's comments. Sure thing, will add comments for the helper. Pan -Original Message- From: Jeff Law Sent: Monday, May 5, 2025 9:42 PM To: Li, Pan2 ; gcc-patches@g

Re: [PATCH] libphobos: enable for sparc64-unknown-linux-gnu

2025-05-05 Thread Sam James
Iain Buclaw writes: > Excerpts from Sam James's message of April 20, 2025 2:46 am: >> This bootstraps with some test failures but works well enough to build >> 11..15. >> >> libphobos/ChangeLog: >> >> * configure.tgt: Add sparc64-unknown-linux-gnu as a supported target. >> --- >> As discus

Re: [PATCH 2/3] Flip default to LRA for targets with -mlra

2025-05-05 Thread John Paul Adrian Glaubitz
Hi, On Mon, 2025-05-05 at 11:05 +0200, John Paul Adrian Glaubitz wrote: > On Mon, 2025-05-05 at 10:14 +0200, Richard Biener wrote: > > > I just noticed that my builds were with --disable-bootstrap. *sigh* > > > > Note I'd consider that "fine", it gives you a build that was able to > > build libgc

[RISC-V][PR target/119971] Avoid losing shift count masking

2025-05-05 Thread Jeff Law
Not sure how I missed zbb-rol-ror-03.c failing with the prior version of this patch. But thankfully it's easily resolved. Looking at the testcase I think the old code generation was bogus as it was folding in an andi dst,src,63 with a rorw instruction. It would be OK to fold with a ror and i

Re: [PATCH 3/4] Rewrite VCEs of integral types [PR116939]

2025-05-05 Thread Andrew Pinski
On Mon, May 5, 2025 at 12:53 PM Andrew Pinski wrote: > > On Mon, May 5, 2025 at 12:00 AM Richard Biener > wrote: > > > > On Mon, May 5, 2025 at 3:45 AM Andrew Pinski > > wrote: > > > > > > Like the patch to phiopt (r15-4033-g1f619fe25925a5f7), this adds rewriting > > > of VCE to > > > gimple_w

Re: [PATCH 1/4] Loop-IM: Don't unconditional move conditional stmts during first LIM

2025-05-05 Thread Andrew Pinski
On Sun, May 4, 2025 at 11:51 PM Richard Biener wrote: > > On Mon, May 5, 2025 at 3:42 AM Andrew Pinski wrote: > > > > While fixing up how rewrite_to_defined_overflow works, > > gcc.dg/Wrestrict-22.c started > > to fail. This is because `d p+ 2` would moved by LIM and then be rewritten > > not u

[PATCH] combine: gen_lowpart_no_emit vs CLOBBER [PR120090]

2025-05-05 Thread Andrew Pinski
The problem here is simplify-rtx.cc expects gen_lowpart_no_emit to return NULL on failure but combine's hook was returning CLOBBER. After r16-160-ge6f89d78c1a7528e93458278, gcc.target/i386/avx512bw-pr103750-2.c started to fail at -m32 due to this as new simplify code would return a RTL with a clobb

Re: [PATCH 3/7] OpenMP: Support functions for nested "begin declare variant"

2025-05-05 Thread Tobias Burnus
Hi Sandra, hello world, see other email from today in this thread regarding a C++ module test case + C++ module issues and a parser issues. Regarding the patch itself: On February 10, 2025, Sandra Loosemore wrote: This patch adds functions for variant name mangling and context selector mergin

Re: [PATCH] cobol: Rewrite exception handling. Partially refactor subscript/refmod calculations.

2025-05-05 Thread Rainer Orth
Hi Robert, >> This causes bootstrap to fail on x86_64 darwin with: >> >> Undefined symbols for architecture x86_64: >> "_program_invocation_short_name", referenced from: >> ___gg__check_fatal_exception in libgcobol.o >> ld: symbol(s) not found for architecture x86_64 >> >> Looking at the p

Re: [PATCH v3 2/6] dwarf: create annotation DIEs for btf tags

2025-05-05 Thread David Faust
On 5/2/25 01:26, Richard Biener wrote: > On Wed, Apr 30, 2025 at 7:26 PM David Faust wrote: >> >> The btf_decl_tag and btf_type_tag attributes provide a means to annotate >> declarations and types respectively with arbitrary user provided >> strings. These strings are recorded in debug informa

RE: [PATCH] cobol: Rewrite exception handling. Partially refactor subscript/refmod calculations.

2025-05-05 Thread Robert Dubner
> -Original Message- > From: Iain Sandoe > Sent: Monday, May 5, 2025 14:46 > To: Robert Dubner > Cc: GCC Patches ; Jakub Jelinek > ; James K. Lowden > Subject: Re: [PATCH] cobol: Rewrite exception handling. Partially refactor > subscript/refmod calculations. > > Hi Bob, > > > On 5 May

[PATCH] [GCC14] PR tree-optimization/120048 - Allow IPA_CP to handle UNDEFINED as VARYING.

2025-05-05 Thread Andrew MacLeod
On 5/3/25 07:41, Richard Biener wrote: On Sat, May 3, 2025 at 12:39 AM Andrew MacLeod wrote: On trunk I'll eventually do something different.. but it will be more invasive than I think is reasonable for a backport. The problem in the PR is that there is a variable with a range and has a bitma

[PATCH][GCC15] PR tree-optimization/120048 - Allow IPA_CP to handle UNDEFINED as VARYING.

2025-05-05 Thread Andrew MacLeod
On 5/3/25 07:41, Richard Biener wrote: On Sat, May 3, 2025 at 12:39 AM Andrew MacLeod wrote: On trunk I'll eventually do something different.. but it will be more invasive than I think is reasonable for a backport. The problem in the PR is that there is a variable with a range and has a bitma

Re: [PATCH 3/4] Rewrite VCEs of integral types [PR116939]

2025-05-05 Thread Andrew Pinski
On Mon, May 5, 2025 at 12:00 AM Richard Biener wrote: > > On Mon, May 5, 2025 at 3:45 AM Andrew Pinski wrote: > > > > Like the patch to phiopt (r15-4033-g1f619fe25925a5f7), this adds rewriting > > of VCE to gimple_with_undefined_signed_overflow/rewrite_to_defined_overflow. > > I have not seen a c

Re: [PATCH v5 05/10] libstdc++: Implement layout_left from mdspan.

2025-05-05 Thread Luc Grosheintz
On 5/5/25 9:44 AM, Tomasz Kaminski wrote: On Sat, May 3, 2025 at 2:39 PM Luc Grosheintz wrote: On 4/30/25 7:13 AM, Tomasz Kaminski wrote: Hi, As we will be landing patches for extends, this will become a separate patch series. I would prefer, if you could commit per layout, and start wi

[PATCH] libstdc++: Fix constraint recursion in std::expected's operator== [PR119714]

2025-05-05 Thread Patrick Palka
Tested on x86_64-pc-linux-gnu, does this look OK for trunk/15? -- >8 -- This std::expected friend operator== is prone to constraint recursion after CWG 2369 for the same reason as basic_const_iterator's comparison operators were before the r15-7757-g4342c50ca84ae5 workaround. This patch works ar

[PATCH v1] libstdc++: More efficient weekday from year_month_day.

2025-05-05 Thread Cassio Neri
Use a better algorithm to calculate n % 7, taking into account that the divisor is a Mersenne number. This is explained in this two-part lightning talk at CppCon 2024 [1, 2]. Roughly speaking, the algorithm is used for n = sys_days but it has a precondition that doesn't hold for all values of sys_

Re: [PATCH] cobol: Rewrite exception handling. Partially refactor subscript/refmod calculations.

2025-05-05 Thread Iain Sandoe
Hi Bob, > On 5 May 2025, at 02:49, Robert Dubner wrote: > > I know it's the weekend. But this has been niggling at me, so I decided > to push it. This causes bootstrap to fail on x86_64 darwin with: Undefined symbols for architecture x86_64: "_program_invocation_short_name", referenced from

[to-be-committed][RISC-V][PR target/119971] Avoid losing shift count masking

2025-05-05 Thread Jeff Law
As is outlined in the PR, we have a few define_insn_and_split patterns which optimize away explicit masking of shift/bit positions when the masking matches what the hardware's behavior. A small number of those define_insn_and_split patterns generate a single instruction. It's fairly elegant i

[pushed]: i386: Do not use explicit operands for MOVS instructions [PR120019]

2025-05-05 Thread Uros Bizjak
Some assemblers do not support MOVS instructions with explicit operands. Emit instruction with implicit operands, but prefix the instruction with a segment override prefix if the memory operand refers to ADDR_SPACE_SEG_FS or ADDR_SPACE_SEG_GS named address space. PR target/120019 gcc/ChangeLo

Re: [PATCH] [PR117978] AArch64: Fold SVE load/store with certain ptrue patterns to LDR/STR.

2025-05-05 Thread Jennifer Schmitz
> On 2 May 2025, at 18:01, Richard Sandiford wrote: > > External email: Use caution opening links or attachments > > > Jennifer Schmitz writes: >> SVE loads/stores using predicates that select the bottom 8, 16, 32, 64, >> or 128 bits of a register can be folded to ASIMD LDR/STR, thus avoidin

[committed] testsuite: Link gcc.dg/lto/modref-2_0 with libm

2025-05-05 Thread John David Anglin
Tested on hppa64-hp-hpux11.11. Committed to trunk. Dave --- testsuite: Link gcc.dg/lto/modref-2_0 with libm 2025-05-05 John David Anglin gcc/testsuite/ChangeLog: PR testsuite/120085 * gcc.dg/lto/modref-2_0.c: Link test with libm. diff --git a/gcc/testsuite/gcc.dg/lto/modre

Re: [PATCH] cfgexpand: Change __builtin_unreachable to __builtin_trap if only thing in function [PR109267]

2025-05-05 Thread Maciej W. Rozycki
On Mon, 28 Apr 2025, Andrew Pinski wrote: > E.g. avr, bpf, c6x, epiphany, fr30, frv, ft32, h8300, lm32, m32c, > m32r, mcore, mmix, mn10300, moxie, msp430, or1k, pdp11, pru, rl78, rx, > (and some others) don't have a trap instruction defined. I can take care about the VAX target; BUGW seems the l

[PATCH] emit-rtl: Add extra checks for paradoxical hardware subregs [PR119966]

2025-05-05 Thread Dimitar Dimitrov
After r16-160-ge6f89d78c1a752, late_combine2 started transforming the following RTL for pru-unknown-elf: (insn 3949 3948 3951 255 (set (reg:QI 56 r14.b0 [orig:1856 _619 ] [1856]) (and:QI (reg:QI 1 r0.b1 [orig:1855 _201 ] [1855]) (const_int 3 [0x3]))) (nil)) ...

Re: [PATCH] libstdc++: Fix width computation for the chrono formatting [PR120114]

2025-05-05 Thread Tomasz Kaminski
On Mon, May 5, 2025 at 4:48 PM Tomasz Kamiński wrote: > Use `__unicode::_field_width` to compute the field width of the output > when writting > the formatted output for std::chrono::types. This applies both to > characters copied > from format string, and one produced by localized formatting. >

Re: [PATCH] RISC-V: Fix gcc.target/riscv/predef-19.c [PR120054]

2025-05-05 Thread Kito Cheng
Pushed to the trunk :) On Mon, May 5, 2025 at 10:03 PM Jeff Law wrote: > > > > On 5/4/25 8:13 PM, Kito Cheng wrote: > > gcc/testsuite/ChangeLog: > > > > PR target/120054 > > * gcc.target/riscv/predef-19.c: Adjust testcase. > If you think it's right fix, then OK. I haven't dove into i

[PATCH] libstdc++: Fix width computation for the chrono formatting [PR120114]

2025-05-05 Thread Tomasz Kamiński
Use `__unicode::_field_width` to compute the field width of the output when writting the formatted output for std::chrono::types. This applies both to characters copied from format string, and one produced by localized formatting. We also use _Str_sink::view() instead of get(), which avoids copy

Re: [PATCH] libstdc++: Provide ability to query _Sink_iter if writes are discarded.

2025-05-05 Thread Tomasz Kaminski
On Mon, May 5, 2025 at 2:55 PM Tomasz Kamiński wrote: > This patch provides an equality operator between _Sink_iter and > default_sentinel, > that returns true, if any further writes to the _Sink_iter and underlying > _Sink, > will be discared, and thus can be omitted. This operator is implemente

Re: [PATCH] RISC-V: Fix gcc.target/riscv/predef-19.c [PR120054]

2025-05-05 Thread Jeff Law
On 5/4/25 8:13 PM, Kito Cheng wrote: gcc/testsuite/ChangeLog: PR target/120054 * gcc.target/riscv/predef-19.c: Adjust testcase. If you think it's right fix, then OK. I haven't dove into it at all. Just want to see it get fixed so the CI/testers are happy again :-) jeff

Re: [PATCH 2/3] x86: Add a pass to fold tail call

2025-05-05 Thread Andi Kleen
On Mon, May 05, 2025 at 06:20:40AM -0700, Andi Kleen wrote: > > If the branch edge destination is a basic block with only a direct > > sibcall, change the jcc target to the sibcall target, decrement the > > destination basic block entry label use count and redirect the edge > > to the exit basic bl

Re: [PATCH] dwarf2out: Propagate dtprel into the .debug_addr table in resolve_addr_in_expr

2025-05-05 Thread Kyle Huey
On Mon, May 5, 2025 at 6:45 AM Richard Biener wrote: > > On Mon, May 5, 2025 at 3:37 PM Kyle Huey wrote: > > > > On Thu, May 1, 2025 at 11:22 PM Richard Biener > > wrote: > > > > > > On Fri, May 2, 2025 at 2:14 AM Kyle Huey wrote: > > > > > > > > For a debugger to display statically-allocated[0

Re: [PATCH] RISC-V: Use vclmul for CRC expansion if available

2025-05-05 Thread Jeff Law
On 5/4/25 10:49 PM, Anton Blanchard wrote: If the vector version of clmul (vclmul) is available and the scalar one is not, use it for CRC expansion. gcc/Changelog: * config/riscv/bitmanip.md (crc_rev4): Check TARGET_ZVBC. (crc4): Likewise. * config/riscv/riscv

Re: [PATCH] dwarf2out: Propagate dtprel into the .debug_addr table in resolve_addr_in_expr

2025-05-05 Thread Richard Biener
On Mon, May 5, 2025 at 3:37 PM Kyle Huey wrote: > > On Thu, May 1, 2025 at 11:22 PM Richard Biener > wrote: > > > > On Fri, May 2, 2025 at 2:14 AM Kyle Huey wrote: > > > > > > For a debugger to display statically-allocated[0] TLS variables the > > > compiler > > > must communicate information[1

Re: [PATCH v1 2/5] RISC-V: Combine vec_duplicate + vadd.vv to vadd.vx on GR2VR cost

2025-05-05 Thread Jeff Law
On 5/3/25 2:14 AM, pan2...@intel.com wrote: From: Pan Li This patch would like to combine the vec_duplicate + vadd.vv to the vadd.vx. From example as below code. The related pattern will depend on the cost of vec_duplicate from GR2VR, it will: * The pattern matching will be active by defa

Re: [PATCH v1 1/5] RISC-V: Add new option --param=rvv-gr2vr-cost= for rvv insn

2025-05-05 Thread Jeff Law
On 5/3/25 2:14 AM, pan2...@intel.com wrote: From: Pan Li During investigate the combine from vec_dup and vop.vv into vop.vx, we need to depend on the cost of the insn operate from the gr to vr, for example, vadd.vx. Thus, for better control and test, we introduce a new option, aka below: -

Re: [PATCH] dwarf2out: Propagate dtprel into the .debug_addr table in resolve_addr_in_expr

2025-05-05 Thread Kyle Huey
On Thu, May 1, 2025 at 11:22 PM Richard Biener wrote: > > On Fri, May 2, 2025 at 2:14 AM Kyle Huey wrote: > > > > For a debugger to display statically-allocated[0] TLS variables the compiler > > must communicate information[1] that can be used in conjunction with > > knowledge > > of the runtime

Re: [PATCH 4/7] OpenMP: Add flag for code elision to omp_context_selector_matches.

2025-05-05 Thread Tobias Burnus
On February 10, 2025, Sandra Loosemore wrote: The "begin declare variant" has different rules for determining whether a context selector cannot match for purposes of code elision than we normally use; it excludes the case of a constant false "condition" selector for the "user" set. Namely: "If

Re: [PATCH 2/3] x86: Add a pass to fold tail call

2025-05-05 Thread Andi Kleen
> If the branch edge destination is a basic block with only a direct > sibcall, change the jcc target to the sibcall target, decrement the > destination basic block entry label use count and redirect the edge > to the exit basic block. Call delete_unreachable_blocks to delete > the unreachable bas

Re: [PATCH v1 1/5] RISC-V: Add new option --param=rvv-gr2vr-cost= for rvv insn

2025-05-05 Thread Robin Dapp
1. those static const var initialized before options, can hardly initialize correct. 2. The --param is somehow experimental, thus I prefer to keep the const GR2VR in static structure as is. I will append a new patch,aka let the reference goes to the new helper if that is OK. Yes that should

RE: [PATCH v1 1/5] RISC-V: Add new option --param=rvv-gr2vr-cost= for rvv insn

2025-05-05 Thread Li, Pan2
Thanks Robin. > The series looks generally reasonable to me now, thanks. But if we have a > parameter that sets GR2VR IMHO it should affect all of its uses. That means > we > should either adjust the regmove costs directly or use the new helper > whenever > GR2VR is currently used. > As we

[PATCH] libstdc++: Provide ability to query _Sink_iter if writes are discarded.

2025-05-05 Thread Tomasz Kamiński
This patch provides an equality operator between _Sink_iter and default_sentinel, that returns true, if any further writes to the _Sink_iter and underlying _Sink, will be discared, and thus can be omitted. This operator is implemented in terms new of _M_discarding virtual function in _Sink. Curre

Re: [PATCH] libstdc++: Fix dangling pointer in fs::path::operator+=(*this) [PR120029]

2025-05-05 Thread Tomasz Kaminski
On Fri, May 2, 2025 at 1:12 PM Jonathan Wakely wrote: > When concatenating a path we reallocate the left operand's storage to > make room for the new components being added. When the two operands are > the same object, or the right operand is one of the components of the > left operand, the reall

Re: [PATCH] Allow a PCH to be mapped to a different address

2025-05-05 Thread Jonathan Yong
On 5/5/25 11:25 AM, LIU Hao wrote: 在 2025-4-28 15:05, LIU Hao 写道: This is a response to https://gcc.gnu.org/bugzilla/show_bug.cgi? id=14940#c57 The patch was submitted to MSYS2 for testing in 2022-5. No issue reports have been received so far: * https://github.com/msys2/MINGW-packages/ blo

Re: [PATCH 3/7] OpenMP: Support functions for nested "begin declare variant"

2025-05-05 Thread Tobias Burnus
Hi Sandra, hello world, On Feburary 10, 2025, Sandra Loosemore wrote: This patch adds functions for variant name mangling and context selector merging that are shared by the C and C++ front ends. The OpenMP specification says that name mangling is supposed to encode the context selector for the

Re: [PATCH] i386: Quote user-defined symbols in assembly in Intel syntax

2025-05-05 Thread LIU Hao
在 2025-4-28 14:43, LIU Hao 写道: Hello, I'm sending this patch again after GCC 15 has been released. This patch was sent in February and but there were no comments: https://patchwork.sourceware.org/project/gcc/patch/eca6660c-6578-4e39-8aa9-be9fdd013...@126.com/ Ping. -- Best regards, LIU Ha

Re: [PATCH] Allow a PCH to be mapped to a different address

2025-05-05 Thread LIU Hao
在 2025-4-28 15:05, LIU Hao 写道: This is a response to https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14940#c57 The patch was submitted to MSYS2 for testing in 2022-5. No issue reports have been received so far: * https://github.com/msys2/MINGW-packages/blob/455762a45250642b90e9ff34020d001c1be0901

[Ada] Fix PR ada/120104

2025-05-05 Thread Eric Botcazou
This is a (benign) assertion failure on the mainline for the new Finalizable aspect put on a tagged record type, when not all the primitives are declared. This compiles and runs on the 15 branch because assertions are disabled. Tested on x86-64/Linux, applied on the mainline and 15 branch. 2025

Re: 'libgomp.c/interop-hsa.c': GCN offloading only

2025-05-05 Thread Tobias Burnus
Thomas Schwinge wrote: I've pushed to trunk branch commit 85ad0d84fcec720c1d94b9bda9a617ced70ba5d2 "'libgomp.c/interop-hsa.c': GCN offloading only", see attached. Thanks! If nvptx offloading compilation is enabled in addition to GCN, the former ICEs: during RTL pass: final [...]/l

Re: [PATCH] libstdc++: Rewrite atomic builtin checks [PR70560]

2025-05-05 Thread Tomasz Kaminski
On Wed, Apr 30, 2025 at 2:30 PM Jonathan Wakely wrote: > On Wed, 30 Apr 2025 at 12:12, Tomasz Kaminski wrote: > > > > > > > > On Tue, Apr 29, 2025 at 10:11 PM Jonathan Wakely > wrote: > >> > >> Currently the GLIBCXX_ENABLE_ATOMIC_BUILTINS macro checks for a variety > >> of __atomic built-ins fo

Re: [PATCH v4] libstdc++: Implement C++26 features (P2546R5)

2025-05-05 Thread Uros Bizjak
On Thu, May 1, 2025 at 12:59 PM Jonathan Wakely wrote: > > This includes the P2810R4 (is_debugger_present is_replaceable) changes, > allowing std::is_debugger_present to be replaced by the program. > > It would be good to provide a macOS definition of is_debugger_present as > per https://developer

[pushed] c++: Remove obsolete prototype

2025-05-05 Thread Simon Martin
I noticed while investigating PR c++/119437 that r8-2724-g88b811bd290630 removed parsing_default_capturing_generic_lambda_in_template but not its prototype in cp-tree.h. This patch fixes this. Successfully tested on x86_64-pc-linux-gnu, and pushed as obvious. gcc/cp/ChangeLog: * cp-tree

Re: [PATCH 2/3] Flip default to LRA for targets with -mlra

2025-05-05 Thread John Paul Adrian Glaubitz
Hi, On Mon, 2025-05-05 at 10:14 +0200, Richard Biener wrote: > > I just noticed that my builds were with --disable-bootstrap. *sigh* > > Note I'd consider that "fine", it gives you a build that was able to > build libgcc and thus it will allow you to make check and debug > from there (with nice s

Re: [PATCH v4] libstdc++: Implement C++26 features (P2546R5)

2025-05-05 Thread Jonathan Wakely
On Mon, 5 May 2025, 09:53 Jonathan Wakely, wrote: > > > On Mon, 5 May 2025, 09:23 Sam James, wrote: > >> Jonathan Wakely writes: >> >> > [...] >> > +void >> > +std::breakpoint() noexcept >> > +{ >> > + PROBE(std::breakpoint); >> > + >> > + if (__gnu_cxx::debugger_signal_for_breakpoint > 0) >>

Re: [PATCH v4] libstdc++: Implement C++26 features (P2546R5)

2025-05-05 Thread Tomasz Kaminski
On Mon, May 5, 2025 at 10:55 AM Jonathan Wakely wrote: > > > On Mon, 5 May 2025, 09:23 Sam James, wrote: > >> Jonathan Wakely writes: >> >> > [...] >> > +void >> > +std::breakpoint() noexcept >> > +{ >> > + PROBE(std::breakpoint); >> > + >> > + if (__gnu_cxx::debugger_signal_for_breakpoint >

Re: [PATCH v4] libstdc++: Implement C++26 features (P2546R5)

2025-05-05 Thread Jonathan Wakely
On Mon, 5 May 2025, 09:23 Sam James, wrote: > Jonathan Wakely writes: > > > [...] > > +void > > +std::breakpoint() noexcept > > +{ > > + PROBE(std::breakpoint); > > + > > + if (__gnu_cxx::debugger_signal_for_breakpoint > 0) > > +std::raise(__gnu_cxx::debugger_signal_for_breakpoint); > > +

Re: [RFC PATCH 0/2] Add target_clones profile option support

2025-05-05 Thread Yangyu Chen
> On 5 May 2025, at 16:34, Kyrylo Tkachov wrote: > > > >> On 4 May 2025, at 19:19, Yangyu Chen wrote: >> >> Hi everyone, >> >> This patch series introduces support for the target_clones profile >> option in GCC. This option enables users to specify target_clones >> attributes in a separat

vect-simd-clone-1[6-8][cd].c: Expect in-branch clones for x86: Fix target selector syntax (was: [PATCH stage1 4/6] vect-simd-clone-1[6-8][cd].c: Expect in-branch clones for x86)

2025-05-05 Thread Thomas Schwinge
Hi! On 2025-03-14T15:42:48-0700, "H.J. Lu" wrote: > --- a/gcc/testsuite/gcc.dg/vect/vect-simd-clone-16c.c > +++ b/gcc/testsuite/gcc.dg/vect/vect-simd-clone-16c.c > @@ -7,11 +7,8 @@ > > /* Ensure the the in-branch simd clones are used on targets that support > them. > Some targets use anot

'libgomp.c/interop-hsa.c': GCN offloading only (was: [PATCH] OpenMP, GCN: Add interop-hsa testcase)

2025-05-05 Thread Thomas Schwinge
Hi! On 2025-04-25T10:33:39+, Andrew Stubbs wrote: > --- /dev/null > +++ b/libgomp/testsuite/libgomp.c/interop-hsa.c > @@ -0,0 +1,203 @@ > +/* { dg-additional-options "-ldl" } */ > +/* { dg-require-effective-target offload_device_gcn } */ This means that a GCN offloading device must be availa

Re: [RFC PATCH 0/2] Add target_clones profile option support

2025-05-05 Thread Kyrylo Tkachov
> On 4 May 2025, at 19:19, Yangyu Chen wrote: > > Hi everyone, > > This patch series introduces support for the target_clones profile > option in GCC. This option enables users to specify target_clones > attributes in a separate file, allowing GCC to generate multiple > versions of the functio

Re: [PATCH] c++: Inhibit subsequent warnings/notes in diagnostic_groups with an inhibited warning [PR118163,PR118392]

2025-05-05 Thread Simon Martin
Hi, On Tue Jan 14, 2025 at 11:39 PM CET, Jason Merrill wrote: > On 1/14/25 8:25 AM, Simon Martin wrote: >> [ Apologies for the previous incomplete, garbled email - I used the >> shortcut to send the email by mistake way too early ] >> >> Hi Jason, >> >> On 14 Jan 2025, at 11:43, Simon Martin wro

Re: [PATCH v4] libstdc++: Implement C++26 features (P2546R5)

2025-05-05 Thread Sam James
Jonathan Wakely writes: > [...] > +void > +std::breakpoint() noexcept > +{ > + PROBE(std::breakpoint); > + > + if (__gnu_cxx::debugger_signal_for_breakpoint > 0) > +std::raise(__gnu_cxx::debugger_signal_for_breakpoint); > + glib's https://gitlab.gnome.org/GNOME/glib/-/blob/main/glib/gbackt

Re: [PATCH v4] libstdc++: Implement C++26 features (P2546R5)

2025-05-05 Thread Tomasz Kaminski
On Thu, May 1, 2025 at 12:59 PM Jonathan Wakely wrote: > This includes the P2810R4 (is_debugger_present is_replaceable) changes, > allowing std::is_debugger_present to be replaced by the program. > > It would be good to provide a macOS definition of is_debugger_present as > per https://developer.

Re: [PATCH] gimple-fold: Fix fold_truth_andor_for_ifcombine [PR120074]

2025-05-05 Thread Richard Biener
On Mon, 5 May 2025, Jakub Jelinek wrote: > Hi! > > The following testcase ICEs because of a mismatch between wide_int > precision, in particular lr_and_mask has 32-bit precision while sign has > 16-bit. > > decode_field_reference ensures that {ll,lr,rl,rr}_and_mask has > {ll,lr,rl,rr}_bitsize pr

Re: [PATCH] i386: Implement Thread Local Storage on Windows

2025-05-05 Thread Jonathan Yong
On 5/5/25 6:14 AM, Julian Waters wrote: gcc bootstrap works on my end pretty well, but you know what they say, no one likes an "It works on my device" developer :) In all seriousness, no observable problems were seen on my end, apart from all the existing ucrt64 programs failing to run because o

Re: [PATCH 2/3] Flip default to LRA for targets with -mlra

2025-05-05 Thread Richard Biener
On Sun, 4 May 2025, John Paul Adrian Glaubitz wrote: > Hi, > > On Sun, 2025-05-04 at 11:18 +0200, John Paul Adrian Glaubitz wrote: > > On Fri, 2025-05-02 at 12:12 +0200, Richard Biener wrote: > > > This flips the default to LRA for targets with an -mlra option not > > > using Mask(..). > > > > >

[PATCH] gimple-fold, v2: Fix fold_truth_andor_for_ifcombine [PR120074]

2025-05-05 Thread Jakub Jelinek
On Mon, May 05, 2025 at 09:02:15AM +0200, Jakub Jelinek wrote: > The other option would be > + if (ll_bitsize != lr_bitsize) > + return 0; > if (!lr_and_mask.get_precision ()) > lr_and_mask = sign; > else > lr_and_mask &= sign; > and similarly in th

Re: [PATCH] libstdc++: Add noexcept to some std::counted_iterator operations

2025-05-05 Thread Tomasz Kaminski
On Fri, May 2, 2025 at 1:06 PM Jonathan Wakely wrote: > This was inspired by LWG 4245 but goes further. Anything which only > reads or writes the _M_length member can be noexcept. That > member is an iterator difference_type which means it's a signed integer > type or the __max_diff_type integer-

Re: [PATCH v5 05/10] libstdc++: Implement layout_left from mdspan.

2025-05-05 Thread Tomasz Kaminski
On Sat, May 3, 2025 at 4:45 PM Luc Grosheintz wrote: > Topic: follow up question about operator() for layout_stride. > > On 4/30/25 7:13 AM, Tomasz Kaminski wrote: > > Hi, > > > > As we will be landing patches for extends, this will become a separate > > patch series. > > I would prefer, if you c

Re: [PATCH v1 1/5] RISC-V: Add new option --param=rvv-gr2vr-cost= for rvv insn

2025-05-05 Thread Robin Dapp
Hi Pan, During investigate the combine from vec_dup and vop.vv into vop.vx, we need to depend on the cost of the insn operate from the gr to vr, for example, vadd.vx. Thus, for better control and test, we introduce a new option, aka below: --param=rvv-gr2vr-cost= +static inline int +get_vec

Re: [PATCH v5 05/10] libstdc++: Implement layout_left from mdspan.

2025-05-05 Thread Tomasz Kaminski
On Sat, May 3, 2025 at 3:42 PM Luc Grosheintz wrote: > This chain discusses changes to `mapping::operator()`. For concrete > discussion, see below. I have a general question: is there a reason > other than style to prefer folds over recursion? > > > On 4/30/25 7:13 AM, Tomasz Kaminski wrote: > >

Re: [PATCH v5 05/10] libstdc++: Implement layout_left from mdspan.

2025-05-05 Thread Tomasz Kaminski
On Sat, May 3, 2025 at 2:39 PM Luc Grosheintz wrote: > > > On 4/30/25 7:13 AM, Tomasz Kaminski wrote: > > Hi, > > > > As we will be landing patches for extends, this will become a separate > > patch series. > > I would prefer, if you could commit per layout, and start with > layout_right > > (def

[committed] i386: Fix comment typo on truncsfbf2 pattern

2025-05-05 Thread Jakub Jelinek
Hi! I've noticed a typo on the flag name, fixed thusly. Bootstrapped/regtested on x86_64-linux and i686-linux, committed to trunk as obvious. 2025-05-05 Jakub Jelinek * config/i386/i386.md (truncsfbf2): Fix comment typo, unsafte -> unsafe. --- gcc/config/i386/i386.md.jj 202

[PATCH] testsuite/120084 - adjust gcc.dg/lto/pr60779_0.c

2025-05-05 Thread Richard Biener
Require the linker plugin so functions are properly detected as unused when inlined. Pushed. PR testsuite/120084 * gcc.dg/lto/pr60779_0.c: Require linker-plugin. --- gcc/testsuite/gcc.dg/lto/pr60779_0.c | 1 + 1 file changed, 1 insertion(+) diff --git a/gcc/testsuite/gcc.dg/lto/

[PATCH] gimple-fold: Fix fold_truth_andor_for_ifcombine [PR120074]

2025-05-05 Thread Jakub Jelinek
Hi! The following testcase ICEs because of a mismatch between wide_int precision, in particular lr_and_mask has 32-bit precision while sign has 16-bit. decode_field_reference ensures that {ll,lr,rl,rr}_and_mask has {ll,lr,rl,rr}_bitsize precision, so the ll_and_mask |= sign; and r

Re: [PATCH 4/4] phiopt: Use rewrite_to_defined_overflow in move_stmt [PR116938]

2025-05-05 Thread Richard Biener
On Mon, May 5, 2025 at 3:42 AM Andrew Pinski wrote: > > As mentioned previously the rewrite in move_stmt should be > using rewrite_to_defined_overflow/gimple_with_undefined_signed_overflow > instead of just rewriting the VCE. > This moves move_stmt over to that. > > A few testcases needed to be up