This is the mail archive of the gcc-patches@gcc.gnu.org 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: [PING] Target hook for rewriting inline asm constraints


> Sorry if this has already been suggested, but why not just replace
> hard-coded uses of 'm' in constraint-handling code with uses of some
> target macro?  You could then treat your current 'm' as an ordinary
> define_memory_constraint.

I'm not sure this would work.  I think reload relies on the
relationship between the 'm' constraint and GO_IF_LEGITIMATE_ADDRESS.
There is an early loop invoking find_reloads_address.  This reloads
all addresses which aren't supported by the target at all i.e. all
addresses for which GO_IF_LEGITIMATE_ADDRESS is false (or does not
jump to the given label).  If reload later on sees an 'm' constraint
it considers the address already been fixed by that early loop.  So I
would expect that in order to make such a hook work I would have to
mess around with the reload logic which is not preferable I think.

Bye,

-Andreas-


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