This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Patch to support mark_constant_function marking pure functions
- To: John Wehle <john at feith dot com>
- Subject: Re: Patch to support mark_constant_function marking pure functions
- From: Richard Henderson <rth at redhat dot com>
- Date: Fri, 21 Sep 2001 15:25:52 -0700
- Cc: gcc-patches at gcc dot gnu dot org
- References: <200108201955.PAA00895@jwlab.FEITH.COM>
On Mon, Aug 20, 2001 at 03:55:26PM -0400, John Wehle wrote:
> * alias.c: (nonlocal_mentioned_p): Don't
> bother checking non-constant calls.
> (nonlocal_referenced_p): New function.
> (nonlocal_set_p): Likewise.
> (mark_constant_function): Recognize pure functions.
> * rtl.h (global_reg_mentioned_p): New prototype.
> * rtlanal.c (global_reg_mentioned_p): New function.
I'd rather these routines be rewritten to use note_stores
and/or for_each_rtx, but the concept is sound.
r~