bit.rorΒΆ
rotate x[:n] right by 1-bit
SignatureΒΆ
def ror n, x @ temp_bit { ... }
Defined in bit/shifts.fj β lines 48β55 (view on GitHub).
ComplexityΒΆ
Time:
n(2@-1)Space:
n(2@-1)
See the complexity glossary for what @, w, dw, dbit, n mean.
SourceΒΆ
Click to view the macro body
def ror n, x @ temp_bit {
.mov temp_bit, x
rep(n-1, i) .mov x+i*dw, x+(i+1)*dw
.mov x+(n-1)*dw, temp_bit
stl.skip
temp_bit:
.bit
}