Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 27 Feb 2009 14:11:55 +0100
From:      Ed Schouten <ed@80386.nl>
To:        FreeBSD Arch <freebsd-arch@freebsd.org>
Subject:   Making LLVM happy: memmove() in the kernel
Message-ID:  <20090227131155.GE19161@hoeg.nl>

next in thread | raw e-mail | index | archive | help

--2mUf73N0HmzM2Naa
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Hi all,

The FreeBSD+LLVM folks* noticed Clang generates calls to memmove() by
itself. I have yet to confirm this, but I assume this is done when
performing copies of structs greater than a certain size. In our kernel,
we don't have a memmove() function, but we do have a bcopy().

Because memmove() must be a function in this case (not a simple macro),
Roman and I agreed that adding a memmove() to libkern would be the best
thing to do for now, simply by calling bcopy(). ARM already has a
memmove() in support.S, so we don't need it there.

So my question is: what is your folks opinion on this patch?

	http://80386.nl/pub/memmove.diff

It would be lovely if we could integrate this patch (or a similar one),
because this will allow us to build kernels with Clang out of the box.

--=20
 Ed Schouten <ed@80386.nl>
 WWW: http://80386.nl/

* http://wiki.freebsd.org/BuildingFreeBSDWithClang

--2mUf73N0HmzM2Naa
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (FreeBSD)

iEYEARECAAYFAkmn5psACgkQ52SDGA2eCwVRLACdFdrXwy3q6mToUszQW6/mixoA
/UgAn1tHChVlTcNiGke141s0CnNzMS5z
=FjIf
-----END PGP SIGNATURE-----

--2mUf73N0HmzM2Naa--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090227131155.GE19161>