tasks.py: support using nextpnr's "static" placer

It's still a WIP, but assuming its output is correct, it seems to net
a 5-10MHz boost to Fmax.
This commit is contained in:
David Anderson 2024-09-14 13:53:21 -07:00
parent 498aeae2f4
commit 2acf6aa661
1 changed files with 3 additions and 1 deletions

View File

@ -137,7 +137,7 @@ def build(c, target):
return verilog_files
@task
def synth(c, target, gui=False):
def synth(c, target, gui=False, new_placer=False):
target = resolve_synth_target(target)
out_info, out_verilog, out_bsc, out_yosys, out_nextpnr = ensure_build_dirs(target, "info", "verilog", "bsc", "yosys", "nextpnr")
@ -201,6 +201,8 @@ def synth(c, target, gui=False):
cmd = f"nextpnr-ecp5 --85k --detailed-timing-report --report {nextpnr_timing} --json {yosys_json} --gui --gui-no-aa --package=CABGA381 {pin_map_arg} --speed=6 --textcfg {nextpnr_out}"
else:
cmd = f"nextpnr-ecp5 --85k --detailed-timing-report -l {nextpnr_log} --report {nextpnr_timing} --json {yosys_json} --write {nextpnr_out_json} --package=CABGA381 {pin_map_arg} --speed=6 --textcfg {nextpnr_out}"
if new_placer:
cmd += f" --placer static"
out = c.run(cmd)
print_filtered_paragraphs(out.stderr, "Device utilisation", "Critical path", "Max frequency", "Max delay", common_prefix="Info: ")