I am copying N bytes from pSrc
to pDest
. This can be done in a single loop:
for (int i = 0; i < N; i++)
*pDest++ = *pSrc++
Why is this slower than memcpy
or memmove
? What tricks do they use to speed it up?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…