This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Global Reload Problem
- From: Gyle Yearsley <gyearsley at zilog dot com>
- To: "'gcc at gcc dot gnu dot org'" <gcc at gcc dot gnu dot org>
- Date: Mon, 31 Jan 2005 16:41:09 -0800
- Subject: Global Reload Problem
I am having a problem with the global reload. Below is a debugging dump from
the .lreg and .greg dumps for a particular insn. In the local reload insn
register 58 of the first operand is pseudo register which needs to be
reloaded. In the global reload insn register 58 has been replaced with a
stack slot. However the processor does not support a stack slot with an
offset, thus it causes the compiler to abort since it cannot match the insn.
What really needs to happen is register 58 needs to be reloaded as a hard
register and not a stack slot. How can I tell the compiler that this needs
to be a hard register? It appears that global reload does not check the
viability of this instruction since it passed global reload and fails later.
Any help would be appreciated.
After Local Reload
(set (reg:QI 63)
(plus:QI (mem/s:QI (plus:SI (reg:SI 58)
(symbol_ref:SI ("__clz_tab")))
(reg/v:QI 51))) 12 {addqi3}
After Global Reload
(set (reg:QI 1 r1)
(plus:QI (reg:QI 1 r1)
(mem/s:QI (plus:SI (mem:SI (plus:SI (reg/f:SI 31 q60)
(const_int -10))
(symbol_ref:SI ("__clz_tab")))
Thanks,
Gyle Yearsley
gyearsley@zilog.com