Skip to content

Commit 452bbb7

Browse files
committed
dpl: add unit test
Signed-off-by: Eder Monteiro <[email protected]>
1 parent c74f792 commit 452bbb7

File tree

7 files changed

+46
-0
lines changed

7 files changed

+46
-0
lines changed

src/dpl/src/PlacementDRC.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -305,6 +305,7 @@ bool PlacementDRC::checkPadding(const Node* cell,
305305
const bool left_edge = x == 0;
306306
const bool right_edge = cell_x_end == grid_->getRowSiteCount();
307307
if (!cell->isFixed() && !left_edge && !right_edge) {
308+
// Padding violation with the core edge.
308309
return false;
309310
}
310311
continue;

src/dpl/test/BUILD

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ COMPULSORY_TESTS = [
5656
"pad06",
5757
"pad07",
5858
"pad08",
59+
"pad09",
5960
"regions1",
6061
"regions2",
6162
"regions3",

src/dpl/test/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ or_integration_tests(
5959
pad06
6060
pad07
6161
pad08
62+
pad09
6263
regions1
6364
regions2
6465
regions3

src/dpl/test/pad09.def

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
VERSION 5.8 ;
2+
DIVIDERCHAR "/" ;
3+
BUSBITCHARS "[]" ;
4+
DESIGN aes_cipher_top ;
5+
UNITS DISTANCE MICRONS 1000 ;
6+
DIEAREA ( 0 0 ) ( 2000000 2000000 ) ;
7+
ROW ROW_283 unit 30240 975690 FS DO 3624 BY 1 STEP 480 0 ;
8+
COMPONENTS 2 ;
9+
- ANTENNA_283 sky130_fd_sc_hs__diode_2 + PLACED ( 30240 975690 ) FS ;
10+
- ANTENNA_284 sky130_fd_sc_hs__diode_2 + PLACED ( 1768800 975690 ) FS ;
11+
END COMPONENTS
12+
END DESIGN

src/dpl/test/pad09.defok

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
VERSION 5.8 ;
2+
DIVIDERCHAR "/" ;
3+
BUSBITCHARS "[]" ;
4+
DESIGN aes_cipher_top ;
5+
UNITS DISTANCE MICRONS 1000 ;
6+
DIEAREA ( 0 0 ) ( 2000000 2000000 ) ;
7+
ROW ROW_283 unit 30240 975690 FS DO 3624 BY 1 STEP 480 0 ;
8+
COMPONENTS 2 ;
9+
- ANTENNA_283 sky130_fd_sc_hs__diode_2 + PLACED ( 30240 975690 ) FS ;
10+
- ANTENNA_284 sky130_fd_sc_hs__diode_2 + PLACED ( 1768800 975690 ) FS ;
11+
END COMPONENTS
12+
NETS 0 ;
13+
END NETS
14+
END DESIGN

src/dpl/test/pad09.ok

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
[INFO ODB-0227] LEF file: sky130hs/sky130hs.tlef, created 13 layers, 25 vias
2+
[INFO ODB-0227] LEF file: sky130hs/sky130hs_std_cell.lef, created 390 library cells
3+
[INFO ODB-0128] Design: aes_cipher_top
4+
[INFO ODB-0131] Created 2 components and 10 component-terminals.
5+
No differences found.

src/dpl/test/pad09.tcl

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# set_placement_padding 2
2+
source "helpers.tcl"
3+
read_lef sky130hs/sky130hs.tlef
4+
read_lef sky130hs/sky130hs_std_cell.lef
5+
read_def pad09.def
6+
# check -masters arg parsing
7+
set_placement_padding -global -left 2 -right 2
8+
check_placement
9+
10+
set def_file [make_result_file pad09.def]
11+
write_def $def_file
12+
diff_file pad09.defok $def_file

0 commit comments

Comments
 (0)