bcopy

mcdonald at uxe.cso.uiuc.edu mcdonald at uxe.cso.uiuc.edu
Sat Dec 17 02:24:00 AEST 1988


/* Written  2:11 pm  Dec 14, 1988 by guy at auspex.UUCP in uxe.cso.uiuc.edu:comp.unix.questions */

 >It seems to me the idea is that memcpy should be the most efficient
 >possible way to copy SMALL things - maybe even things like structs
 >containing four bytes, in which case a 32 bit integer move instruction
 >could be generated (if the alignemnt was right).

The C compilers I know of generate inline code, not calls to "memcpy" or
any other subroutine, for structure assignments; they may even generate
such a move instruction if appropriate.
/* End of text from uxe.cso.uiuc.edu:comp.unix.questions */

My brain was on coffee break when I said "struct". I meant "array".



More information about the Comp.unix.questions mailing list