Limit number of jobs for verilator

This commit is contained in:
Byron Lathi
2025-02-25 08:09:11 -08:00
parent 75184afd8f
commit 934160d619
2 changed files with 6 additions and 2 deletions

View File

@@ -35,7 +35,7 @@ name = "fpga-sim" # REQUIRED, is the only field that cannot be marked as dynami
# https://packaging.python.org/guides/single-sourcing-package-version/
# dynamic = ["version"]
version = "0.2.1" # REQUIRED, although can be dynamic
version = "0.2.2" # REQUIRED, although can be dynamic
# This is a one-line description or tagline of what your project does. This
# corresponds to the "Summary" metadata field:

View File

@@ -22,6 +22,7 @@ def fpga_sim_main():
parser.add_argument("yaml")
parser.add_argument("test_name", nargs="?")
parser.add_argument("-j", "--jobs", default=1)
args = parser.parse_args()
@@ -78,7 +79,9 @@ def fpga_sim_main():
sim = os.getenv("SIM", "verilator")
runner = get_runner(sim)
os.environ["MAKEFLAGS"] = "-j"
jobs = args.jobs
print(jobs)
os.environ["MAKEFLAGS"] = f"-j{jobs}"
tests_to_run = []
@@ -107,3 +110,4 @@ def fpga_sim_main():
sys.path.append(test["base_path"])
runner.test(hdl_toplevel=test["toplevel"], test_module=test["modules"], waves=test["waves"], results_xml=result_xml)