hex.quadrupled_exact_xorΒΆ
{q3,q2,q1,q0} ^= src
{r3,r2,r1,r0} ^= src
{t3,t2,t1,t0} ^= src
{d3,d2,d1,d0} ^= src
r3,r2,r1,r0,q3,q2,q1,q0,t3,t2,t1,t0,d3,d2,d1,d0 are bit-addresses; src is hex.
SignatureΒΆ
def quadrupled_exact_xor r3, r2, r1, r0, q3, q2, q1, q0, t3, t2, t1, t0, d3, d2, d1, d0, src @ first_flip, second_flip, third_flip, fourth_flip, end { ... }
Defined in hex/logics.fj β lines 166β243 (view on GitHub).
ComplexityΒΆ
Time:
@+12Space:
@+60
See the complexity glossary for what @, w, dw, dbit, n mean.
SourceΒΆ
Click to view the macro body
def quadrupled_exact_xor r3, r2, r1, r0, q3, q2, q1, q0, \
t3, t2, t1, t0, d3, d2, d1, d0, src @ first_flip, second_flip, third_flip, fourth_flip, end {
wflip src+w, first_flip, src
pad 16
first_flip:
;end // 0
r0;second_flip+ 1*dw // 1
r1;second_flip+ 2*dw // 2
r1;second_flip+ 3*dw // 3
r2;second_flip+ 4*dw // 4
r2;second_flip+ 5*dw // 5
r2;second_flip+ 6*dw // 6
r2;second_flip+ 7*dw // 7
r3;second_flip+ 8*dw // 8
r3;second_flip+ 9*dw // 9
r3;second_flip+10*dw // 10
r3;second_flip+11*dw // 11
r3;second_flip+12*dw // 12
r3;second_flip+13*dw // 13
r3;second_flip+14*dw // 14
r3;second_flip+15*dw // 15
second_flip:
;end // 0
q0;third_flip+ 1*dw // 1
q1;third_flip+ 2*dw // 2
q1;third_flip+ 3*dw // 3
q2;third_flip+ 4*dw // 4
q2;third_flip+ 5*dw // 5
q2;third_flip+ 6*dw // 6
q2;third_flip+ 7*dw // 7
q3;third_flip+ 8*dw // 8
q3;third_flip+ 9*dw // 9
q3;third_flip+10*dw // 10
q3;third_flip+11*dw // 11
q3;third_flip+12*dw // 12
q3;third_flip+13*dw // 13
q3;third_flip+14*dw // 14
q3;third_flip+15*dw // 15
third_flip:
;end // 0
t0;fourth_flip+ 1*dw // 1
t1;fourth_flip+ 2*dw // 2
t1;fourth_flip+ 3*dw // 3
t2;fourth_flip+ 4*dw // 4
t2;fourth_flip+ 5*dw // 5
t2;fourth_flip+ 6*dw // 6
t2;fourth_flip+ 7*dw // 7
t3;fourth_flip+ 8*dw // 8
t3;fourth_flip+ 9*dw // 9
t3;fourth_flip+10*dw // 10
t3;fourth_flip+11*dw // 11
t3;fourth_flip+12*dw // 12
t3;fourth_flip+13*dw // 13
t3;fourth_flip+14*dw // 14
t3;fourth_flip+15*dw // 15
fourth_flip:
;end // 0
d0;end // 1
d1;end // 2
d1;first_flip+1*dw // 3
d2;end // 4
d2;first_flip+1*dw // 5
d2;first_flip+2*dw // 6
d2;first_flip+3*dw // 7
d3;end // 8
d3;first_flip+1*dw // 9
d3;first_flip+2*dw // 10
d3;first_flip+3*dw // 11
d3;first_flip+4*dw // 12
d3;first_flip+5*dw // 13
d3;first_flip+6*dw // 14
d3;first_flip+7*dw // 15
end:
wflip src+w, first_flip
}
β Previous: hex.address_and_variable_double_xor
Next: hex.not/1 β