aboutsummaryrefslogtreecommitdiff
path: root/qtmips_gui/programmodel.h
diff options
context:
space:
mode:
authorPavel Pisa <pisa@cmp.felk.cvut.cz>2019-03-25 23:13:31 +0100
committerPavel Pisa <pisa@cmp.felk.cvut.cz>2019-03-25 23:54:51 +0100
commit635567e0564db4d19741b2478a4129fccb76f64a (patch)
treeb358007ad61d4cc1ae889e851c220ab892f377bf /qtmips_gui/programmodel.h
parent50361206f7fdccc911ae9dc8095f6304fcb9bc95 (diff)
downloadqtmips-635567e0564db4d19741b2478a4129fccb76f64a.tar.gz
qtmips-635567e0564db4d19741b2478a4129fccb76f64a.tar.bz2
qtmips-635567e0564db4d19741b2478a4129fccb76f64a.zip
Highlight instructions passing through the pipeline stages.
Signed-off-by: Pavel Pisa <pisa@cmp.felk.cvut.cz>
Diffstat (limited to 'qtmips_gui/programmodel.h')
-rw-r--r--qtmips_gui/programmodel.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/qtmips_gui/programmodel.h b/qtmips_gui/programmodel.h
index f5159af..a7c1699 100644
--- a/qtmips_gui/programmodel.h
+++ b/qtmips_gui/programmodel.h
@@ -84,10 +84,20 @@ public:
return true;
}
+ enum StageAddress {
+ STAGEADDR_FETCH,
+ STAGEADDR_DECODE,
+ STAGEADDR_EXECUTE,
+ STAGEADDR_MEMORY,
+ STAGEADDR_WRITEBACK,
+ STAGEADDR_COUNT,
+ };
+
public slots:
void setup(machine::QtMipsMachine *machine);
void check_for_updates();
void toggle_hw_break(const QModelIndex & index);
+ void update_stage_addr(uint stage, std::uint32_t addr);
private:
std::uint32_t index0_offset;
@@ -95,6 +105,8 @@ private:
machine::QtMipsMachine *machine;
std::uint32_t memory_change_counter;
std::uint32_t cache_program_change_counter;
+ std::uint32_t stage_addr[STAGEADDR_COUNT];
+ bool stages_need_update;
};
#endif // PROGRAMMODEL_H