Re: [PATCH 09/52] Replace {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE with new hook mode_for_floating_type

2024-06-02 Thread Richard Biener
On Mon, Jun 3, 2024 at 5:02 AM Kewen Lin wrote: > > Currently how we determine which mode will be used for a > floating point type is that for a given type precision > (size) call mode_for_size to get the first mode which has > this size in the specified class. On Powerpc, we have > three modes (

Re: [PATCH] Add AVX10.1 target_clones support

2024-06-02 Thread Hongtao Liu
On Wed, May 29, 2024 at 11:05 AM Haochen Jiang wrote: > > Hi all, > > Since AVX10 is the first major ISA introduced after AVX-512, we propose > to add target_clones support for it. > > Although AVX10.1-256 won't cover 512-bit part of AVX512F, but since > it is only for priority but not for implica

Re: [RFC][PATCH] PR tree-optimization/109071 - -Warray-bounds false positive warnings due to code duplication from jump threading

2024-06-02 Thread Richard Biener
On Fri, May 31, 2024 at 11:23 PM Qing Zhao wrote: > > > > > On May 23, 2024, at 07:46, Richard Biener > > wrote: > > > > On Wed, May 22, 2024 at 8:53 PM Qing Zhao wrote: > >> > >> > >> > >>> On May 22, 2024, at 03:38, Richard Biener > >>> wrote: > >>> > >>> On Tue, May 21, 2024 at 11:36 PM Da

Re: RISC-V: Patches need to be backport to GCC-14

2024-06-02 Thread Kito Cheng
Yeah, I think both should back port to GCC-14, but I would like to wait one more week like the convention within the GCC community :) On Mon, Jun 3, 2024 at 10:05 AM juzhe.zh...@rivai.ai wrote: > > Hi, I saw Robin commit these following patches: > https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=978

Ping [PATCH] aarch64: Add vector popcount besides QImode [PR113859]

2024-06-02 Thread Pengxuan Zheng (QUIC)
Ping > -Original Message- > From: Pengxuan Zheng (QUIC) > Sent: Tuesday, April 30, 2024 5:32 PM > To: gcc-patches@gcc.gnu.org > Cc: Andrew Pinski (QUIC) ; Pengxuan Zheng > (QUIC) > Subject: [PATCH] aarch64: Add vector popcount besides QImode [PR113859] > > This patch improves GCC’s vect

Re: [PATCH 41/52] riscv: New hook implementation riscv_c_mode_for_floating_type

2024-06-02 Thread Kito Cheng
LGTM from RISC-V, thanks :) On Mon, Jun 3, 2024 at 11:08 AM Kewen Lin wrote: > > This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE > defines in riscv port, and add new port specific hook > implementation riscv_c_mode_for_floating_type. > > gcc/ChangeLog: > > * config/riscv/riscv.c

Re: [PATCH] Fix -Wstringop-overflow warning in 23_containers/vector/types/1.cc PR109849

2024-06-02 Thread François Dumont
I hadn't try to make my patch as limited as possible to fix the problem, indeed.     libstdc++: Fix -Wstringop-overflow warning coming from std::vector [PR109849]     libstdc++-v3/ChangeLog:     PR libstdc++/109849     * include/bits/vector.tcc     (std::vector<>::_M_

[PATCH v2 1/2] Factor out static_assert constexpr string extraction for reuse

2024-06-02 Thread Andi Kleen
No intentional semantics change. gcc/cp/ChangeLog: * cp-tree.h (struct cstr): Add structure. (get_cstr): Declare. (extract_cstr): Declare. (free_cstr): Declare. * semantics.cc (finish_static_assert): Factor out constant string expression extraction

[PATCH v2 2/2] C++: Support constexpr strings for asm statements

2024-06-02 Thread Andi Kleen
Some programing styles use a lot of inline assembler, and it is common to use very complex preprocessor macros to generate the assembler strings for the asm statements. In C++ there would be a typesafe alternative using templates and constexpr to generate the assembler strings, but unfortunately th

RE: [PATCH v1 1/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 1

2024-06-02 Thread Li, Pan2
Thanks Juzhe, will commit it after the middle-end patch, as well as the rest similar 4 patches. Pan From: juzhe.zh...@rivai.ai Sent: Monday, June 3, 2024 11:19 AM To: Li, Pan2 ; gcc-patches Cc: kito.cheng ; Li, Pan2 Subject: Re: [PATCH v1 1/5] RISC-V: Add testcases for scalar unsigned SAT_ADD

Re: [PATCH v1 5/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 5

2024-06-02 Thread juzhe.zh...@rivai.ai
LGTM. Thanks. juzhe.zh...@rivai.ai From: pan2.li Date: 2024-06-03 11:09 To: gcc-patches CC: juzhe.zhong; kito.cheng; Pan Li Subject: [PATCH v1 5/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 5 From: Pan Li After the middle-end support the form 5 of unsigned SAT_ADD and the RISC-

Re: [PATCH v1 4/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 4

2024-06-02 Thread juzhe.zh...@rivai.ai
LGTM. Thanks. juzhe.zh...@rivai.ai From: pan2.li Date: 2024-06-03 11:09 To: gcc-patches CC: juzhe.zhong; kito.cheng; Pan Li Subject: [PATCH v1 4/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 4 From: Pan Li After the middle-end support the form 4 of unsigned SAT_ADD and the RISC-

Re: [PATCH v1 2/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 2

2024-06-02 Thread juzhe.zh...@rivai.ai
LGTM. Thanks. juzhe.zh...@rivai.ai From: pan2.li Date: 2024-06-03 11:09 To: gcc-patches CC: juzhe.zhong; kito.cheng; Pan Li Subject: [PATCH v1 2/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 2 From: Pan Li After the middle-end support the form 2 of unsigned SAT_ADD and the RISC-

Re: [PATCH v1 3/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 3

2024-06-02 Thread juzhe.zh...@rivai.ai
LGTM. Thanks. juzhe.zh...@rivai.ai From: pan2.li Date: 2024-06-03 11:09 To: gcc-patches CC: juzhe.zhong; kito.cheng; Pan Li Subject: [PATCH v1 3/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 3 From: Pan Li After the middle-end support the form 3 of unsigned SAT_ADD and the RISC-

Re: [PATCH v1 1/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 1

2024-06-02 Thread juzhe.zh...@rivai.ai
LGTM. Thanks. juzhe.zh...@rivai.ai From: pan2.li Date: 2024-06-03 11:09 To: gcc-patches CC: juzhe.zhong; kito.cheng; Pan Li Subject: [PATCH v1 1/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 1 From: Pan Li After the middle-end support the form 1 of unsigned SAT_ADD and the RISC-

Re: [PATCH 45/52] sh: New hook implementation sh_c_mode_for_floating_type

2024-06-02 Thread Oleg Endo
Hi! On Sun, 2024-06-02 at 22:01 -0500, Kewen Lin wrote: > This is to remove macro LONG_DOUBLE_TYPE_SIZE define in > sh port, and add new port specific hook implementation > sh_c_mode_for_floating_type. > The SH parts look OK to me. Best regards, Oleg Endo > gcc/ChangeLog: > > * confi

[PATCH] [x86] Add some preference for floating point rtl ifcvt when sse4.1 is not available

2024-06-02 Thread liuhongt
W/o TARGET_SSE4_1, it takes 3 instructions (pand, pandn and por) for movdfcc/movsfcc, and could possibly fail cost comparison. Increase branch cost could hurt performance for other modes, so specially add some preference for floating point ifcvt. Bootstrapped and regtested on x86_64-pc-linux-gnu{-

[PATCH v1 3/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 3

2024-06-02 Thread pan2 . li
From: Pan Li After the middle-end support the form 3 of unsigned SAT_ADD and the RISC-V backend implement the scalar .SAT_ADD, add more test case to cover the form 3 of unsigned .SAT_ADD. Form 3: #define SAT_ADD_U_3(T) \ T sat_add_u_3_##T (T x, T y) \ { \ T ret; \ return __builtin_

[PATCH v1 1/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 1

2024-06-02 Thread pan2 . li
From: Pan Li After the middle-end support the form 1 of unsigned SAT_ADD and the RISC-V backend implement the scalar .SAT_ADD, add more test case to cover the form 1 of unsigned .SAT_ADD. Form 1: #define SAT_ADD_U_1(T) \ T sat_add_u_1_##T(T x, T y) \ {

[PATCH v1 4/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 4

2024-06-02 Thread pan2 . li
From: Pan Li After the middle-end support the form 4 of unsigned SAT_ADD and the RISC-V backend implement the scalar .SAT_ADD, add more test case to cover the form 4 of unsigned .SAT_ADD. Form 4: #define SAT_ADD_U_4(T) \ T sat_add_u_4_##T (T x, T y) \ { \ T ret; \ return __builtin_

[PATCH 04/52] go: Replace uses of {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
Joseph pointed out "floating types should have their mode, not a poorly defined precision value" in the discussion[1], as he and Richi suggested, the existing macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE will be replaced with a hook mode_for_floating_type. To be prepared for that, this patch is to repl

[PATCH 52/52] bfin: Rename macros {FLOAT,DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This patch is to remove LONG_DOUBLE_TYPE_SIZE and rename macros {FLOAT,DOUBLE}_TYPE_SIZE with prefix BFIN_ as some macro defines want to use them, keeping them can have better code readability. gcc/ChangeLog: * config/bfin/bfin.h (FLOAT_TYPE_SIZE): Rename to ... (BFIN_FLOAT_TYPE_S

[PATCH v1 2/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 2

2024-06-02 Thread pan2 . li
From: Pan Li After the middle-end support the form 2 of unsigned SAT_ADD and the RISC-V backend implement the scalar .SAT_ADD, add more test case to cover the form 2 of unsigned .SAT_ADD. Form 2: #define SAT_ADD_U_2(T) \ T sat_add_u_2_##T(T x, T y) \ { \ T ret; \ T overflow = __bu

[PATCH 44/52] s390: New hook implementation s390_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in s390 port, and add new port specific hook implementation s390_c_mode_for_floating_type. gcc/ChangeLog: * config/s390/s390.cc (s390_c_mode_for_floating_type): New function. (TARGET_C_MODE_FOR_FLOATING_TYPE): New m

[PATCH 49/52] mips: New hook implementation mips_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to add new port specific hook implementation mips_c_mode_for_floating_type, remove macros FLOAT_TYPE_SIZE and DOUBLE_TYPE_SIZE, rename LONG_DOUBLE_TYPE_SIZE to MIPS_LONG_DOUBLE_TYPE_SIZE since we poison LONG_DOUBLE_TYPE_SIZE but some subtarget wants to redefine it and some macro defines nee

[PATCH 47/52] loongarch: New hook implementation loongarch_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to add new port specific hook implementation loongarch_c_mode_for_floating_type, remove macro defines for FLOAT_TYPE_SIZE and DOUBLE_TYPE_SIZE, and rename LONG_DOUBLE_TYPE_SIZE to LA_LONG_DOUBLE_TYPE_SIZE as we poison LONG_DOUBLE_TYPE_SIZE but some macros need LONG_DOUBLE_TYPE_SIZE. gcc/Ch

[PATCH 48/52] m68k: New hook implementation m68k_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to add new port specific hook implementation m68k_c_mode_for_floating_type, remove macro LONG_DOUBLE_TYPE_SIZE and add new macro LONG_DOUBLE_TYPE_MODE which some subtarget can redefine. gcc/ChangeLog: * config/m68k/m68k.cc (m68k_c_mode_for_floating_type): New function. (TA

[PATCH 45/52] sh: New hook implementation sh_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to remove macro LONG_DOUBLE_TYPE_SIZE define in sh port, and add new port specific hook implementation sh_c_mode_for_floating_type. gcc/ChangeLog: * config/sh/sh.cc (sh_c_mode_for_floating_type): New function. (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro. * config/

[PATCH 36/52] aarch64: New hook implementation aarch64_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in aarch64 port, and add new port specific hook implementation aarch64_c_mode_for_floating_type. gcc/ChangeLog: * config/aarch64/aarch64.cc (aarch64_c_mode_for_floating_type): New function. (TARGET_C_MODE_FO

[PATCH 38/52] avr: New hook implementation avr_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in avr port, and add new port specific hook implementation avr_c_mode_for_floating_type. gcc/ChangeLog: * config/avr/avr.cc (avr_c_mode_for_floating_type): New function. (TARGET_C_MODE_FOR_FLOATING_TYPE): Ne

[PATCH 50/52] pa: New hook implementation pa_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to add new port specific hook implementation pa_c_mode_for_floating_type, as we remove defines in defaults.h for {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE, this also defines them in pa.h but with PA_ prefix since we poison {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE. gcc/ChangeLog: * config/pa/pa.cc

[PATCH 40/52] ia64: New hook implementation ia64_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in ia64 port, and add new port specific hook implementation ia64_c_mode_for_floating_type. gcc/ChangeLog: * config/ia64/ia64.cc (ia64_c_mode_for_floating_type): New function. (TARGET_C_MODE_FOR_FLOATING_TYPE

[PATCH v1 5/5] RISC-V: Add testcases for scalar unsigned SAT_ADD form 5

2024-06-02 Thread pan2 . li
From: Pan Li After the middle-end support the form 5 of unsigned SAT_ADD and the RISC-V backend implement the scalar .SAT_ADD, add more test case to cover the form 5 of unsigned .SAT_ADD. Form 5: #define SAT_ADD_U_5(T) \ T sat_add_u_5_##T(T x, T y) \ { \ return (T)(x + y) < x ? -1 : (x

[PATCH 30/52] pdp11: Remove macro LONG_DOUBLE_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macro LONG_DOUBLE_TYPE_SIZE define in pdp11 port. gcc/ChangeLog: * config/pdp11/pdp11.h (LONG_DOUBLE_TYPE_SIZE): Remove. --- gcc/config/pdp11/pdp11.h | 11 --- 1 file changed, 11 deletions(-) diff --git a/gcc/config/pdp11/pdp11.h b/gcc/config/pdp11/pdp11.h inde

[PATCH 37/52] alpha: New hook implementation alpha_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in alpha port, and add new port specific hook implementation alpha_c_mode_for_floating_type. gcc/ChangeLog: * config/alpha/alpha.cc (alpha_c_mode_for_floating_type): New function. (TARGET_C_MODE_FOR_FLOATING

[PATCH 46/52] h8300: New hook implementation h8300_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to add new port specific hook implementation h8300_c_mode_for_floating_type, remove useless macro defines for {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE and add new macro DOUBLE_TYPE_MODE which some subtarget can redefine. gcc/ChangeLog: * config/h8300/h8300.cc (h8300_c_mode_for_floating_ty

[PATCH 39/52] i386: New hook implementation ix86_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in i386 port, and add new port specific hook implementation ix86_c_mode_for_floating_type. gcc/ChangeLog: * config/i386/i386.cc (ix86_c_mode_for_floating_type): New function. (TARGET_C_MODE_FOR_FLOATING_TYPE

[PATCH 34/52] xtensa: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in xtensa port. gcc/ChangeLog: * config/xtensa/xtensa.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/xtensa/xtensa.h | 3 --- 1 file changed, 3

[PATCH 43/52] rx: New hook implementation rx_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in rx port, and add new port specific hook implementation rx_c_mode_for_floating_type. gcc/ChangeLog: * config/rx/rx.cc (rx_c_mode_for_floating_type): New function. (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.

[PATCH 51/52] sparc: New hook implementation sparc_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to add new port specific hook implementation sparc_c_mode_for_floating_type, remove macros {FLOAT,DOUBLE}_TYPE_SIZE defines and rename LONG_DOUBLE_TYPE_SIZE to SPARC_LONG_DOUBLE_TYPE_SIZE as we poison LONG_DOUBLE_TYPE_SIZE and some subtargets still want to re-define it. gcc/ChangeLog:

[PATCH 28/52] nvptx: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in nvptx port. gcc/ChangeLog: * config/nvptx/nvptx.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/nvptx/nvptx.h | 3 --- 1 file changed, 3 delet

[PATCH 32/52] stormy16: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in stormy16 port. gcc/ChangeLog: * config/stormy16/stormy16.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/stormy16/stormy16.h | 6 -- 1 fil

[PATCH 23/52] mmix: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in mmix port. gcc/ChangeLog: * config/mmix/mmix.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/mmix/mmix.h | 4 1 file changed, 4 deletions

[PATCH 31/52] pru: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in pru port. gcc/ChangeLog: * config/pru/pru.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/pru/pru.h | 3 --- 1 file changed, 3 deletions(-) d

[PATCH 22/52] microblaze: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in microblaze port. gcc/ChangeLog: * config/microblaze/microblaze.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/microblaze/microblaze.h | 3 ---

[PATCH 42/52] rl78: New hook implementation rl78_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in rl78 port, and add new port specific hook implementation rl78_c_mode_for_floating_type. gcc/ChangeLog: * config/rl78/rl78.cc (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro. (rl78_c_mode_for_floating_type): New func

[PATCH 27/52] nios2: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in nios2 port. gcc/ChangeLog: * config/nios2/nios2.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/nios2/nios2.h | 3 --- 1 file changed, 3 delet

[PATCH 33/52] visium: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in visium port. gcc/ChangeLog: * config/visium/visium.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/visium/visium.h | 29 ++

[PATCH 17/52] gcn: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in gcn port. gcc/ChangeLog: * config/gcn/gcn.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/gcn/gcn.h | 3 --- 1 file changed, 3 deletions(-) d

[PATCH 20/52] m32c: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in m32c port. gcc/ChangeLog: * config/m32c/m32c.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/m32c/m32c.h | 4 1 file changed, 4 deletions

[PATCH 41/52] riscv: New hook implementation riscv_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in riscv port, and add new port specific hook implementation riscv_c_mode_for_floating_type. gcc/ChangeLog: * config/riscv/riscv.cc (riscv_c_mode_for_floating_type): New function. (TARGET_C_MODE_FOR_FLOATING_TYPE):

[PATCH 26/52] nds32: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in nds32 port. gcc/ChangeLog: * config/nds32/nds32.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/nds32/nds32.h | 4 1 file changed, 4 dele

[PATCH 16/52] ft32: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in ft32 port. gcc/ChangeLog: * config/ft32/ft32.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/ft32/ft32.h | 4 1 file changed, 4 deletions

[PATCH 21/52] m32r: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in m32r port. gcc/ChangeLog: * config/m32r/m32r.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/m32r/m32r.h | 3 --- 1 file changed, 3 deletions(

[PATCH 11/52] arc: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in arc port. gcc/ChangeLog: * config/arc/arc.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/arc/arc.h | 3 --- 1 file changed, 3 deletions(-) d

[PATCH 35/52] rs6000: New hook implementation rs6000_c_mode_for_floating_type

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in rs6000 port, and add new port specific hook implementation rs6000_c_mode_for_floating_type. gcc/ChangeLog: * config/rs6000/rs6000.cc (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro. (rs6000_c_mode_for_floating_type)

[PATCH 19/52] lm32: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in lm32 port. gcc/ChangeLog: * config/lm32/lm32.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/lm32/lm32.h | 4 1 file changed, 4 deletions

[PATCH 14/52] fr30: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in fr30 port. gcc/ChangeLog: * config/fr30/fr30.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/fr30/fr30.h | 3 --- 1 file changed, 3 deletions(

[PATCH 12/52] bpf: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in bpf port. gcc/ChangeLog: * config/bpf/bpf.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/bpf/bpf.h | 3 --- 1 file changed, 3 deletions(-) d

[PATCH 18/52] iq2000: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in iq2000 port. gcc/ChangeLog: * config/iq2000/iq2000.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/iq2000/iq2000.h | 3 --- 1 file changed, 3

[PATCH 29/52] or1k: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in or1k port. gcc/ChangeLog: * config/or1k/or1k.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/or1k/or1k.h | 3 --- 1 file changed, 3 deletions(

[PATCH 09/52] Replace {FLOAT, {, LONG_}DOUBLE}_TYPE_SIZE with new hook mode_for_floating_type

2024-06-02 Thread Kewen Lin
Currently how we determine which mode will be used for a floating point type is that for a given type precision (size) call mode_for_size to get the first mode which has this size in the specified class. On Powerpc, we have three modes (TF/KF/IF) having the same mode precision 128 (see[1]), so the

[PATCH 15/52] frv: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in frv port. gcc/ChangeLog: * config/frv/frv.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/frv/frv.h | 3 --- 1 file changed, 3 deletions(-) d

[PATCH 08/52] vms: Replace use of LONG_DOUBLE_TYPE_SIZE

2024-06-02 Thread Kewen Lin
Joseph pointed out "floating types should have their mode, not a poorly defined precision value" in the discussion[1], as he and Richi suggested, the existing macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE will be replaced with a hook mode_for_floating_type. To be prepared for that, this patch is to repl

[PATCH 03/52] fortran: Replace uses of {FLOAT, {, LONG_}DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
Joseph pointed out "floating types should have their mode, not a poorly defined precision value" in the discussion[1], as he and Richi suggested, the existing macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE will be replaced with a hook mode_for_floating_type. To be prepared for that, this patch is to repl

[PATCH 24/52] moxie: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in moxie port. gcc/ChangeLog: * config/moxie/moxie.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/moxie/moxie.h | 4 1 file changed, 4 dele

[PATCH 10/52] jit: Replace uses of {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
Joseph pointed out "floating types should have their mode, not a poorly defined precision value" in the discussion[1], as he and Richi suggested, the existing macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE will be replaced with a hook mode_for_floating_type. Unlike the other FEs, for the uses in recordin

[PATCH 06/52] m2: Replace uses of {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
Joseph pointed out "floating types should have their mode, not a poorly defined precision value" in the discussion[1], as he and Richi suggested, the existing macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE will be replaced with a hook mode_for_floating_type. To be prepared for that, this patch is to repl

[PATCH 05/52] rust: Replace uses of {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
Joseph pointed out "floating types should have their mode, not a poorly defined precision value" in the discussion[1], as he and Richi suggested, the existing macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE will be replaced with a hook mode_for_floating_type. To be prepared for that, this patch is to repl

[PATCH 02/52] d: Replace use of LONG_DOUBLE_TYPE_SIZE

2024-06-02 Thread Kewen Lin
Joseph pointed out "floating types should have their mode, not a poorly defined precision value" in the discussion[1], as he and Richi suggested, the existing macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE will be replaced with a hook mode_for_floating_type. To be prepared for that, this patch is to repl

[PATCH 25/52] msp430: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in msp430 port. gcc/ChangeLog: * config/msp430/msp430.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/msp430/msp430.h | 4 1 file changed, 4

[PATCH 13/52] epiphany: Remove macros {FLOAT, DOUBLE, LONG_DOUBLE}_TYPE_SIZE

2024-06-02 Thread Kewen Lin
This is to remove macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE defines in epiphany port. gcc/ChangeLog: * config/epiphany/epiphany.h (FLOAT_TYPE_SIZE): Remove. (DOUBLE_TYPE_SIZE): Likewise. (LONG_DOUBLE_TYPE_SIZE): Likewise. --- gcc/config/epiphany/epiphany.h | 3 --- 1 file c

[PATCH 07/52] darwin: Replace use of LONG_DOUBLE_TYPE_SIZE

2024-06-02 Thread Kewen Lin
Joseph pointed out "floating types should have their mode, not a poorly defined precision value" in the discussion[1], as he and Richi suggested, the existing macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE will be replaced with a hook mode_for_floating_type. To be prepared for that, this patch is to repl

[PATCH 00/52] Replace {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE with new hook

2024-06-02 Thread Kewen Lin
Hi, Currently how we determine which mode will be used for a floating point type is that for a given type precision (size) call mode_for_size to get the first mode which has this size in the specified class. On Powerpc, we have three modes (TF/KF/IF) having the same mode precision 128 (see[1]), s

[PATCH 01/52] ada: Replace use of LONG_DOUBLE_TYPE_SIZE

2024-06-02 Thread Kewen Lin
Joseph pointed out "floating types should have their mode, not a poorly defined precision value" in the discussion[1], as he and Richi suggested, the existing macros {FLOAT,{,LONG_}DOUBLE}_TYPE_SIZE will be replaced with a hook mode_for_floating_type. To be prepared for that, this patch is to repl

Ping [PATCH-1v3, rs6000] Implement optab_isinf for SFDF and IEEE128

2024-06-02 Thread HAO CHEN GUI
Hi, Gently ping the series of patches. [PATCH-1v3, rs6000] Implement optab_isinf for SFDF and IEEE128 https://gcc.gnu.org/pipermail/gcc-patches/2024-May/652593.html [PATCH-2v3, rs6000] Implement optab_isfinite for SFDF and IEEE128 https://gcc.gnu.org/pipermail/gcc-patches/2024-May/652594.html [PA

Ping [PATCHv5] Optab: add isnormal_optab for __builtin_isnormal

2024-06-02 Thread HAO CHEN GUI
Hi, All issues were addressed. Gently ping it. https://gcc.gnu.org/pipermail/gcc-patches/2024-May/653001.html Thanks Gui Haochen 在 2024/5/29 14:36, HAO CHEN GUI 写道: > Hi, > This patch adds an optab for __builtin_isnormal. The normal check can be > implemented on rs6000 by a single instructio

Ping [PATCHv5] Optab: add isfinite_optab for __builtin_isfinite

2024-06-02 Thread HAO CHEN GUI
Hi, All issues were addressed. Gently ping it. https://gcc.gnu.org/pipermail/gcc-patches/2024-May/652991.html Thanks Gui Haochen 在 2024/5/29 14:36, HAO CHEN GUI 写道: > Hi, > This patch adds an optab for __builtin_isfinite. The finite check can be > implemented on rs6000 by a single instruction

RISC-V: Patches need to be backport to GCC-14

2024-06-02 Thread juzhe.zh...@rivai.ai
Hi, I saw Robin commit these following patches: https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=9781885a624f3e29634d95c14cd10940cefb1a5a https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=a2fd0812a54cf51520f15e900df4cfb5874b75ed I think they need to be backport to GCC-14. Any objections ? or can som

Re: [PATCH v3 1/8] [APX NF]: Support APX NF add

2024-06-02 Thread Hongtao Liu
On Wed, May 29, 2024 at 1:11 PM Kong, Lingling wrote: > > Hi, compared with v2, these patches restored the original lea patten position > and addressed hongtao's comment. > > APX NF(no flags) feature implements suppresses the update of status flags > for arithmetic operations. Ok for the patch an

Re: [PATCH v7 2/9] Fix pro_and_epilogue for sibcalls at -O0

2024-06-02 Thread Andi Kleen
> @@ -6557,7 +6558,7 @@ rest_of_handle_thread_prologue_and_epilogue > (function *fun) >  { >    /* prepare_shrink_wrap is sensitive to the block structure of the > control >       flow graph, so clean it up first.  */ > -  if (optimize) > +  if (cfun->tail_ca

Re: [PATCH v7 2/9] Fix pro_and_epilogue for sibcalls at -O0

2024-06-02 Thread Andrew Pinski
On Sun, Jun 2, 2024, 10:24 AM Andi Kleen wrote: > Some of the cfg fixups in pro_and_epilogue for sibcalls were dependent on > "optimize". > Make them check cfun->tail_call_marked instead to handle the -O0 musttail > case. This fixes the musttail test cases on arm targets. > > PR115255 > >

[PATCH v7 9/9] Add documentation for musttail attribute

2024-06-02 Thread Andi Kleen
gcc/ChangeLog: * doc/extend.texi: Document [[musttail]] --- gcc/doc/extend.texi | 23 +-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/gcc/doc/extend.texi b/gcc/doc/extend.texi index 799a36586dc9..1984e8c1beec 100644 --- a/gcc/doc/extend.texi +++ b/gc

[PATCH v7 5/9] C: Implement musttail attribute for returns

2024-06-02 Thread Andi Kleen
Implement a C23 clang compatible musttail attribute similar to the earlier C++ implementation in the C parser. PR83324 gcc/c/ChangeLog: * c-parser.cc (struct attr_state): Define with musttail_p. (c_parser_statement_after_labels): Handle [[musttail]] (c_parser_std_

[PATCH v7 8/9] Give better error messages for musttail

2024-06-02 Thread Andi Kleen
When musttail is set, make tree-tailcall to give error messages when it cannot handle a call. This avoids vague "other reasons" error messages later at expand time. This doesn't always work, for example when find_tail_call walking gives up because the control flow is too complicated then it won't

[PATCH v7 7/9] Enable musttail tail conversion even when not optimizing

2024-06-02 Thread Andi Kleen
Enable the tailcall optimization for non optimizing builds, but in this case only checks calls that have the musttail attribute set. This makes musttail work without optimization. This is done with a new late musttail pass that is only active when not optimizing. The pass must be after ehcleanup.

[PATCH v7 3/9] Add a musttail generic attribute to the c-attribs table

2024-06-02 Thread Andi Kleen
It does nothing currently since statement attributes are handled directly in the parser. gcc/c-family/ChangeLog: * c-attribs.cc (handle_musttail_attribute): Add. * c-common.h (handle_musttail_attribute): Add. --- gcc/c-family/c-attribs.cc | 15 +++ gcc/c-family/c-comm

[PATCH v7 2/9] Fix pro_and_epilogue for sibcalls at -O0

2024-06-02 Thread Andi Kleen
Some of the cfg fixups in pro_and_epilogue for sibcalls were dependent on "optimize". Make them check cfun->tail_call_marked instead to handle the -O0 musttail case. This fixes the musttail test cases on arm targets. PR115255 gcc/ChangeLog: * function.cc (thread_prologue_and_epi

[PATCH v7 6/9] Add tests for C/C++ musttail attributes

2024-06-02 Thread Andi Kleen
Mostly adopted from the existing C musttail plugin tests. gcc/testsuite/ChangeLog: * c-c++-common/musttail1.c: New test. * c-c++-common/musttail2.c: New test. * c-c++-common/musttail3.c: New test. * c-c++-common/musttail4.c: New test. * c-c++-common/musttai

[PATCH v7 4/9] C++: Support clang compatible [[musttail]] (PR83324)

2024-06-02 Thread Andi Kleen
This patch implements a clang compatible [[musttail]] attribute for returns. musttail is useful as an alternative to computed goto for interpreters. With computed goto the interpreter function usually ends up very big which causes problems with register allocation and other per function optimizati

Updated musttail patchkit

2024-06-02 Thread Andi Kleen
This version fixes C++ template propagation of musttail, avoids ICEs for ARM (and probably some other targets) generation of -O0 tail calls, and improves the error messages in tree-musttail again, as well as the documentation. I bootstrapped/tested it on x86_64-linux, and checked the musttail test

[PATCH v7 1/9] Improve must tail in RTL backend

2024-06-02 Thread Andi Kleen
- Give error messages for all causes of non sibling call generation - When giving error messages clear the musttail flag to avoid ICEs - Error out when tree-tailcall failed to mark a must-tail call sibcall. In this case it doesn't know the true reason and only gives a vague message. PR8332

Re: [PATCH 5/6] vect: Support multiple lane-reducing operations for loop reduction [PR114440]

2024-06-02 Thread Feng Xue OS
Please see my comments below. Thanks, Feng > On Thu, May 30, 2024 at 4:55 PM Feng Xue OS > wrote: >> >> For lane-reducing operation(dot-prod/widen-sum/sad) in loop reduction, >> current >> vectorizer could only handle the pattern if the reduction chain does not >> contain other operation, no m

[Patch, aarch64 1/1] Additional interface function implementation

2024-06-02 Thread Ajit Agarwal
Hello All: Common infrastructure using generic code for pair mem fusion of different targets. Implements additional interface virtual function implementation required for rs6000 target. Tested for aarch64-linux-gnu. Thanks & Regards Ajit aarch64: Additional interface function implementation C

Re: [Patch, rs6000, aarch64, middle-end] Add implementation for different targets for pair mem fusion

2024-06-02 Thread Ajit Agarwal
Hello Richard: On 31/05/24 3:23 pm, Richard Sandiford wrote: > Ajit Agarwal writes: >> Hello All: >> >> Common infrastructure using generic code for pair mem fusion of different >> targets. >> >> rs6000 target specific specific code implements virtual functions defined >> by generic code. >> >> C

[Patch, aarch64 1/2] aarch64: Additional interface function implementation

2024-06-02 Thread Ajit Agarwal
Hello All: Common infrastructure using generic code for pair mem fusion of different targets. Implements additional interface virtual function implementation required for rs6000 target. Tested for aarch64-linux-gnu. Thanks & Regards Ajit aarch64: Additional interface function implementation.

[Patch, rs6000, middle-end 0/1] Add implementation for different targets for pair mem fusion

2024-06-02 Thread Ajit Agarwal
Hello All: All comments are addressed and patch is split into rs6000 and aarch64 target changes. Common infrastructure using generic code for pair mem fusion of different targets. rs6000 target specific code implements virtual functions defined by generic code. Target specific code are added

Re: [PATCH v2] s390: Implement TARGET_NOCE_CONVERSION_PROFITABLE_P [PR109549]

2024-06-02 Thread Stefan Schulze Frielinghaus
Since the patch works fine so far for mainline, ok to backport to GCC 14? On Fri, May 17, 2024 at 08:59:05AM +0200, Stefan Schulze Frielinghaus wrote: > I've adapted the patch as follows and will push. > > Thanks, > Stefan > > -- > > Consider a NOCE conversion as profitable if there is at least

Re: [pushed] wwwdocs: mirrors: Remove gcc.fyxm.net

2024-06-02 Thread Gerald Pfeifer
On Sun, 2 Jun 2024, Gerald Pfeifer wrote: > The hostname gcc.fyxm.net no longer resolves. > > Jan, thank you for past services. Please advise if you'd like to restore > (or using a different address). Just for the record/archive: : host imaginarium.2600.sk[159.69.251.30] said: 554 5.7.1 :

[pushed] wwwdocs: mirrors: Remove gcc.fyxm.net

2024-06-02 Thread Gerald Pfeifer
The hostname gcc.fyxm.net no longer resolves. Jan, thank you for past services. Please advise if you'd like to restore (or using a different address). Gerald --- htdocs/mirrors.html | 1 - 1 file changed, 1 deletion(-) diff --git a/htdocs/mirrors.html b/htdocs/mirrors.html index b49aa76c..e9d1

  1   2   >