This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH] Implement (a & B) OP0 (c & B) into (a OP0 c) & B simplifying into forwprop
- From: Richard Guenther <richard dot guenther at gmail dot com>
- To: Andrew Pinski <pinskia at gmail dot com>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 23 Apr 2012 11:39:24 +0200
- Subject: Re: [PATCH] Implement (a & B) OP0 (c & B) into (a OP0 c) & B simplifying into forwprop
- References: <CA+=Sn1kE1kn3emRseJ=E4ftT02WvpgSkopoJSjAL0Tg9zZx=aQ@mail.gmail.com>
On Sat, Apr 21, 2012 at 4:26 AM, Andrew Pinski <email@example.com> wrote:
> ?I noticed a missed simple optimization on the tree level where the
> and expression could be commoned out.
> This patch implements the optimization in tree-ssa-forwprop.c. ? I
> thought it would be good to get it in even before my tree combiner
> work gets in (which I am still working on but recently ran into a git
> merging issue which I am still trying to resolve).
> OK? ?Bootstrapped and tested on x86_64-linux-gnu with no regressions.
> * tree-ssa-forwprop.c (simplify_bitwise_binary): Simplify (A & B) OP0
> (C & B) to (A OP0) & B.
> * gcc.dg/tree-ssa/forwprop-17.c: New testcase.