summaryrefslogtreecommitdiff
path: root/builtin-check-attr.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2009-08-06 03:49:41 (GMT)
committerJunio C Hamano <gitster@pobox.com>2009-08-06 20:56:45 (GMT)
commit7b5075fcfb069fc36ba4cfe5567234974793ab58 (patch)
tree2eba4fbbee102e4e80ec5377b201d5c1f56554f8 /builtin-check-attr.c
parent139e3456ecf18fc03a75eda7a77441e8fec344b9 (diff)
downloadgit-7b5075fcfb069fc36ba4cfe5567234974793ab58.zip
git-7b5075fcfb069fc36ba4cfe5567234974793ab58.tar.gz
git-7b5075fcfb069fc36ba4cfe5567234974793ab58.tar.bz2
block-sha1: re-use the temporary array as we calculate the SHA1
The mozilla-SHA1 code did this 80-word array for the 80 iterations. But the SHA1 state is really just 512 bits, and you can actually keep it in a kind of "circular queue" of just 16 words instead. This requires us to do the xor updates as we go along (rather than as a pre-phase), but that's really what we want to do anyway. This gets me really close to the OpenSSL performance on my Nehalem. Look ma, all C code (ok, there's the rol/ror hack, but that one doesn't strictly even matter on my Nehalem, it's just a local optimization). Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin-check-attr.c')
0 files changed, 0 insertions, 0 deletions