path: root/block-sha1
AgeCommit message (Collapse)Author
2009-08-06block-sha1: try to use rol/ror appropriatelyLinus Torvalds
Use the one with the smaller constant. It _can_ generate slightly smaller code (a constant of 1 is special), but perhaps more importantly it's possibly faster on any uarch that does a rotate with a loop. Signed-off-by: Linus Torvalds <> Signed-off-by: Junio C Hamano <>
2009-08-06block-sha1: undo ctx->size changeJunio C Hamano
Undo the change I picked up from the mailing list discussion suggested by Nico, not because it is wrong, but it will be done at the end of the follow-up series. Signed-off-by: Junio C Hamano <>
2009-08-06Add new optimized C 'block-sha1' routinesLinus Torvalds
Based on the mozilla SHA1 routine, but doing the input data accesses a word at a time and with 'htonl()' instead of loading bytes and shifting. It requires an architecture that is ok with unaligned 32-bit loads and a fast htonl(). Signed-off-by: Linus Torvalds <> Signed-off-by: Junio C Hamano <>