Subject: Re: CVS commit: src/sys
To: David Laight <david@l8s.co.uk>
From: Jeff Rizzo <riz@NetBSD.org>
List: source-changes
Date: 02/03/2006 17:15:19
This is an OpenPGP/MIME signed message (RFC 2440 and 3156)
--------------enig246A74B672411BA06088DEAC
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

David Laight wrote:
> On Thu, Feb 02, 2006 at 08:16:53AM -0800, Jeff Rizzo wrote:
>  =20
>> David-
>>
>> I'm not certain this is the specific commit that caused it, but amd64
>> kernels which are not optimized (like, say, GENERIC) fail to link due =
to
>> looking for bswap16 and bswap32.  I looked things over, but am not sur=
e
>> of the correct way to fix this...
>>    =20
>
> I'm not sure where I changed the effect of building non-optimised kerne=
ls.
> I'm fairly sure the const-folding and __inline versions were both insid=
e
> #if __OPTIMISE__. I don't think it makes any sense for it to be otherwi=
se.
>
> libkern (or somewhere) may need to contain extern defns of bswapnn()
> anyway - for cases where the #define doesn't apply (do we allow the
> address of bswapnn() to be taken?)
>
> It is also worth noting that the libc functions are __bswap16(), __bswa=
p32()
> and bswap64() on i386 and amd64, whereas the kernel ones never have the=

> the leading underscores.
>
> I'll look at what happens to unoptimised code later.
>
> 	David
>
>  =20

OK, I've discovered the source of this - I had COPTS+=3D-pipe and
CFLAGS+=3D-pipe in my /etc/mk.conf .  Without these, GENERIC builds at th=
e
default -O2 level, and consequently links.  This at least explains why
nobody else saw GENERIC fail to build.

+j



--------------enig246A74B672411BA06088DEAC
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iQCVAwUBQ+QAOLOuUtxCgar5AQON4QQAs1t6vCIDDRuWyh+9Olaqat6zNGBEWRv9
Lh0B0ZZw4zUdsf8+nc8Y4fRmX6bqR9FBs6ovUhJjw2vv/q6xDMsS64xvEqRNnOWq
Ji6rQ50u5rvhBg4Zfr17gAdAhMwO0C+pRTblW0bLg/2wDZeW2zNNbIT0Ddfuh1r0
UODXpBeWUYA=
=KLyH
-----END PGP SIGNATURE-----

--------------enig246A74B672411BA06088DEAC--