diff options
author | bd <bdunahu@operationnull.com> | 2025-04-26 23:49:35 -0400 |
---|---|---|
committer | bd <bdunahu@operationnull.com> | 2025-04-26 23:49:35 -0400 |
commit | 270d5c95c46385b7f8c3ad5ffd1adb4ac5a43acb (patch) | |
tree | 49ac24e66f02c2d7ceb589d28c5fab593059d0c4 /gui/gui.cc | |
parent | d449750f789076459de8d47c2960a1279e543c32 (diff) |
Fix bug which caused a very large allocation
Diffstat (limited to 'gui/gui.cc')
-rw-r--r-- | gui/gui.cc | 9 |
1 files changed, 3 insertions, 6 deletions
@@ -358,16 +358,13 @@ void GUI::make_tabs(int num) e = new StorageView(0, this); } else if (i == num - 1) { n = "DRAM"; - e = new StorageView(4, this); + e = new StorageView(MEM_LINES, this); } else { n = QString("L%1").arg(i); e = new StorageView( - // cache_size_mapper(this->curr_cache_levels-1, i-1) - 4, this); + (1 << cache_size_mapper(this->curr_cache_levels - 1, i - 1)), + this); } - std::cout << "total levels: " << num << ":" - << this->curr_cache_levels - 1 << " level: " << i - << std::endl; t = new QTableView(ui->storage); t->setModel(e); |