From: Robert Jordens Date: Fri, 4 Apr 2014 04:19:28 +0000 (-0600) Subject: mibuild/xilinx: make par and map options configurable X-Git-Tag: 24jan2021_ls180~2099^2~371 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=9ff6cc840341e5ec18c77fc369dca44b0a0aebd1;p=litex.git mibuild/xilinx: make par and map options configurable --- diff --git a/mibuild/xilinx_ise.py b/mibuild/xilinx_ise.py index 4bfca827..30dd4d11 100644 --- a/mibuild/xilinx_ise.py +++ b/mibuild/xilinx_ise.py @@ -125,7 +125,7 @@ def _is_valid_version(path, v): return False def _run_ise(build_name, ise_path, source, mode, ngdbuild_opt, - bitgen_opt, ise_commands): + bitgen_opt, ise_commands, map_opt, par_opt): if sys.platform == "win32" or sys.platform == "cygwin": source = False build_script_contents = "# Autogenerated by mibuild\nset -e\n" @@ -148,12 +148,13 @@ xst -ifn {build_name}.xst""" build_script_contents += """ ngdbuild {ngdbuild_opt} -uc {build_name}.ucf {build_name}.{ext} {build_name}.ngd -map -ol high -w -o {build_name}_map.ncd {build_name}.ngd {build_name}.pcf -par -ol high -w {build_name}_map.ncd {build_name}.ncd {build_name}.pcf +map {map_opt} -w -o {build_name}_map.ncd {build_name}.ngd {build_name}.pcf +par {par_opt} -w {build_name}_map.ncd {build_name}.ncd {build_name}.pcf bitgen {bitgen_opt} -w {build_name}.ncd {build_name}.bit """ build_script_contents = build_script_contents.format(build_name=build_name, - ngdbuild_opt=ngdbuild_opt, bitgen_opt=bitgen_opt, ext=ext) + ngdbuild_opt=ngdbuild_opt, bitgen_opt=bitgen_opt, ext=ext, + par_opt=par_opt, map_opt=map_opt) build_script_contents += ise_commands.format(build_name=build_name) build_script_file = "build_" + build_name + ".sh" tools.write_to_file(build_script_file, build_script_contents) @@ -187,6 +188,8 @@ class XilinxISEPlatform(GenericPlatform): -opt_mode SPEED -reduce_control_sets auto -register_balancing yes""" + map_opt = "-ol high" + par_opt = "-ol high" ngdbuild_opt = "" bitgen_opt = "-g LCK_cycle:6 -g Binary:Yes" ise_commands = "" @@ -238,6 +241,7 @@ class XilinxISEPlatform(GenericPlatform): tools.write_to_file(build_name + ".ucf", _build_ucf(named_sc, named_pc)) if run: _run_ise(build_name, ise_path, source, isemode, - ngdbuild_opt, self.bitgen_opt, self.ise_commands) + ngdbuild_opt, self.bitgen_opt, self.ise_commands, + self.map_opt, self.par_opt) os.chdir("..")