XP is just a number | |
PerlMonks |
Re^5: Challenge: CPU-optimized byte-wise or-equals (for a meter of beer) (addr math)by tye (Sage) |
on Sep 13, 2007 at 01:29 UTC ( [id://638717]=note: print w/replies, xml ) | Need Help?? |
Yes, memchr() and related items usually end up implementing their loop in a single machine-language instruction on most processors. Given the relative infrequency of '\0' bytes, the added complexity of computation when one is found is outweighed by the much more efficient finding of them. - tye
In Section
Seekers of Perl Wisdom
|
|