Re: [PATCH 2/3] [CRYPTO] Add optimized SHA-1 implementation for i486+

2007-06-09 Thread Benjamin Gilbert
Jan Engelhardt wrote: On Jun 8 2007 17:42, Benjamin Gilbert wrote: @@ -0,0 +1,299 @@ +/* + * x86-optimized SHA1 hash algorithm (i486 and above) + * + * Originally from Nettle + * Ported from M4 to cpp by Benjamin Gilbert <[EMAIL PROTECTED]> + * + * Copyright (C) 2004, Niels M?ller + * Copyright

Re: [PATCH 2/3] [CRYPTO] Add optimized SHA-1 implementation for i486+

2007-06-09 Thread Benjamin Gilbert
Jeff Garzik wrote: Matt Mackall wrote: Have you benchmarked this against lib/sha1.c? Please post the results. Until then, I'm frankly skeptical that your unrolled version is faster because when I introduced lib/sha1.c the rolled version therein won by a significant margin and had 1/10th the cach

Re: [PATCH 2/3] [CRYPTO] Add optimized SHA-1 implementation for i486+

2007-06-09 Thread Matt Mackall
On Sat, Jun 09, 2007 at 04:23:27PM -0400, Jeff Garzik wrote: > Matt Mackall wrote: > >On Fri, Jun 08, 2007 at 05:42:53PM -0400, Benjamin Gilbert wrote: > >>Add x86-optimized implementation of the SHA-1 hash function, taken from > >>Nettle under the LGPL. This code will be enabled on kernels compil

Re: [PATCH 2/3] [CRYPTO] Add optimized SHA-1 implementation for i486+

2007-06-09 Thread Jeff Garzik
Matt Mackall wrote: On Fri, Jun 08, 2007 at 05:42:53PM -0400, Benjamin Gilbert wrote: Add x86-optimized implementation of the SHA-1 hash function, taken from Nettle under the LGPL. This code will be enabled on kernels compiled for 486es or better; kernels which support 386es will use the generi

Re: [PATCH 2/3] [CRYPTO] Add optimized SHA-1 implementation for i486+

2007-06-09 Thread Matt Mackall
On Fri, Jun 08, 2007 at 05:42:53PM -0400, Benjamin Gilbert wrote: > Add x86-optimized implementation of the SHA-1 hash function, taken from > Nettle under the LGPL. This code will be enabled on kernels compiled for > 486es or better; kernels which support 386es will use the generic > implementatio

Re: [PATCH 2/3] [CRYPTO] Add optimized SHA-1 implementation for i486+

2007-06-09 Thread Jan Engelhardt
On Jun 8 2007 17:42, Benjamin Gilbert wrote: >@@ -0,0 +1,299 @@ >+/* >+ * x86-optimized SHA1 hash algorithm (i486 and above) >+ * >+ * Originally from Nettle >+ * Ported from M4 to cpp by Benjamin Gilbert <[EMAIL PROTECTED]> >+ * >+ * Copyright (C) 2004, Niels M?ller >+ * Copyright (C) 2006-2007