[autovect] [patch] Extend dse

Revital1 Eres ERES@il.ibm.com
Mon Mar 19 16:34:00 GMT 2007


Hello,

This patch enhance dse pass to delete dead stores when the previous
implementation failed due to alias uncertainty.  For example:

S[5].x = 0;
S[5].y = 0;

S[5].x = x;
S[5].y = y;

Previously S[5].y = 0; failed to be eliminated.  This patch fixes this
problem by walking the virtual def-use chain to find the stmt that
uses S[5].y.

Bootstrap and tested on PPC. OK for autovect branch?

Thanks,
Revital

2007-03-19  Revital Eres  <eres@il.ibm.com>

        * tree-ssa-dse.c (get_use_of_stmt_lhs): New function
          which walks virtual def-use chains to find redundant stores.
          (dse_optimize_stmt): Call it.
        * testsuite/gcc.dg/store_dse_test.c: New test.
        * testsuite/gcc.dg/dse_test.c: New test.

(See attached file: dse_patch_19_3.txt)(See attached file:
store_dse_test.txt)(See attached file: dse_test.txt)
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: dse_patch_19_3.txt
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20070319/c84d17ed/attachment.txt>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: store_dse_test.txt
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20070319/c84d17ed/attachment-0001.txt>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: dse_test.txt
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20070319/c84d17ed/attachment-0002.txt>


More information about the Gcc-patches mailing list