Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: CVS commit: syssrc/sys/sys



On 6 Jul 2001, Klaus Klein wrote:

: > bcopy() is documented as allowing overlapping memory regions.  Define it
: > in terms of the standard name memmove() to account for this.
: > Fixes kern/13369
:
: This change looks wrong to me.  While the libc bcopy() implementation
: is indeed documented as allowing overlapping memory objects, this is
: not the case for its kernel pendant, which led (historically) to the
: alternate version ovbcopy() being used for possibly overlapping
: objects.

Yes, I know.  However, PR kern/13369 was created because of kernel source
code which used bcopy under the assumptions listed in bcopy(3), since we
don't have a bcopy(9).

The other alternatives to this change are:

1. reintroduce ovbcopy() as a macro,
2. eliminate all uses of bcopy() in the kernel (incl. imported sources),
3. create a bcopy(9) manpage which describes the differences.

I'd rather see most instances of bcopy() eliminated (partial #2) here, and
then Just Deal with the slight overhead of the bcopy() compatibility
#define.  This is the intent of my commit.

My second choice would be to create the manpage as in #3.

Thoughts?

-- 
-- Todd Vierling <tv%wasabisystems.com@localhost>  *  Wasabi NetBSD:  Run with 
it.
-- NetBSD 1.5 now available on CD-ROM  --  http://www.wasabisystems.com/




Home | Main Index | Thread Index | Old Index