@@ -32,8 +32,6 @@ def and_gate(inputs, output=None):
3232
3333 return aig .AIG (
3434 inputs = frozenset (inputs ),
35- latch_map = frozenset (),
36- latch2init = frozenset (),
3735 node_map = frozenset (((output , _map_tree (inputs , f = _and )), )),
3836 comments = (' and ' .join (inputs ), ))
3937
@@ -61,8 +59,6 @@ def parity_gate(inputs, output=None):
6159
6260 return aig .AIG (
6361 inputs = frozenset (inputs ),
64- latch_map = frozenset (),
65- latch2init = frozenset (),
6662 node_map = frozenset (((output , _map_tree (inputs , f = _xor )), )),
6763 comments = (' xor ' .join (inputs ), ))
6864
@@ -73,14 +69,12 @@ def identity(inputs, outputs=None):
7369
7470 return aig .AIG (
7571 inputs = frozenset (inputs ),
76- latch_map = frozenset (),
77- latch2init = frozenset (),
7872 node_map = frozenset (zip (outputs , map (aig .Input , inputs ))),
7973 comments = ('identity' , ))
8074
8175
8276def empty ():
83- return identity ([] )
77+ return aig . AIG ( )
8478
8579
8680def _inverted_input (name ):
@@ -95,8 +89,6 @@ def bit_flipper(inputs, outputs=None):
9589
9690 return aig .AIG (
9791 inputs = frozenset (inputs ),
98- latch_map = frozenset (),
99- latch2init = frozenset (),
10092 node_map = frozenset (zip (outputs , map (_inverted_input , inputs ))),
10193 comments = ('~' , ))
10294
@@ -107,19 +99,13 @@ def _const(val):
10799
108100def source (outputs ):
109101 return aig .AIG (
110- inputs = frozenset (),
111- latch_map = frozenset (),
112- latch2init = frozenset (),
113102 node_map = frozenset ((k , _const (v )) for k , v in outputs .items ()),
114103 comments = ('source' , ))
115104
116105
117106def sink (inputs ):
118107 return aig .AIG (
119108 inputs = frozenset (inputs ),
120- latch_map = frozenset (),
121- latch2init = frozenset (),
122- node_map = frozenset (),
123109 comments = ('sink' , ))
124110
125111
@@ -132,8 +118,6 @@ def tee_output(name, renames):
132118
133119 return aig .AIG (
134120 inputs = frozenset (outputs ),
135- latch_map = frozenset (),
136- latch2init = frozenset (),
137121 node_map = frozenset .union (* starmap (tee_output , outputs .items ())),
138122 comments = ('T' , ))
139123
0 commit comments