r275242 - in /trunk/gcc: ChangeLog config/or1k/...
shorne@gcc.gnu.org
shorne@gcc.gnu.org
Sat Aug 31 06:00:00 GMT 2019
Author: shorne
Date: Sat Aug 31 06:00:56 2019
New Revision: 275242
URL: https://gcc.gnu.org/viewcvs?rev=275242&root=gcc&view=rev
Log:
or1k: Fix issue with set_got clobbering LR (r9)
When compiling glibc we found that the GOT register was being allocated
r9 when the instruction was still set_got_tmp. That is a problem
because r9 is the Link Register (LR) in OpenRISC which is used/clobbered
in set_got. We cannot use r9 as the GOT register. Also, we cannot
simply say set_got_tmp clobbers r9 as this is the reason for having the
temporary set_got_tmp.
Fix by using a register class constraint that does not allow r9 during
register allocation.
gcc/ChangeLog:
* config/or1k/constraints.md (t): New constraint.
* config/or1k/or1k.h (GOT_REGS): New register class.
* config/or1k/or1k.md (set_got_tmp, set_got): Use t contraint.
Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/or1k/constraints.md
trunk/gcc/config/or1k/or1k.h
trunk/gcc/config/or1k/or1k.md
More information about the Gcc-cvs
mailing list