Just what are rtx costs?
David Edelsohn
dje.gcc@gmail.com
Mon Aug 22 15:53:00 GMT 2011
On Mon, Aug 22, 2011 at 9:08 AM, Joern Rennecke <amylaar@spamcop.net> wrote:
> Quoting Richard Guenther <richard.guenther@gmail.com>:
>
>>> So are you saying that we should remove the recursive nature of the
>>> rtx_cost/targetm.rtx_costs interface, and have the backend handle any
>>> recursion itself? I.e. targetm.rtx_costs only ever sees a complete
>>> (but perhaps invalid) instruction pattern? Or would you still keep
>>> the current recursion?
>>
>> I would say yes to that - kill the recursion.
>
> But the recursion is already optional. If you don't want to use recursion
> for your port, just make the rtx_costs hook return true.
> There is no need to break ports that are OK to use the recursion in
> rtlanal.c
> partially or in whole.
Exactly. I don't understand the disagreement about recursion. For
instance, the rs6000 port explicitly returns true or false for
rtx_costs as necessary for its computation. If a port wants to
compute rtx_costs without recursion, it already has that control.
Thanks, David
More information about the Gcc
mailing list