Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve control over pin placement. #192

Merged
merged 1 commit into from
Sep 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions place_and_route/build_defs.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -88,12 +88,16 @@ place_and_route = rule(
""",
),
"sdc": attr.label(allow_single_file = True),
"pin_placement_script": attr.label(allow_single_file = [".tcl"], doc = "See https://openroad.readthedocs.io/en/latest/main/src/ppl/README.html for syntax"),
"clocks": attr.string_dict(),
"die_width_microns": attr.int(),
"die_height_microns": attr.int(),
"core_padding_microns": attr.int(mandatory = True),
"target_die_utilization_percentage": attr.string(doc = "string float value from 0-100 which sets the die area based on an estimated die area target utilization"),
"placement_density": attr.string(default = "0.69", doc = "When performing global placement this is how densely our cells should be packaged on the die parameter is (0-1]"),
"density_fill_config": attr.label(allow_single_file = True),
"sink_clustering_size": attr.int(doc = "Clock tree synthesis sink group size"),
"sink_clustering_max_diameter": attr.int(doc = "Clock tree synthesis sink group desired diamater in microns"),
"min_pin_distance": attr.string(doc = "The minimum distance in microns between pins around the outside of the block."),
},
)
4 changes: 3 additions & 1 deletion place_and_route/private/clock_tree_synthesis.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,10 @@ def clock_tree_synthesis(ctx, open_road_info):
format_openroad_do_not_use_list(open_road_configuration.do_not_use_cell_list),
"estimate_parasitics -placement",
"repair_clock_inverters",
"clock_tree_synthesis -root_buf \"{cts_buffer}\" -buf_list \"{cts_buffer}\" -sink_clustering_enable -post_cts_disable".format(
"clock_tree_synthesis -root_buf \"{cts_buffer}\" -buf_list \"{cts_buffer}\" -sink_clustering_enable {sink_clustering_size} {sink_clustering_max_diameter}".format(
cts_buffer = open_road_configuration.cts_buffer_cell,
sink_clustering_size = "-sink_clustering_size {}".format(ctx.attr.sink_clustering_size) if ctx.attr.sink_clustering_size else "",
sink_clustering_max_diameter = "-sink_clustering_max_diameter {}".format(ctx.attr.sink_clustering_max_diameter) if ctx.attr.sink_clustering_max_diameter else "",
),
"set_propagated_clock [all_clocks]",
"repair_clock_nets",
Expand Down
1 change: 1 addition & 0 deletions place_and_route/private/global_placement.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ def global_placement(ctx, open_road_info):
pad_left = open_road_configuration.global_placement_cell_pad,
pad_right = open_road_configuration.global_placement_cell_pad,
),
"remove_buffers",
]

command_output = openroad_command(
Expand Down
10 changes: 7 additions & 3 deletions place_and_route/private/place_pins.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,16 @@ def place_pins(ctx, open_road_info):
]
tapcell_command = "source {}".format(open_road_configuration.tapcell_tcl.path)

if ctx.file.pin_placement_script:
inputs.append(ctx.file.pin_placement_script)

open_road_commands = timing_setup_command_struct.commands + [
"remove_buffers",
"place_pins -hor_layers {hor_layers} -ver_layers {ver_layers}".format(
"source {}".format(ctx.file.pin_placement_script.path) if ctx.file.pin_placement_script else "",
"place_pins -hor_layers {hor_layers} -ver_layers {ver_layers} {min_pin_distance}".format(
hor_layers = open_road_configuration.pin_horizontal_metal_layer,
ver_layers = open_road_configuration.pin_vertical_metal_layer,
),
min_pin_distance = "-min_distance {}".format(ctx.attr.min_pin_distance) if ctx.attr.min_pin_distance else "",
),
tapcell_command,
]

Expand Down