aboutsummaryrefslogtreecommitdiff
path: root/qtmips_machine/core.h
diff options
context:
space:
mode:
authorKarel Kočí <cynerd@email.cz>2018-01-15 13:17:07 +0100
committerKarel Kočí <cynerd@email.cz>2018-01-15 13:17:07 +0100
commit1f6cf37d350f01b15be9ca2d2ceec034d87e09b5 (patch)
treec6582214bd9265b4e9146603848469596a83cc73 /qtmips_machine/core.h
parente1b4028d0feb045abf4dd413d5e3bb80269c84b7 (diff)
downloadqtmips-1f6cf37d350f01b15be9ca2d2ceec034d87e09b5.tar.gz
qtmips-1f6cf37d350f01b15be9ca2d2ceec034d87e09b5.tar.bz2
qtmips-1f6cf37d350f01b15be9ca2d2ceec034d87e09b5.zip
Implement hazard unit
Diffstat (limited to 'qtmips_machine/core.h')
-rw-r--r--qtmips_machine/core.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/qtmips_machine/core.h b/qtmips_machine/core.h
index 3078c95..3ff6a98 100644
--- a/qtmips_machine/core.h
+++ b/qtmips_machine/core.h
@@ -3,6 +3,7 @@
#include <QObject>
#include <qtmipsexception.h>
+#include <machineconfig.h>
#include <registers.h>
#include <memory.h>
#include <instruction.h>
@@ -91,7 +92,7 @@ private:
class CorePipelined : public Core {
public:
- CorePipelined(Registers *regs, MemoryAccess *mem);
+ CorePipelined(Registers *regs, MemoryAccess *mem, enum MachineConfig::HazardUnit hazard_unit = MachineConfig::HU_STALL_FORWARD);
void step();
@@ -102,6 +103,8 @@ private:
struct Core::dtDecode dt_d;
struct Core::dtExecute dt_e;
struct Core::dtMemory dt_m;
+
+ enum MachineConfig::HazardUnit hazard_unit;
};
}