This is the mail archive of the
mailing list for the GCC project.
Re: [2/5] C-SKY port: Backend implementation
- From: Sandra Loosemore <sandra at codesourcery dot com>
- To: Jeff Law <law at redhat dot com>, 瞿仙淼 <xianmiao_qu at c-sky dot com>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, Yunhai Shang <yunhai_shang at c-sky dot com>
- Date: Fri, 3 Aug 2018 10:26:38 -0600
- Subject: Re: [2/5] C-SKY port: Backend implementation
- References: <firstname.lastname@example.org> <email@example.com> <firstname.lastname@example.org> <email@example.com> <firstname.lastname@example.org> <56004587-F43E-4004-B618-B819CF7A5E4A@c-sky.com> <email@example.com>
On 08/02/2018 04:27 PM, Jeff Law wrote:
I think the cse_cc pass is really just working around one or more bugs
in CSE and/or a backend bug. The RTL above clearly shows a common
subexpression that is not eliminated by CSE.
What CSE should be trying to do is changing the second and third
occurrences of (gt:CC (reg 77) (reg 78)) with (reg 33) which would
create nop-sets which would be subsequently deleted. I suspect you do
not have an insn which matches that nop set of the CC register. If you
fix that I suspect CSE will work better and eliminate the need for your
Thanks for the tip about that! I hacked things up to do as you suggest
and it appears to work. I'll post a new patch set once I've had time
for more testing, probably Monday-ish.