Skip to content

Commit fd82969

Browse files
authored
Merge pull request hdl#314 from hdl/read_sdc
Make power estimate more accurate by reading SDC first
2 parents 6070f55 + a99f948 commit fd82969

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

place_and_route/private/floorplan.bzl

+12-3
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
"""Floorplaning openROAD commands"""
1616

1717
load("@rules_hdl//pdk:open_road_configuration.bzl", "get_open_road_configuration")
18-
load("//place_and_route:open_road.bzl", "OpenRoadInfo", "openroad_command")
18+
load("//place_and_route:open_road.bzl", "OpenRoadInfo", "openroad_command", "timing_setup_commands")
1919
load("//place_and_route:private/report_area.bzl", "generate_area_results")
2020
load("//place_and_route:private/report_power.bzl", "generate_power_results")
2121
load("//synthesis:build_defs.bzl", "SynthesisInfo")
@@ -73,6 +73,10 @@ def init_floor_plan(ctx):
7373
tieoneport = open_road_configuration.tie_high_port
7474
tiezeroport = open_road_configuration.tie_low_port
7575

76+
timing_setup_command_struct = timing_setup_commands(ctx)
77+
78+
input_open_road_files = timing_setup_command_struct.inputs
79+
7680
open_road_commands = [
7781
"read_lef {tech_lef}".format(
7882
tech_lef = tech_lef.path,
@@ -89,6 +93,9 @@ def init_floor_plan(ctx):
8993
"link_design {top_module}".format(
9094
top_module = top_module,
9195
),
96+
])
97+
open_road_commands.extend(timing_setup_command_struct.commands)
98+
open_road_commands.extend([
9299
_initialize_floorplan_command(ctx),
93100
"source {tracks_file}".format(
94101
tracks_file = open_road_configuration.tracks_file.path,
@@ -104,12 +111,14 @@ def init_floor_plan(ctx):
104111
open_road_commands.extend(generate_power_results(ctx, verilog_based_power_results))
105112
open_road_commands.extend(generate_area_results(verilog_based_area_results))
106113

107-
input_open_road_files = [
114+
input_open_road_files.extend([
108115
netlist,
109116
liberty,
110117
tech_lef,
111118
open_road_configuration.tracks_file,
112-
] + std_cell_lef + additional_liberties
119+
])
120+
input_open_road_files.extend(std_cell_lef)
121+
input_open_road_files.extend(additional_liberties)
113122

114123
command_output = openroad_command(
115124
ctx,

0 commit comments

Comments
 (0)