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: RFC: Putting target-dependent global state into switchable structures


On Sat, Jun 26, 2010 at 10:02 PM, Mark Mitchell <mark@codesourcery.com> wrote:
> Richard Sandiford wrote:
>
>> I've got a series of patches that speed up the switching process by
>> avoiding target_reinit. ?Rather than spam the list with the entire
>> series now, I thought I'd better ask for feedback on the general approach.
>
> I think this is entirely sensible. ?It's a step towards a more modular
> compiler, and we all know that we need that. ?I'll be happy to help
> review the patches as necessary once you're ready.

Well.  I don't like the idea of using .def files and a generator program.
In fact we are happily using no .def files for target hooks.

So why not have a target-independent piece of the structure definition
and a target macro implementing a target specific piece in it.  Thus,
sth like

  struct globals {
     ...
     TARGET_GLOBALS;
  };

and targets can define that if they need target specific globals.

Using .def files is over-engineering here IMHO and I do not see any
advantage in using it.

Richard.

> Thanks,
>
> --
> Mark Mitchell
> CodeSourcery
> mark@codesourcery.com
> (650) 331-3385 x713
>


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