IRA is not looking into the predicates ?

Jeff Law law@redhat.com
Fri Oct 30 18:31:00 GMT 2009


On 10/30/09 07:13, Mohamed Shafi wrote:
> Hi,
>
> I am doing a port for a 32bit target in GCC 4.4.0. The target does not
> have support for symbolic address in QImode for load operations.
You'll need to make sure to reject such addresses for QImode in 
GO_IF_LEGITIMATE_ADDRESS.


>   In
> order to do this what i have done is in define_expand for moveqi
> reject symbolic address it they come in source operands and i have
> also written a predicate for *moveqi_internal to reject such cases.
>    
OK.  Nothing wrong with these steps.  Though you really need to make 
sure GO_IF_LEGITIMATE_ADDRESS is defined correctly.

IRA doesn't look at operand predicates or insn conditions.  It assumes 
that any insns are valid assuming any pseudo registers appearing in the 
insn get suitable hard registers.

Based on the dumps you provided it appears that reg61 does not get a 
hard register and reload is generating the problematical insn #24.  This 
is a good indication that your GO_IF_LEGITIMATE_ADDRESS is incorrectly 
implemented.


jeff



More information about the Gcc mailing list