From c39552375661e495b344e8386649ade92a4d45b2 Mon Sep 17 00:00:00 2001 From: Alejandro Soto Date: Wed, 7 Dec 2022 19:18:04 -0600 Subject: Implement single-stepping --- sim/sim.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'sim/sim.py') diff --git a/sim/sim.py b/sim/sim.py index 16ceb54..be846fb 100755 --- a/sim/sim.py +++ b/sim/sim.py @@ -343,11 +343,12 @@ while True: else: break + mode = None halted = True if halt: - halt() + mode = halt() - print('continue', file=sim_end, flush=True) + print('step' if mode == 'step' else 'continue', file=sim_end, flush=True) if not halt: break -- cgit v1.2.3