From: Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx> Date: Tue, 10 Apr 2012 15:50:49 -0700 > For the "strncpy_from_user()", you only have the 'detect zeroes', and > the loop count is often noticeable (whole pathname), so it might make > sense to do that outside the loop. Just wanted to mention that handling the detect zeroes operations on cpus that require alignment is easy, just rewind the pointer at the beginning to be aligned and "or" in a mask of 0xff for each alignment pad byte into the initially loaded word. That's how we do it in glibc on sparc and powerpc already. The only reason to go to little-endian is to 1) potentially save a small number of cycles on the loop exit and frankly I think if you do another load to accomplish that you'll anihilate up all the gains and 2) make the "strlen + hash function computation" case eaiser. -- To unsubscribe from this list: send the line "unsubscribe linux-arch" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html