Skip to content
Snippets Groups Projects
Commit 2fed94ae authored by Horst Schirmeier's avatar Horst Schirmeier
Browse files

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
parent 4f18dd94
No related branches found
No related tags found
No related merge requests found
...@@ -6,6 +6,8 @@ namespace fail { ...@@ -6,6 +6,8 @@ namespace fail {
// External reference declared in SALInst.hpp // External reference declared in SALInst.hpp
ConcreteSimulatorController simulator; 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) bool SimulatorController::addListener(BaseListener* li)
{ {
......
...@@ -229,6 +229,9 @@ public: ...@@ -229,6 +229,9 @@ public:
unsigned getListenerCount() const { return m_LstList.getListenerCount(); } unsigned getListenerCount() const { return m_LstList.getListenerCount(); }
}; };
// FIXME (see SimulatorController.cc): Weird, homeless global variable
extern int interrupt_to_fire;
} // end-of-namespace: fail } // end-of-namespace: fail
#endif // __SIMULATOR_CONTROLLER_HPP__ #endif // __SIMULATOR_CONTROLLER_HPP__
...@@ -16,7 +16,6 @@ std::string sr_path = ""; ...@@ -16,7 +16,6 @@ std::string sr_path = "";
bx_bool reboot_bochs_request = false; bx_bool reboot_bochs_request = false;
bx_bool interrupt_injection_request = false; bx_bool interrupt_injection_request = false;
int interrupt_to_fire = -1;
BochsController::BochsController() BochsController::BochsController()
: SimulatorController(new BochsRegisterManager(), new BochsMemoryManager()), : SimulatorController(new BochsRegisterManager(), new BochsMemoryManager()),
......
...@@ -15,7 +15,6 @@ namespace fail { ...@@ -15,7 +15,6 @@ namespace fail {
extern bx_bool reboot_bochs_request; extern bx_bool reboot_bochs_request;
extern bx_bool interrupt_injection_request; extern bx_bool interrupt_injection_request;
extern int interrupt_to_fire;
} // end-of-namespace: fail } // end-of-namespace: fail
......
...@@ -8,8 +8,6 @@ ...@@ -8,8 +8,6 @@
namespace fail { namespace fail {
int interrupt_to_fire = -1;
void Gem5Controller::save(const std::string &path) void Gem5Controller::save(const std::string &path)
{ {
// Takes a snapshot in the m5out dir // Takes a snapshot in the m5out dir
......
...@@ -7,8 +7,6 @@ ...@@ -7,8 +7,6 @@
namespace fail { namespace fail {
extern int interrupt_to_fire;
class Gem5Controller : public SimulatorController { class Gem5Controller : public SimulatorController {
public: public:
void onBreakpoint(address_t instrPtr, address_t address_space); void onBreakpoint(address_t instrPtr, address_t address_space);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment