Skip to content

Commit 7338470

Browse files
Add more attributes to SmarBufferSRAM
1 parent ba5dc39 commit 7338470

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

  • hwcomponents_library/library

hwcomponents_library/library/misc.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,9 @@ def __init__(
145145
)
146146
self.address_bits = max(math.ceil(math.log2(depth)), 1)
147147
self.width = width
148+
self.depth = depth
149+
self.n_rw_ports = n_rw_ports
150+
self.n_banks = n_banks
148151

149152
self.address_reg = AladdinRegister(width=self.address_bits, tech_node=tech_node)
150153
self.delta_reg = AladdinRegister(width=self.address_bits, tech_node=tech_node)
@@ -174,6 +177,7 @@ def read(self) -> float:
174177
float
175178
The energy consumed by a read operation in Joules.
176179
"""
180+
print(f'My width is {self.width}')
177181
self.sram.read(bits_per_action=self.width)
178182
self.address_reg.read()
179183
self.delta_reg.read()

0 commit comments

Comments
 (0)