global interrupt_to_fire seems not to be Bochs-specific at the moment

FIXME: This shouldn't be a global variable (probably a SimulatorController
member?).  Reconsider interrupt generation being part of the generic
interface.

git-svn-id: https://www4.informatik.uni-erlangen.de/i4svn/danceos/trunk/devel/fail@1612 8c4709b5-6ec9-48aa-a5cd-a96041d1645a
This commit is contained in:
hsc
2012-09-11 17:10:11 +00:00
parent 4f18dd945e
commit 2fed94ae49
6 changed files with 5 additions and 6 deletions

View File

@ -6,6 +6,8 @@ namespace fail {
// External reference declared in SALInst.hpp
ConcreteSimulatorController simulator;
// FIXME: Bochs specific? If not, at least get rid of this global variable.
int interrupt_to_fire = -1;
bool SimulatorController::addListener(BaseListener* li)
{

View File

@ -229,6 +229,9 @@ public:
unsigned getListenerCount() const { return m_LstList.getListenerCount(); }
};
// FIXME (see SimulatorController.cc): Weird, homeless global variable
extern int interrupt_to_fire;
} // end-of-namespace: fail
#endif // __SIMULATOR_CONTROLLER_HPP__

View File

@ -16,7 +16,6 @@ std::string sr_path = "";
bx_bool reboot_bochs_request = false;
bx_bool interrupt_injection_request = false;
int interrupt_to_fire = -1;
BochsController::BochsController()
: SimulatorController(new BochsRegisterManager(), new BochsMemoryManager()),

View File

@ -15,7 +15,6 @@ namespace fail {
extern bx_bool reboot_bochs_request;
extern bx_bool interrupt_injection_request;
extern int interrupt_to_fire;
} // end-of-namespace: fail

View File

@ -8,8 +8,6 @@
namespace fail {
int interrupt_to_fire = -1;
void Gem5Controller::save(const std::string &path)
{
// Takes a snapshot in the m5out dir

View File

@ -7,8 +7,6 @@
namespace fail {
extern int interrupt_to_fire;
class Gem5Controller : public SimulatorController {
public:
void onBreakpoint(address_t instrPtr, address_t address_space);