Aaron Lehmann wrote:
>
> On Sun, May 20, 2001 at 07:02:06PM -0400, Kevin Lawton wrote:
> > In 'kernel/util-nexus.c', there are some simple routines which
> > could use some asm speedups (memzero/memcpy/memset).
> >
> > Last time I checked, there's some code in the Linux kernel
> > that you could base it on.
> See these, too (i686 optimized):
>
>
>http://cvs.gnu.org/cgi-bin/cvsweb/glibc/sysdeps/i386/i686/memcpy.S?rev=1.3&content-type=text/x-cvsweb-markup
>
>http://cvs.gnu.org/cgi-bin/cvsweb/glibc/sysdeps/i386/i686/memset.S?rev=1.4&content-type=text/x-cvsweb-markup
>
> Although the Linux stuff seems nicer...
>
> MMX memcpy:
> http://lxr.linux.no/source/arch/i386/lib/mmx.c?v=2.4.4#L29
>
> normal memcpy:
> http://lxr.linux.no/source/include/asm-i386/string.h#L199
>
> memset:
> http://lxr.linux.no/source/include/asm-i386/string.h?v=2.4.4#L388
>
> memzero is defined in terms of memset:
> http://lxr.linux.no/source/arch/i386/boot/compressed/misc.c#L24
>
> But if util-nexus is ever used in kernel-space (and it seems it is),
> it should use the ones the Linux asm-i386 headers provide instead of
> defining its own.
Thanks for the URLs. BTW, we have to define our own, because they
are used from monitor as well as kernel space. We can not use functions
from the kernel outside of our own kernel module. The function are
used while in kernel space too, but since we have to have them
anyways...
Hopefully, someone will sort through those links and send me
some diffs (or a new util-nexus.c file). :^)
-Kevin
--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Kevin Lawton [EMAIL PROTECTED]
MandrakeSoft, Inc. Plex86 developer
http://www.linux-mandrake.com/ http://www.plex86.org/