Nathan Froyd <froy...@codesourcery.com> writes:

> On Fri, Jun 04, 2010 at 07:45:20AM -0700, Ian Lance Taylor wrote:
>> Nathan Froyd <froy...@codesourcery.com> writes:
>> >    * config/i386/i386-protos.h (ix86_print_operand): Declare.
>> >    * config/i386/i386.c (ix86_print_operand): Make non-static.
>> >    * config/i386/sol2.h (ASM_OUTPUT_CALL): Call ix86_print_operand.
>> >    * rtl.h (output_operand): Declare.
>> >    * final.c (output_operand): Make non-static.
>> 
>> The changes in config/i386 are OK.
>> 
>> I don't understand the point of the changes to rtl.h and final.c.
>
> The changes to rtl.h and final.c are necessary because PRINT_OPERAND* on
> some platforms freely calls output_operand.  But now that PRINT_OPERAND*
> has been hookized, that call to output_operand no longer appears
> textually in final.c, but somewhere else (targhooks.c if the port has
> not done the conversion PRINT_OPERAND* -> TARGET_PRINT_OPERAND*,
> config/$PORT/$PORT.c if the port has), output_operand needs to be
> exported.

I get it.

> Looking at things a little more closely, output_address is exported in
> output.h.  I suppose output_operand should be exported there as well?

Yes, put the declaration there, by output_operand_lossage.

Thanks.

Ian

Reply via email to