This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch, avr-tiny]: Fix handling of constant addresses.

2015-02-25 18:56 GMT+03:00 Georg-Johann Lay <>:
> The current avr-gcc ICEs in avr.c::tiny_valid_direct_memory_access_range
> because XEXP (op, 0) is used on op which are not MEM_P (e.g. REG or SUBREG).
> If op is MEM_P then INTVAL might be used for on RTXes which are not
> Anyway, using such functions in insn conditions is not the right approach to
> get valid addresses.  The right place is targetm.legitimate_address_p.
> Taking away move insns from reload by means of such conditions is not
> robust; reload knows how to make addresses legitimate if told so...
> Ok for trunk?
> Johann
>         PR target/65192
>         * config/avr/avr.c (tiny_valid_direct_memory_access_range): Remove.
>         (avr_legitimate_address_p) <AVR_TINY, CONSTANT_ADDRESS_P>:
>         Refuse any constant address not in 0..0xbf.
>         * config/avr/avr-protos.h: Same.
>         * config/avr/ (*mov<mode>, *movsf): Remove
>         tiny_valid_direct_memory_access_range from insn conditions.
>         (mov<mode>): Don't special-case expansion of avrtiny addresses.

Please apply.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]