Re: [PATCH] [RISC-V] Tune for removal unnecessary sext in builtin overflows [PR108016]

2025-04-18 Thread Alexey Merzlyakov
On Fri, Apr 18, 2025 at 06:47:51AM -0600, Jeff Law wrote: > Thanks. I've pushed this to the trunk. I know there's an additional patch > in this space. It'll take some time to get to as we work through the queue > of pending stuff. > > jeff Thank you for taking care of it. Yeah, there is no sen

[PATCH] Fix for compile-time hang in ext-dce [PR119099]

2025-03-07 Thread Alexey Merzlyakov
ext-dce + df-core could be treated as finite-state machine, whose states acting on livenow and livein bitmaps. In some situations, it can loop forever flipping/flopping or widening/narrowing livein states with livenow. Dataflow solver algorithm will never come to the null-worklists in this case. Th

Re: [PATCH] [RISC-V] Tune for removal unnecessary sext in builtin overflows [PR108016]

2025-02-16 Thread Alexey Merzlyakov
On Sat, Feb 15, 2025 at 08:39:44AM -0700, Jeff Law wrote: > > Looks pretty good. While it fixes a bug, we're actually in stage4 of the > development cycle. So with some exceptions we require the bug to be a > regression relative to earlier releases. > > We tend to make exceptions for cases wher

[PATCH] [RISC-V] Tune for removal unnecessary sext in builtin overflows [PR108016]

2025-02-14 Thread Alexey Merzlyakov
her pipeline. gcc/ChangeLog: * config/riscv/riscv.md (addv4, uaddv4, subv4, usubv4): Tunes for unnecessary sext.w elimination. gcc/testsuite/ChangeLog: * gcc.target/riscv/pr108016.c: New test. Signed-off-by: Alexey Merzlyakov --- gcc/config/riscv/riscv

[PATCH v3] zero_extend(not) -> xor optimization [PR112398]

2024-11-28 Thread Alexey Merzlyakov
tsuite/ChangeLog: * gcc.target/riscv/pr112398.c: New test. * gcc.dg/torture/pr117476-1.c: New test. From Zhendong Su. * gcc.dg/torture/pr117476-2.c: New test. From Zdenek Sojka. Signed-off-by: Alexey Merzlyakov --- gcc/simplify-rtx.cc | 23

Re: [PATCH] Fix incorrect subreg mode check [PR117476]

2024-11-12 Thread Alexey Merzlyakov
* simplify-rtx.cc (simplify_context::simplify_unary_operation_1): Fix subreg mode check during zero_extend(not) -> xor optimization. gcc/testsuite/ChangeLog: * gcc.dg/torture/pr117476.c: New test. From Zhendong Su. Signed-off-by: Alexey Merzlyakov --- gcc/simplify-rtx.cc

Re: [PATCH] Fix incorrect subreg mode check [PR117476]

2024-11-12 Thread Alexey Merzlyakov
mization. gcc/testsuite/ChangeLog: * gcc.c-torture/execute/pr117476.c: New test. From Zhendong Su. Signed-off-by: Alexey Merzlyakov --- gcc/simplify-rtx.cc| 2 +- gcc/testsuite/gcc.c-torture/execute/pr117476.c | 10 ++ 2 files changed, 11 insertions(+

Re: [PATCH] Fix incorrect subreg mode check [PR117476]

2024-11-12 Thread Alexey Merzlyakov
gcc.dg/pr117476.c: New test. From Zhendong Su. Signed-off-by: Alexey Merzlyakov --- gcc/simplify-rtx.cc | 2 +- gcc/testsuite/gcc.dg/pr117476.c | 12 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 gcc/testsuite/gcc.dg/pr117476.c diff --git a/gcc/si

[PATCH] Fix incorrect subreg mode check [PR117476]

2024-11-11 Thread Alexey Merzlyakov
gcc/ChangeLog: * simplify-rtx.cc (simplify_context::simplify_unary_operation_1): Fix subreg mode check during zero_extend(not) -> xor optimization. gcc/testsuite/ChangeLog: * gcc.dg/pr117476.c: New test. Signed-off-by: Alexey Merzlyakov --- gcc/simplify-rtx

[PATCH v2] RISC-V: zero_extend(not) -> xor optimization [PR112398]

2024-11-06 Thread Alexey Merzlyakov
ost common) and for RV-64 and MIPS-32 targets (as having an effect from this optimization): no regressions for all cases. gcc/ChangeLog: * simplify-rtx.cc (simplify_context::simplify_unary_operation_1): Simplify ZERO_EXTEND (SUBREG (NOT X)) to XOR (X, GET_MODE_MASK(SUBREG)) whe

[PATCH] RISC-V: zero_extend(not) -> xor optimization [PR112398]

2024-11-02 Thread Alexey Merzlyakov
X)) to XOR (X, 0xff...f) when X     doesn't have any non-zero bits outside of SUBREG mode. gcc/testsuite/ChangeLog:     * gcc.target/riscv/pr112398.c: New test. Signed-off-by: Alexey Merzlyakov ---  gcc/simplify-rtx.cc   | 23 +++  gcc/testsuite/

Re: [PATCH] Regression fix for PR target/61223

2014-05-22 Thread Alexey Merzlyakov
On 20.05.2014 20:24, Ramana Radhakrishnan wrote: For now, please revert your original patch and one of Richard or me will try to look at it in the morning. The thumb1 case is slightly more complicated than this. I don't like this approach as you are introducing the problem again in ARM state

Re: [PATCH] [PING^2] Fix for PR libstdc++/60758

2014-05-20 Thread Alexey Merzlyakov
On 20.05.2014 17:16, Richard Earnshaw wrote: On 20/05/14 14:12, Ramana Radhakrishnan wrote: The following PR is opened for this problem: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61223 Thumb1 failure was also detected and reported in pr60758. I've proposed a thumb1 bugfix there. Regtest for

[PATCH] Regression fix for PR target/61223

2014-05-20 Thread Alexey Merzlyakov
Alexey Merzlyakov PR target/61223 * libsupc++/eh_arm.cc (__cxa_end_cleanup): Revert backtracing support on thumb1. diff --git a/libstdc++-v3/libsupc++/eh_arm.cc b/libstdc++-v3/libsupc++/eh_arm.cc index 6a45af5..8ad327d 100644 --- a/libstdc++-v3/libsupc++/eh_arm.cc +++ b/libstdc++-v3/libsupc

Re: [PATCH] [PING^2] Fix for PR libstdc++/60758

2014-05-20 Thread Alexey Merzlyakov
On 20.05.2014 16:25, Richard Earnshaw wrote: On 16/05/14 14:56, Alexey Merzlyakov wrote: On 07.05.2014 13:28, Ramana Radhakrishnan wrote: On 05/07/14 09:19, Yury Gribov wrote: Original Message Subject: [PING] [PATCH] Fix for PR libstdc++/60758 Date: Thu, 17 Apr 2014 17:48

Re: [PATCH] [PING^2] Fix for PR libstdc++/60758

2014-05-16 Thread Alexey Merzlyakov
On 07.05.2014 13:28, Ramana Radhakrishnan wrote: On 05/07/14 09:19, Yury Gribov wrote: Original Message Subject: [PING] [PATCH] Fix for PR libstdc++/60758 Date: Thu, 17 Apr 2014 17:48:12 +0400 From: Alexey Merzlyakov To: Ramana Radhakrishnan CC: gcc-patches@gcc.gnu.org

[PING] [PATCH] Fix for PR libstdc++/60758

2014-04-17 Thread Alexey Merzlyakov
Hi, This fixes infinite backtrace in __cxa_end_cleanup(). Regtest was finished with no regressions on arm-linux-gnueabi(sf). The patch posted at: http://gcc.gnu.org/ml/gcc-patches/2014-04/msg00496.html Thanks in advance. Best regards, Merzlyakov Alexey

Re: [PATCH] Fix for PR libstdc++/60758

2014-04-10 Thread Alexey Merzlyakov
On 09.04.2014 15:12, Ramana Radhakrishnan wrote: On 04/09/14 09:07, Alexey Merzlyakov wrote: On 04.04.2014 14:44, Alexey Merzlyakov wrote: Hi all, Here is a patch, that fixes infinite backtraces in __cxa_end_cleanup(). The Bugzilla entry for this:http://gcc.gnu.org/bugzilla/show_bug.cgi?id

Re: [PATCH] Fix for PR libstdc++/60758

2014-04-09 Thread Alexey Merzlyakov
On 04.04.2014 14:44, Alexey Merzlyakov wrote: Hi all, Here is a patch, that fixes infinite backtraces in __cxa_end_cleanup(). The Bugzilla entry for this:http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60758 The __cxa_end_cleanup() does not save/restore LR in function header/footer and does not

[PATCH] Fix for PR libstdc++/60758

2014-04-04 Thread Alexey Merzlyakov
with GDB and other tools (e.g. unwind code in libgcc, libbacktrace, etc.). Best regards, Merzlyakov Alexey 2014-04-03 Alexey Merzlyakov PR libstdc++/60758 * libsupc++/eh_arm.cc (__cxa_end_cleanup): Add LR save/restore. diff --git a/libstdc++-v3/libsupc++/eh_arm.cc b/libstdc