This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: get_attr_* speedups
- To: Jan Hubicka <jh at suse dot cz>
- Subject: Re: get_attr_* speedups
- From: Richard Henderson <rth at cygnus dot com>
- Date: Mon, 28 Aug 2000 14:11:46 -0700
- Cc: gcc-patches at gcc dot gnu dot org, patches at x86-64 dot org
- References: <20000828013742.A1077@atrey.karlin.mff.cuni.cz>
On Mon, Aug 28, 2000 at 01:37:42AM +0200, Jan Hubicka wrote:
> + /* Wrappers around recog, split, peephole2 functions from insn-recog.c that
> + does dirty work. These functions just clear the recog_data cache. */
> + int
> + recog (x0, insn, pnum_clobbers)
> + rtx x0, insn;
> + int *pnum_clobbers;
> + {
> + recog_data.insn = NULL;
> + which_alternative = -1;
> + return recog_1 (x0, insn, pnum_clobbers);
> + }
I think you should just emit this code into the regular recog, etc.
> + void
> + extract_constrain_insn_cached (insn)
> + rtx insn;
> + {
> + extract_insn_cached (insn);
> + if (!constrain_operands (reload_completed))
> + fatal_insn_not_found (insn);
> + }
> +
[...]
> + /* In the caching mode don't recalculate when not required. */
> + if (which_alternative != -1
> + && recog_data.insn)
> + return 1;
> +
I don't like splitting this into constrain_operands. Is there any
reason not to have the -1 test in extract_constrain_insn_cached?
r~