MD5/Implementation: Difference between revisions
→{{header|11l}}: support `--int64` option
Alextretyak (talk | contribs) m (→{{header|11l}}) |
Alextretyak (talk | contribs) (→{{header|11l}}: support `--int64` option) |
||
Line 41:
init_values = (UInt32(6745'2301), UInt32(EFCD'AB89), UInt32(98BA'DCFE), UInt32(1032'5476))
[((
functions [+]= (b, c, d) -> (b [&] c) [|] ((-)b [&] d)
functions [+]= (b, c, d) -> (d [&] b) [|] ((-)d [&] c)
Line 47:
functions [+]= (b, c, d) -> c (+) (b [|] (-)d)
[(
index_functions [+]= i -> i
index_functions [+]= i -> (5 * i + 1) % 16
Line 68:
V f = :functions[i I/ 16](b, c, d)
V g = :index_functions[i I/ 16](i)
V to_rotate = a + f + :constants[i] +
V new_b = UInt32(b + rotl(to_rotate, :rotate_amounts[i]))
(a, b, c, d) = (d, new_b, b, c)
|