summaryrefslogtreecommitdiff
path: root/src/regress
diff options
context:
space:
mode:
authorjsing <>2025-01-19 07:51:41 +0000
committerjsing <>2025-01-19 07:51:41 +0000
commita2f6e4db5ee489ac3600ec5518e9914d017f85de (patch)
treeec020deb0d1f679179eab8c5f4643191d4e623cc /src/regress
parent34423391bcc52ecedccc906e3945ef585e383920 (diff)
downloadopenbsd-a2f6e4db5ee489ac3600ec5518e9914d017f85de.tar.gz
openbsd-a2f6e4db5ee489ac3600ec5518e9914d017f85de.tar.bz2
openbsd-a2f6e4db5ee489ac3600ec5518e9914d017f85de.zip
Improve bit counter handling in MD5.
Like most hashes, MD5 needs to keep count of the number of bits in the message being processed. However, rather than using a 64 bit counter this is implemented using two 32 bit values (which is exposed in the public API). Even with this hurdle, we can still use 64 bit math and let the compiler figure out how to best handle the situation (hopefully avoiding compiler warnings on 16 bit platforms in the process!). On amd64 this code now requires two instructions, instead of the previous five. While here remove a comment that is excessively visible and no longer completely accurate (and if you're going to redefine types like MD5_WORD you kinda need to know what you're doing). ok tb@ (who's going to miss the dear diary style comments)
Diffstat (limited to 'src/regress')
0 files changed, 0 insertions, 0 deletions