Message ID | 20140328185445.GA8945@mail.duskware.de |
---|---|
State | New |
Headers | show |
Martin Husemann <martin@duskware.de> writes: > In the mips--netbsdelf target gcc 4.9 lost the pre-definition of > __mips_o32, which is heavily used in NetBSD sources. > > The obvious trivial patch adds it back. Are you sure it was ever in FSF GCC? I went through every revision of netbsd.h in git and couldn't see it. I can go ahead and apply the patch anyway if it's the right thing to do. Just wanted to make sure I wasn't missing something. Thanks, Richard
On Mon, Mar 31, 2014 at 08:35:30PM +0100, Richard Sandiford wrote: > Are you sure it was ever in FSF GCC? I went through every revision > of netbsd.h in git and couldn't see it. No, I'm not - guess I never tried a pure gcc on mips. > I can go ahead and apply the patch anyway if it's the right thing to do. > Just wanted to make sure I wasn't missing something. Matt Thomas should be the authority on this. This was one of the very few changes I needed so far for NetBSD/playstation2 (the others all in bugzilla already). Matt? Martin
Martin Husemann <martin@duskware.de> writes: > On Mon, Mar 31, 2014 at 08:35:30PM +0100, Richard Sandiford wrote: >> Are you sure it was ever in FSF GCC? I went through every revision >> of netbsd.h in git and couldn't see it. > > No, I'm not - guess I never tried a pure gcc on mips. > >> I can go ahead and apply the patch anyway if it's the right thing to do. >> Just wanted to make sure I wasn't missing something. > > Matt Thomas should be the authority on this. This was one of the very > few changes I needed so far for NetBSD/playstation2 (the others all in > bugzilla already). OK, in that case I went ahead and applied it. Thanks for the patch. Richard
--- gcc/config/mips/netbsd.h.orig 2014-01-02 23:23:26.000000000 +0100 +++ gcc/config/mips/netbsd.h 2014-03-28 14:19:18.000000000 +0100 @@ -32,7 +32,9 @@ along with GCC; see the file COPYING3. if (TARGET_ABICALLS) \ builtin_define ("__ABICALLS__"); \ \ - if (mips_abi == ABI_EABI) \ + if (mips_abi == ABI_32) \ + builtin_define ("__mips_o32"); \ + else if (mips_abi == ABI_EABI) \ builtin_define ("__mips_eabi"); \ else if (mips_abi == ABI_N32) \ builtin_define ("__mips_n32"); \