From 8ec0e8c02d1b1db0112c8564888f2d8dd88cbe15 Mon Sep 17 00:00:00 2001 From: Tim Newsome Date: Tue, 18 Jul 2017 11:35:59 -0700 Subject: [PATCH] Check all PCs after reset. --- debug/gdbserver.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/debug/gdbserver.py b/debug/gdbserver.py index 5ac0153..f6c61c3 100755 --- a/debug/gdbserver.py +++ b/debug/gdbserver.py @@ -208,7 +208,13 @@ class InstantHaltTest(GdbTest): """Assert that reset is really resetting what it should.""" self.gdb.command("monitor reset halt") self.gdb.command("flushregs") - assertEqual(self.target.reset_vector, self.gdb.p("$pc")) + threads = self.gdb.threads() + pcs = [] + for t in threads: + self.gdb.thread(t) + pcs.append(self.gdb.p("$pc")) + for pc in pcs: + assertEqual(self.target.reset_vector, pc) # mcycle and minstret have no defined reset value. mstatus = self.gdb.p("$mstatus") assertEqual(mstatus & (MSTATUS_MIE | MSTATUS_MPRV | -- 2.30.2