This is the mail archive of the gcc@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: Defining special builtin functions for DFA/VLIW scheduling


On Tue, Sep 17, 2002 at 03:30:20PM +0100, Dan Towner wrote:
> This would then allow the builtin pattern to be VLIW'd, and when the
> pattern is converted into assembly language, the integer constant would
> be converted into the appropriate channel name in the assembly language
> output.

A machine-specific builtin function certainly is the way to go here.
But why in the world must the assembly language produce a _name_?
The thing surely resolves to an integer in the end anyway; why bother
with jumping through 3 hoops to get there?  Just define

	__builtin_put_channel(data, /*channel=*/ 0);

and let the 0 go from source all the way through to the instruction
image.

> To remove the need for the prepending I would need to pass the type
> infomation to gcc on the command line:
> 
>   gcc -mchannel="DanielsChannel,struct Complicated32BitStruct"

This you can't do from the back end, because you don't have access to
all the parsing bits from the front end.  It's also really ugly, IMO.


r~


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