mirror of
https://github.com/holub/mame
synced 2025-07-02 00:29:37 +03:00
prune upfront - makes the other stuff cheaper (nw)
This commit is contained in:
parent
daec33cb61
commit
11fa3800f3
@ -165,22 +165,16 @@ void debug_view_memory::enumerate_sources()
|
|||||||
void *base;
|
void *base;
|
||||||
std::string name_string(machine().save().indexed_item(itemnum, base, valsize, valcount));
|
std::string name_string(machine().save().indexed_item(itemnum, base, valsize, valcount));
|
||||||
|
|
||||||
itemnames.emplace_back(std::move(name_string), base, valsize, valcount);
|
// add pretty much anything that's not a timer (we may wish to cull other items later)
|
||||||
|
// also, don't trim the front of the name, it's important to know which VIA6522 we're looking at, e.g.
|
||||||
|
if (strncmp(name_string.c_str(), "timer/", 6))
|
||||||
|
itemnames.emplace_back(std::move(name_string), base, valsize, valcount);
|
||||||
}
|
}
|
||||||
|
|
||||||
std::sort(itemnames.begin(), itemnames.end(), [] (auto const &x, auto const &y) { return std::get<0>(x) < std::get<0>(y); });
|
std::sort(itemnames.begin(), itemnames.end(), [] (auto const &x, auto const &y) { return std::get<0>(x) < std::get<0>(y); });
|
||||||
|
|
||||||
for (auto const &item : itemnames)
|
for (auto const &item : itemnames)
|
||||||
{
|
m_source_list.append(*global_alloc(debug_view_memory_source(std::get<0>(item).c_str(), std::get<1>(item), std::get<2>(item), std::get<3>(item))));
|
||||||
const char *itemname = std::get<0>(item).c_str();
|
|
||||||
|
|
||||||
// add pretty much anything that's not a timer (we may wish to cull other items later)
|
|
||||||
// also, don't trim the front of the name, it's important to know which VIA6522 we're looking at, e.g.
|
|
||||||
if (strncmp(itemname, "timer/", 6))
|
|
||||||
{
|
|
||||||
m_source_list.append(*global_alloc(debug_view_memory_source(itemname, std::get<1>(item), std::get<2>(item), std::get<3>(item))));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// reset the source to a known good entry
|
// reset the source to a known good entry
|
||||||
set_source(*m_source_list.first());
|
set_source(*m_source_list.first());
|
||||||
|
Loading…
Reference in New Issue
Block a user