This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Constant propagation and strength reduction


On Tuesday, January 21, 2003, at 10:22  AM, David Edelsohn wrote:
Roger Sayle writes:
Roger> The problem is that currently GCC doesn't perform any form of
Roger> constant propagation at the tree-level. The only transformations
Roger> performed by fold work on a single statement at a time.

Roger> The good news is that this should be fixed by the new SSA passes
Roger> once they come online.

Roger> I'll also look into fixing this at the simplify-rtx level. If
Roger> enough of the expand_divmod code is generic enough, we should be
Roger> re-use it, should CSE/GCSE or similar propagate a constant into
Roger> the division.

There already was a proposal to retry the divmod case later that
was rejected, mentioning that this will be fixed by Tree-SSA. I tend to
agree that duplicating the code is the wrong design.
That was mine I think; basically cprop_insn calls back into expand_divmod.
I can resubmit this patch if anyone's interested.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]