Exemplo n.º 1
0
def PC(in_, load, inc, reset):
    "16-bit counter with load and reset controls."
    out_ = deferred_wires(16)
    choice1 = gates.mux16(out_, arithmetic.inc16(out_), inc)
    choice2 = gates.mux16(choice1, in_, load)
    choice3 = gates.mux16(choice2, (lo, ) * 16, reset)
    return resolve(out_, register(choice3, hi))
Exemplo n.º 2
0
def PC(in_, load, inc, reset):
    "16-bit counter with load and reset controls."
    out_ = deferred_wires(16)
    choice1 = gates.mux16(out_, arithmetic.inc16(out_), inc)
    choice2 = gates.mux16(choice1, in_, load)
    choice3 = gates.mux16(choice2, (lo,) * 16, reset)
    return resolve(out_, register(choice3, hi))
Exemplo n.º 3
0
def test_inc16():
    exhaustive_test(inc16, lambda *in_: A.inc16(in_), 16)
Exemplo n.º 4
0
def test_inc16():
    exhaustive_test(inc16, lambda *in_: A.inc16(in_), 16)