From: kelefth
`(A * B) + (-C) to (B - C/A) * A` fails to match on ILP32 targets due to
the upper bits of CST0 being zeros in some cases.
This patch adds the following pattern in match.pd:
(A + CST0) * CST1 -> (A + CST0') * CST1, where CST1 is a power of 2
constant and CST0' is CST0 with the log2
From: kelefth
During the initialization of the base register for the zero-offset store, in
the case that we are eliminating the load, we used a paradoxical subreg
assuming that we don't care about the higher bits of the register. This led to
writing wrong values when we were not updating the whol
From: kelefth
Avoid-store-forwarding doesn't handle the case where an instruction in the
store-load sequence contains a REG_EH_REGION note, leading to the insertion
of instructions after it, while it should be the last instruction in the
basic block. This causes an ICE when compiling using `-O -f
.html).
Thanks,
Konstantinos.
On Sat, Oct 26, 2024 at 5:54 PM Jeff Law wrote:
>
>
>
> On 10/23/24 8:27 AM, Konstantinos Eleftheriou wrote:
> > From: kelefth
> >
> > This pass detects cases of expensive store forwarding and tries to avoid
> > them
> >
Signed-off-by: Konstantinos Eleftheriou
Series-version: 8
Series-changes: 8
- Fix store_bit_field call for big-endian targets, where
BITS_BIG_ENDIAN is false.
- Handle store_forwarding_max_distance = 0 as a special case that
disables cost checks for avoid-store
0/18/24 3:57 AM, Konstantinos Eleftheriou wrote:
> > From: kelefth
> >
> > This pass detects cases of expensive store forwarding and tries to avoid
> > them
> > by reordering the stores and using suitable bit insertion sequences.
> > For example it can
-store-forwarding-3.c: New test.
* gcc.target/aarch64/avoid-store-forwarding-4.c: New test (XFAIL).
* gcc.target/aarch64/avoid-store-forwarding-5.c: New test (XFAIL).
Signed-off-by: Philipp Tomsich
Signed-off-by: Konstantinos Eleftheriou
Series-version: 7
Series-changes: 7
-store-forwarding-3.c: New test.
* gcc.target/aarch64/avoid-store-forwarding-4.c: New test (XFAIL).
* gcc.target/aarch64/avoid-store-forwarding-5.c: New test (XFAIL).
Signed-off-by: Philipp Tomsich
Signed-off-by: Konstantinos Eleftheriou
Series-version: 6
Series-changes: 6
Sent a new version for this in
https://gcc.gnu.org/pipermail/gcc-patches/2024-October/665794.html.
Thanks,
Konstantinos.
On Fri, Aug 30, 2024 at 4:32 PM Richard Sandiford
wrote:
>
> Manolis Tsamis writes:
> >> > I could have some help with that, because after the new changes a
> >> > subreg rel
-xor-and-or.c: New test.
* gcc.dg/tree-ssa/fold-xor-or.c: New test.
Tested-by: Christoph Müllner
Signed-off-by: Philipp Tomsich
Signed-off-by: Konstantinos Eleftheriou
---
gcc/match.pd | 32 ++-
.../gcc.dg/tree-ssa/fold-xor-and
I have sent a new version
(https://gcc.gnu.org/pipermail/gcc-patches/2024-September/663350.html).
I also added :c to the ne operations.
Thanks,
Konstantinos
On Wed, Sep 18, 2024 at 1:52 PM Richard Biener
wrote:
>
> On Wed, Sep 18, 2024 at 10:42 AM Konstantinos Eleftheriou
> wrote:
&
fold-xor-and-or.c: New test.
> > * gcc.dg/tree-ssa/fold-xor-or.c: New test.
> >
> > Reviewed-by: Christoph Müllner
> > Signed-off-by: Philipp Tomsich
> > Signed-off-by: Konstantinos Eleftheriou
> > ---
> > gcc/match.pd
regression tested on x86-64 and
> aarch64.
> >
> > PR tree-optimization/109393
> >
> > gcc/ChangeLog:
> >
> > * match.pd: (A * B) + (-C) -> (B - C/A) * A, if C a multiple of
> A.
> >
> > gcc/testsuite/ChangeLog:
> >
.
gcc/testsuite/ChangeLog:
* gcc.dg/pr109393.c: New test.
Tested-by: Christoph Müllner
Signed-off-by: Philipp Tomsich
Signed-off-by: Konstantinos Eleftheriou
---
gcc/match.pd| 21 -
gcc/testsuite/gcc.dg/pr109393.c | 23 +++
2 files c
.
gcc/testsuite/ChangeLog:
* gcc.dg/pr109393.c: New test.
Tested-by: Christoph Müllner
Signed-off-by: Philipp Tomsich
Signed-off-by: Konstantinos Eleftheriou
---
gcc/match.pd| 15 ++-
gcc/testsuite/gcc.dg/pr109393.c | 23 +++
2 files chang
024 at 4:24 PM Konstantinos Eleftheriou
> wrote:
> >
> > From: kelefth
> >
> > In expressions like (a != b || ((a ^ b) & CST0) == CST1) and
> > (a != b || (a ^ b) == CST), (a ^ b) is folded to false.
> > In the equivalent expressions (((a ^ b) & CST0)
and-or.c: New test.
* gcc.dg/tree-ssa/fold-xor-or.c: New test.
Reviewed-by: Christoph Müllner
Signed-off-by: Philipp Tomsich
Signed-off-by: Konstantinos Eleftheriou
---
gcc/match.pd | 30 ++
.../gcc.dg/tree-ssa/fold-xor-and
Thanks, fixed (
https://gcc.gnu.org/pipermail/gcc-patches/2024-August/660631.html).
On Thu, Aug 15, 2024 at 3:57 PM Sam James wrote:
> Konstantinos Eleftheriou writes:
>
> > From: kelefth
> >
> > In expressions like (a != b || ((a ^ b) & CST0) == CST1) and
> &
estsuite/ChangeLog:
* gcc.dg/tree-ssa/fold-xor-and-or-1.c: New test.
* gcc.dg/tree-ssa/fold-xor-and-or-2.c: New test.
* gcc.dg/tree-ssa/fold-xor-or-1.c: New test.
* gcc.dg/tree-ssa/fold-xor-or-2.c: New test.
Reviewed-by: Christoph Müllner
Signed-off-by: Philipp Tomsich
Signed-of
estsuite/ChangeLog:
* gcc.dg/tree-ssa/fold-xor-and-or-1.c: New test.
* gcc.dg/tree-ssa/fold-xor-and-or-2.c: New test.
* gcc.dg/tree-ssa/fold-xor-or-1.c: New test.
* gcc.dg/tree-ssa/fold-xor-or-2.c: New test.
Reviewed-by: Christoph Müllner
Signed-off-by: Philipp Tomsich
Signed-of
20 matches
Mail list logo