aboutsummaryrefslogtreecommitdiff
path: root/qtmips_gui
diff options
context:
space:
mode:
authorKarel Kočí <cynerd@email.cz>2018-04-15 13:56:43 +0200
committerKarel Kočí <cynerd@email.cz>2018-04-15 13:56:43 +0200
commit8211b172579aac12a07afbddd5bed12e3b1cd83b (patch)
tree29d7385b2f4060cf55bee75ebb8f696f945157d4 /qtmips_gui
parent3ce0bbb92731f67aa09b20cd21208505daea5e6b (diff)
downloadqtmips-8211b172579aac12a07afbddd5bed12e3b1cd83b.tar.gz
qtmips-8211b172579aac12a07afbddd5bed12e3b1cd83b.tar.bz2
qtmips-8211b172579aac12a07afbddd5bed12e3b1cd83b.zip
Change presets
Diffstat (limited to 'qtmips_gui')
-rw-r--r--qtmips_gui/NewDialog.ui8
-rw-r--r--qtmips_gui/newdialog.cpp16
2 files changed, 12 insertions, 12 deletions
diff --git a/qtmips_gui/NewDialog.ui b/qtmips_gui/NewDialog.ui
index 3c1eaba..135ac83 100644
--- a/qtmips_gui/NewDialog.ui
+++ b/qtmips_gui/NewDialog.ui
@@ -50,16 +50,16 @@
</widget>
</item>
<item>
- <widget class="QRadioButton" name="preset_pipelined_bare">
+ <widget class="QRadioButton" name="preset_no_pipeline_cache">
<property name="text">
- <string>Pipelined without hazard unit and without cache</string>
+ <string>No pipeline with cache</string>
</property>
</widget>
</item>
<item>
- <widget class="QRadioButton" name="preset_pipelined_hazard">
+ <widget class="QRadioButton" name="preset_pipelined_bare">
<property name="text">
- <string>Pipelined with hazard unit and without cache</string>
+ <string>Pipelined without hazard unit and without cache</string>
</property>
</widget>
</item>
diff --git a/qtmips_gui/newdialog.cpp b/qtmips_gui/newdialog.cpp
index ee957cb..565d353 100644
--- a/qtmips_gui/newdialog.cpp
+++ b/qtmips_gui/newdialog.cpp
@@ -21,8 +21,8 @@ NewDialog::NewDialog(QWidget *parent, QSettings *settings) : QDialog(parent) {
connect(ui->pushButton_cancel, SIGNAL(clicked(bool)), this, SLOT(cancel()));
connect(ui->pushButton_browse, SIGNAL(clicked(bool)), this, SLOT(browse_elf()));
connect(ui->preset_no_pipeline, SIGNAL(toggled(bool)), this, SLOT(set_preset()));
+ connect(ui->preset_no_pipeline_cache, SIGNAL(toggled(bool)), this, SLOT(set_preset()));
connect(ui->preset_pipelined_bare, SIGNAL(toggled(bool)), this, SLOT(set_preset()));
- connect(ui->preset_pipelined_hazard, SIGNAL(toggled(bool)), this, SLOT(set_preset()));
connect(ui->preset_pipelined, SIGNAL(toggled(bool)), this, SLOT(set_preset()));
connect(ui->pipelined, SIGNAL(clicked(bool)), this, SLOT(pipelined_change(bool)));
@@ -159,12 +159,12 @@ unsigned NewDialog::preset_number() {
enum machine::ConfigPresets preset;
if (ui->preset_no_pipeline->isChecked())
preset = machine::CP_SINGLE;
+ else if (ui->preset_no_pipeline_cache->isChecked())
+ preset = machine::CP_SINGLE_CACHE;
else if (ui->preset_pipelined_bare->isChecked())
preset = machine::CP_PIPE_NO_HAZARD;
- else if (ui->preset_pipelined_hazard->isChecked())
- preset = machine::CP_PIPE_NO_CACHE;
else if (ui->preset_pipelined->isChecked())
- preset = machine::CP_PIPE_CACHE;
+ preset = machine::CP_PIPE;
else
return 0;
return (unsigned)preset + 1;
@@ -188,13 +188,13 @@ void NewDialog::load_settings() {
case machine::CP_SINGLE:
ui->preset_no_pipeline->setChecked(true);
break;
+ case machine::CP_SINGLE_CACHE:
+ ui->preset_no_pipeline_cache->setChecked(true);
+ break;
case machine::CP_PIPE_NO_HAZARD:
ui->preset_pipelined_bare->setChecked(true);
break;
- case machine::CP_PIPE_NO_CACHE:
- ui->preset_pipelined_hazard->setChecked(true);
- break;
- case machine::CP_PIPE_CACHE:
+ case machine::CP_PIPE:
ui->preset_pipelined->setChecked(true);
break;
}