Skip to content

Commit e900c0c

Browse files
committed
ram: change to tap-to-tap distance and added tapcells to top row
Signed-off-by: braydenl9988 <[email protected]>
1 parent 88b8630 commit e900c0c

File tree

5 files changed

+2869
-2885
lines changed

5 files changed

+2869
-2885
lines changed

src/ram/src/ram.cpp

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ std::unique_ptr<Layout> RamGen::generateTapColumn(const int word_count,
177177
const int tapcell_col)
178178
{
179179
auto tapcell_layout = std::make_unique<Layout>(odb::vertical);
180-
for (int i = 0; i < word_count; ++i) {
180+
for (int i = 0; i <= word_count; ++i) {
181181
auto tapcell_cell = std::make_unique<Cell>();
182182
makeCellInst(tapcell_cell.get(),
183183
"tapcell",
@@ -575,9 +575,6 @@ void RamGen::generate(const int bytes_per_word,
575575
int nearest_tap
576576
= (max_tap_dist / ram_grid.getWidth()) * ram_grid.getLayoutWidth(0);
577577
int tapcell_count = 0;
578-
// x distance between transistor and tapcell means 2x distance between
579-
// tapcells
580-
max_tap_dist *= 2;
581578
// iterates through each of the columns
582579
for (int col = 0; col < ram_grid.numLayouts(); ++col) {
583580
if (nearest_tap + ram_grid.getLayoutWidth(col) >= max_tap_dist) {
@@ -591,7 +588,7 @@ void RamGen::generate(const int bytes_per_word,
591588
nearest_tap += ram_grid.getLayoutWidth(col);
592589
}
593590
// check for last column in the grid
594-
if (nearest_tap >= max_tap_dist / 2) {
591+
if (nearest_tap >= max_tap_dist) {
595592
auto tapcell_layout = generateTapColumn(word_count, tapcell_count);
596593
ram_grid.addLayout(std::move(tapcell_layout));
597594
}

src/ram/src/ram.tcl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ proc generate_ram_netlist { args } {
5858
}
5959
set tapcell $keys(-tapcell)
6060
} else {
61-
utl::info RAM 22 "No tapcell is specified.
61+
utl::warn RAM 22 "No tapcell is specified.
6262
The generated layout may not pass Design Rule Checks."
6363
}
6464

0 commit comments

Comments
 (0)