Michael Cree f2db633d30 alpha: Use new generic strncpy_from_user() and strnlen_user()
Similar to x86/sparc/powerpc implementations except:
1) we implement an extremely efficient has_zero()/find_zero()
   sequence with both prep_zero_mask() and create_zero_mask()
   no-operations.
2) Our output from prep_zero_mask() differs in that only the
   lowest eight bits are used to represent the zero bytes
   nevertheless it can be safely ORed with other similar masks
   from prep_zero_mask() and forms input to create_zero_mask(),
   the two fundamental properties prep_zero_mask() must satisfy.

Tests on EV67 and EV68 CPUs revealed that the generic code is
essentially as fast (to within 0.5% of CPU cycles) of the old
Alpha specific code for large quadword-aligned strings, despite
the 30% extra CPU instructions executed.  In contrast, the
generic code for unaligned strings is substantially slower (by
more than a factor of 3) than the old Alpha specific code.

Signed-off-by: Michael Cree <mcree@orcon.net.nz>
Acked-by: Matt Turner <mattst88@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2012-08-19 08:41:18 -07:00
..
2009-01-15 16:39:40 -08:00
2012-03-20 21:29:46 -04:00
2012-03-28 18:11:12 +01:00
2011-03-31 11:26:23 -03:00
2012-03-28 18:11:12 +01:00
2009-05-02 15:36:10 -07:00
2012-03-28 18:11:12 +01:00
2011-03-31 11:26:23 -03:00
2005-04-16 15:20:36 -07:00
2012-03-28 18:11:12 +01:00
2005-04-16 15:20:36 -07:00
2012-03-28 18:11:12 +01:00
2012-05-05 13:00:21 +02:00
2012-03-28 18:11:12 +01:00
2010-08-31 22:45:31 -04:00
2012-03-28 18:11:12 +01:00
2012-03-28 18:11:12 +01:00
2012-06-01 12:58:52 -04:00
2011-09-27 18:08:04 +02:00
2012-03-28 18:11:12 +01:00
2012-03-28 18:11:12 +01:00