mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-07 23:45:12 +00:00
kernel-explorer: Show bound queue to port information
Show its IPC key or ID, depends on the queue's type.
This commit is contained in:
parent
c7b5bbd467
commit
72c85744b9
3 changed files with 29 additions and 3 deletions
|
|
@ -7,6 +7,7 @@
|
|||
#include <QTreeWidgetItem>
|
||||
|
||||
#include "Emu/IdManager.h"
|
||||
#include "Emu/IPC.h"
|
||||
#include "Emu/Cell/PPUThread.h"
|
||||
#include "Emu/Cell/SPUThread.h"
|
||||
#include "Emu/Cell/lv2/sys_lwmutex.h"
|
||||
|
|
@ -360,7 +361,29 @@ void kernel_explorer::Update()
|
|||
case SYS_EVENT_PORT_OBJECT:
|
||||
{
|
||||
auto& ep = static_cast<lv2_event_port&>(obj);
|
||||
add_leaf(node, qstr(fmt::format("Event Port 0x%08x: Name: %#llx, Bound: %s", id, ep.name, lv2_event_queue::check(ep.queue))));
|
||||
const auto queue = ep.queue.lock();
|
||||
const auto type = ep.type == SYS_EVENT_PORT_LOCAL ? "LOCAL"sv : "IPC"sv;
|
||||
|
||||
if (lv2_event_queue::check(queue))
|
||||
{
|
||||
if (queue.get() == idm::check_unlocked<lv2_obj, lv2_event_queue>(ep.queue_id));
|
||||
{
|
||||
// Type must be LOCAL here, but refer to the note below for why it is showed
|
||||
add_leaf(node, qstr(fmt::format("Event Port 0x%08x: %s, Name: %#llx, Event Queue (ID): 0x%08x", id, type, ep.name, ep.queue_id)));
|
||||
break;
|
||||
}
|
||||
|
||||
if (queue == lv2_event_queue::find(queue->key))
|
||||
{
|
||||
// There are cases in which the attached queue by ID also has an IPC
|
||||
// And the ID was destroyed but another was created for that same IPC
|
||||
// So show event port type as well here because it not guaranteed to be IPC
|
||||
add_leaf(node, qstr(fmt::format("Event Port 0x%08x: %s, Name: %#llx, Event Queue (IPC): %s", id, type, ep.name, queue->key)));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
add_leaf(node, qstr(fmt::format("Event Port 0x%08x: %s, Name: %#llx, Unbound", id, type, ep.name)));
|
||||
break;
|
||||
}
|
||||
case SYS_TRACE_OBJECT:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue