mirror of https://github.com/VLSIDA/OpenRAM.git
Added way to determine length of en pin with wmask in write_driver_array and shortened en to width of driver.
This commit is contained in:
parent
0cfa0ac755
commit
49fffcbc92
|
|
@ -107,12 +107,12 @@ class write_driver_array(design.design):
|
|||
|
||||
def place_write_array(self):
|
||||
if self.bitcell.width > self.driver.width:
|
||||
driver_spacing = self.bitcell.width
|
||||
self.driver_spacing = self.bitcell.width
|
||||
else:
|
||||
driver_spacing = self.driver.width
|
||||
self.driver_spacing = self.driver.width
|
||||
for i in range(0,self.columns,self.words_per_row):
|
||||
index = int(i/self.words_per_row)
|
||||
base = vector(i * driver_spacing, 0)
|
||||
base = vector(i * self.driver_spacing, 0)
|
||||
self.driver_insts[index].place(base)
|
||||
|
||||
|
||||
|
|
@ -151,12 +151,18 @@ class write_driver_array(design.design):
|
|||
if self.write_size is not None:
|
||||
for bit in range(self.num_wmasks):
|
||||
en_pin = self.driver_insts[bit*self.write_size].get_pin("en")
|
||||
# modifier to stretch enable pin for column mux
|
||||
modifier = (self.words_per_row-1) + 0.65
|
||||
# Determine width of wmask modified en_pin with/without col mux
|
||||
if (self.words_per_row == 1):
|
||||
wmask_en_len = (self.write_size * self.driver_spacing)
|
||||
en_gap = self.driver_spacing - en_pin.width()
|
||||
else:
|
||||
wmask_en_len = 2*(self.write_size * self.driver_spacing)
|
||||
en_gap = self.driver_spacing
|
||||
|
||||
self.add_layout_pin(text="en_{0}".format(bit),
|
||||
layer=en_pin.layer,
|
||||
offset=en_pin.ll(),
|
||||
width=modifier*self.write_size*en_pin.width(),
|
||||
width=wmask_en_len-en_gap,
|
||||
height=en_pin.height())
|
||||
else:
|
||||
self.add_layout_pin(text="en",
|
||||
|
|
|
|||
|
|
@ -23,8 +23,12 @@ class write_driver_test(openram_test):
|
|||
globals.init_openram("config_{0}".format(OPTS.tech_name))
|
||||
|
||||
# check write driver array for single port
|
||||
debug.info(2, "Testing write_driver_array for columns=8, word_size=8, write_size=2")
|
||||
a = factory.create(module_type="write_driver_array", columns=8, word_size=8, write_size=2)
|
||||
debug.info(2, "Testing write_driver_array for columns=8, word_size=8, write_size=4")
|
||||
a = factory.create(module_type="write_driver_array", columns=8, word_size=8, write_size=4)
|
||||
self.local_check(a)
|
||||
|
||||
debug.info(2, "Testing write_driver_array for columns=16, word_size=16, write_size=2")
|
||||
a = factory.create(module_type="write_driver_array", columns=16, word_size=16, write_size=2)
|
||||
self.local_check(a)
|
||||
|
||||
debug.info(2, "Testing write_driver_array for columns=16, word_size=8, write_size=4")
|
||||
|
|
|
|||
Binary file not shown.
|
|
@ -1,6 +1,6 @@
|
|||
magic
|
||||
tech scmos
|
||||
timestamp 1565289461
|
||||
timestamp 1565304081
|
||||
<< nwell >>
|
||||
rect -3 101 37 138
|
||||
rect -3 0 37 51
|
||||
|
|
@ -177,7 +177,7 @@ rect 27 45 31 60
|
|||
rect 3 35 7 38
|
||||
rect 19 35 23 38
|
||||
rect 7 31 19 35
|
||||
rect 0 24 7 28
|
||||
rect 3 24 7 28
|
||||
rect 11 24 31 28
|
||||
<< m2contact >>
|
||||
rect 10 193 14 197
|
||||
|
|
@ -198,7 +198,6 @@ rect 15 0 19 6
|
|||
rect 0 0 34 203
|
||||
<< labels >>
|
||||
rlabel metal2 15 1 15 1 1 din
|
||||
rlabel metal1 2 25 2 25 3 en
|
||||
rlabel m2contact 21 66 21 66 1 gnd
|
||||
rlabel m2contact 28 88 28 88 1 gnd
|
||||
rlabel m2contact 21 33 21 33 1 vdd
|
||||
|
|
@ -206,4 +205,5 @@ rlabel m2contact 18 120 18 120 1 vdd
|
|||
rlabel metal2 12 201 12 201 5 bl
|
||||
rlabel metal2 22 201 22 201 5 br
|
||||
rlabel m2contact 14 161 14 161 1 gnd
|
||||
rlabel metal1 17 26 17 26 1 en
|
||||
<< end >>
|
||||
|
|
|
|||
Loading…
Reference in New Issue