mirror of
https://github.com/enjoy-digital/litex.git
synced 2025-01-04 09:52:26 -05:00
Merge pull request #948 from developandplay/non-interactive
Expose non-interactive mode
This commit is contained in:
commit
e7d04a2d1b
2 changed files with 6 additions and 3 deletions
|
@ -189,7 +189,8 @@ class SimVerilatorToolchain:
|
|||
trace_fst = False,
|
||||
trace_start = 0,
|
||||
trace_end = -1,
|
||||
regular_comb = False):
|
||||
regular_comb = False,
|
||||
interactive = True):
|
||||
|
||||
# Create build directory
|
||||
os.makedirs(build_dir, exist_ok=True)
|
||||
|
@ -238,7 +239,7 @@ class SimVerilatorToolchain:
|
|||
run_as_root = True
|
||||
if sim_config.has_module("xgmii_ethernet"):
|
||||
run_as_root = True
|
||||
_run_sim(build_name, as_root=run_as_root)
|
||||
_run_sim(build_name, as_root=run_as_root, interactive=interactive)
|
||||
|
||||
os.chdir(cwd)
|
||||
|
||||
|
|
|
@ -374,6 +374,7 @@ def sim_args(parser):
|
|||
parser.add_argument("--opt-level", default="O3", help="Compilation optimization level")
|
||||
parser.add_argument("--sim-debug", action="store_true", help="Add simulation debugging modules")
|
||||
parser.add_argument("--gtkwave-savefile", action="store_true", help="Generate GTKWave savefile")
|
||||
parser.add_argument("--non-interactive", action="store_true", help="Run simulation without user input")
|
||||
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(description="Generic LiteX SoC Simulation")
|
||||
|
@ -452,7 +453,8 @@ def main():
|
|||
trace = args.trace,
|
||||
trace_fst = args.trace_fst,
|
||||
trace_start = trace_start,
|
||||
trace_end = trace_end
|
||||
trace_end = trace_end,
|
||||
interactive = not args.non_interactive
|
||||
)
|
||||
if args.with_analyzer:
|
||||
soc.analyzer.export_csv(vns, "analyzer.csv")
|
||||
|
|
Loading…
Reference in a new issue