This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: regclass.c: scan_one_insn special casing
- From: Eric Christopher <echristo at redhat dot com>
- To: Richard Kenner <kenner at vlsi1 dot ultra dot nyu dot edu>
- Cc: gcc at gcc dot gnu dot org
- Date: Sat, 27 Mar 2004 14:04:28 -0800
- Subject: Re: regclass.c: scan_one_insn special casing
- References: <10403272200.AA21873@vlsi1.ultra.nyu.edu>
> For those very few cases that are machine-specific.
>
There are tons of things that go through define_split now. You should
look at a few ports as examples:
[echristo@dzur sh]$ grep define_insn sh.md | wc -l
413
[echristo@dzur sh]$ grep define_split sh.md | wc -l
56
[echristo@dzur mips]$ grep define_split mips.md | wc -l
60
[echristo@dzur mips]$ grep define_insn mips.md | wc -l
366
> There's just something wrong with special casing all over the compiler
> just for a small case that could/should be handled somewhere else.
>
> But I feel that this case should be handled right where ti is and that's
> the best place to put it.
>
I know, you put it in there in 92. I won't ask why - I don't even want
to try to think of things I did 11 years ago :)
> How is it better to put this in a define_split in each port?
So that you aren't penalizing every call to scan_one_insn with this code
that is almost never called. (I'll say almost never even though I've not
tripped it with 4 ports and all of check-gcc). It also hurts
maintainability - scatter 100 or so of these cases through the compiler
and it looks like spaghetti.
-eric
--
Eric Christopher <echristo@redhat.com>