From: Nathan Binkert Date: Thu, 30 Jun 2005 02:20:38 +0000 (-0400) Subject: Easier remote debugging at boot time. X-Git-Tag: m5_1.1~48^2~8 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ec1f689d0db9e1839e1b5a8f67f12d19f56c85e3;p=gem5.git Easier remote debugging at boot time. sim/system.cc: Add a global variable that will tell the remote debugger to wait when a given CPU is is registered. --HG-- extra : convert_revision : a093c9331daa675d4b59a321e53a5da6ea292c40 --- diff --git a/sim/system.cc b/sim/system.cc index 6f7d53f6b..47ffc4b01 100644 --- a/sim/system.cc +++ b/sim/system.cc @@ -203,6 +203,8 @@ System::breakpoint() return remoteGDB[0]->trap(ALPHA_KENTRY_INT); } +int rgdb_wait = -1; + int System::registerExecContext(ExecContext *xc, int id) { @@ -229,7 +231,8 @@ System::registerExecContext(ExecContext *xc, int id) * Uncommenting this line waits for a remote debugger to connect * to the simulator before continuing. */ - //gdbl->accept(); + if (rgdb_wait != -1 && rgdb_wait == id) + gdbl->accept(); if (remoteGDB.size() <= id) { remoteGDB.resize(id + 1);