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]

Re: PATCH: Darwin / Mac OS X native support


Franz Sirl wrote:
> 
> The rs6000 directory was just cleaned from old-style includes recently, so
> this should read
> 
> > +     tm_file="${tm_file} darwin.h rs6000/darwin.h"
> 
> and the corresponding #include's removed from your header files.

Oh yeah - I did this for the host stuff, but forgot about the target
bits.

> config/darwin.h also seems to contain a lot of unnecessary #undef's, rs6000.h
> got cleaned up a lot from OS dependent defines since gcc-2.95, so you should
> be able to clean it up a bit. Feel free to suggest some macros for move from
> rs6000.h to the OS headers too, if you think they prevent cleanly structured
> darwin OS headers.

The #undefs are mostly paranoia; some of them are probably historical; the
original theory was that generic Dar^H^H^HNeXT definitions would be useful
for all architectures, but in practice many of them had to be overridden.

> On the other hand I don't think PREFERRED_RELOAD_CLASS belongs in an OS
> header...

Yes, that one is ugly, but forced by the workings of the Mach-O PIC
code, otherwise symbol loads try to use r0, with unfortunate consequences.
Nobody here knows of a more elegant solution.

> Overall the patch is looking good at a first glance, and unless Geoff and
> David have major concerns with it, I guess it can go into 3.0?

It would be very convenient to have it in 3.0, but the mainline would be
fine too.  I haven't tested the patched sources on LinuxPPC, wouldn't want
to cause any regressions on the branch...

> The
> FINALIZE_PIC stuff maybe controversial, I believe this hook is deprecated and
> no new targets should use it, so most probably you will have to find a
> different solution...

I didn't know it was deprecated.  Perhaps the manual should say something?

Stan


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