Skip to content

Commit

Permalink
[Hack WIP] ol2/tt_top: Setup STA
Browse files Browse the repository at this point in the history
Not working :(
Paths are not found / analyzed ...

Signed-off-by: Sylvain Munaut <[email protected]>
  • Loading branch information
smunaut committed Oct 11, 2023
1 parent 7c07dc0 commit b44604f
Show file tree
Hide file tree
Showing 2 changed files with 88 additions and 1 deletion.
81 changes: 81 additions & 0 deletions ol2/tt_top/base.sdc
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
#
# TT top level STA
#


# Segment signals
# ---------------

# Port: Control inputs
set all_ctl [ get_ports { "io_in[36]" "io_in[34]" "io_in[32]" } ]

# Port: User IO
set all_pads_in [list]
set all_pads_out [list]

# UIO
for {set i 0} {$i < 8} {incr i} {
set j [expr $i+24]
lappend all_pads_in [ get_ports "io_in[$j]" ]
lappend all_pads_out [ get_ports "io_out[$j]" ]
lappend all_pads_out [ get_ports "io_oeb[$j]" ]
}

# UO
for {set i 0} {$i < 8} {incr i} {
set j [expr $i+16]
lappend all_pads_out [ get_ports "io_out[$j]" ]
}

# UI
for {set i 0} {$i < 10} {incr i} {
set j [expr $i+6]
lappend all_pads_in [ get_ports "io_in[$j]" ]
}

# Pins:
set all_pins_um_ctl [ get_pins {*/um_ena*} ]
set all_pins_um_iw [ get_pins {*/um_iw*} ]
set all_pins_um_ow [ get_pins {*/um_ow*} ]


# Inputs
# ------

# All `io_in` come from strong buffer in the gpio_control_block
set_driving_cell -lib_cell sky130_fd_sc_hd__buf_16 -pin X [all_inputs]


# Loads
# -----

# All `io_out` & `io_oeb` go to gpio_control_block and have a bit
# of capacitance (estimates from lib and gpio_control_block.spef)
set_load 0.03 [all_outputs]


# Clock
# -----

# Only clock is the ctrl_sel_inc
# The internal sub-divided clocks are checked internally when
# hardening tt_ctrl itself so don't bother here
create_clock -name ctrl_inc -period 10 [ get_ports "io_in[34]" ]


# Max delays
# ----------

# No artifical delays
set_input_delay 0 [all_inputs]
set_output_delay 0 [all_outputs]

# Control delays
set_max_delay -from $all_ctl -to $all_pads_out 10.0

set_max_delay -from $all_ctl -to $all_pins_um_ctl 10.0
set_max_delay -from $all_ctl -to $all_pins_um_iw 10.0

# User IO
set_max_delay -from $all_pads_in -to $all_pins_um_iw 10.0
set_max_delay -from $all_pins_um_ow -to $all_pads_out 10.0
8 changes: 7 additions & 1 deletion ol2/tt_top/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ class TopFlow(SequentialFlow):
Odb.ReportWireLength,
Checker.WireLength,
OpenROAD.RCX,
# OpenROAD.STAPostPNR, # FIXME
OpenROAD.STAPostPNR,
OpenROAD.IRDropReport,
Magic.StreamOut,
Magic.WriteLEF,
Expand Down Expand Up @@ -133,6 +133,9 @@ class TopFlow(SequentialFlow):
"orientation": m.orient,
}

# Check that macros_models have '/// sta-blackbox' marker
# FIXME

# Custom config
flow_cfg = {
# Main design properties
Expand All @@ -150,6 +153,9 @@ class TopFlow(SequentialFlow):
"EXTRA_VERILOG_MODELS": macros_models,
"MACROS": macros,

# Constraints
"BASE_SDC_FILE" : "base.sdc",

# Synthesis
"SYNTH_ELABORATE_ONLY" : True,
"SYNTH_EXCLUSION_CELL_LIST" : "no_synth_cells.txt",
Expand Down

0 comments on commit b44604f

Please sign in to comment.