This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/16563] The compiler doesnt the necessary push/restore of r18/r19
- From: "denisc at overta dot ru" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 31 Aug 2004 18:35:18 -0000
- Subject: [Bug target/16563] The compiler doesnt the necessary push/restore of r18/r19
- References: <20040715103001.16563.baphomed@lycos.de>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From denisc at overta dot ru 2004-08-31 18:35 -------
I have analyzed this bug and founded that it's not a target bug.
It's a bug in regrename.c
regrename.c have a wrong tracking of call-clobbered registers.
avr have defined r2, ... r16,r17 as call-saved and r18,r19,... as call-clobbered.
Register allocator (greg) produce right code and copy 'd' to r10,r11,r12,r13.
Register renaming (rnreg) produce a wrong code. Rnreg remove copy insn because
it have a wrong tracking of register r16 in SImode through call_insn's.
regrename.c use the `kill_value_regno' to remove information about all
call-clobbered registers from `value_data' structure, but `kill_value_regno'
can't remove all information
about r16 in SImode (r16,r17,r18,r19) because call-clobbered registers only r18,
r19, ...
In example:
We have a link from r10 to r16 in SImode (for avr port SImoode use r16,r17,r18,r19)
call to `kill_value_regno (18, vd)' do nothing because r18 havn't any link. (r16
have. Not r18 nor r17,r19). I think that it's wrong.
I don't know a right place for fixing code.
`fix_value' probably have a code which can be used as a part for fix.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2004-08-31 18:35:16
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16563