New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ID manager refactoring #1172
ID manager refactoring #1172
Conversation
b93411f
to
8b412e8
Compare
d03ab83
to
b06b0fa
Compare
@Nekotekina Could you look into implementing support for structs in callbacks? Since cellSail callbacks are required to pass a struct that contains the info about why the callback was called, etc. Passing a pointer or reference doesn't work. |
C++ doesn't support reflection so you can't do much about such structs passed by value. Fortunately, it's rare. The only option is to decompose them manually according to their fields' displacement in GPRs, FPRs, VPRs registers and the stack. Here is a partial solution to cover CellSailEvent specific case: union CellSailEvent
{
be_t<u64> value;
struct _data_t
{
be_t<u32> major;
be_t<u32> minor;
};
};
template<typename T, bool is_enum> struct cast_ppu_gpr;
template<> struct cast_ppu_gpr<CellSailEvent, false>
{
force_inline static u64 to_gpr(const CellSailEvent& event)
{
return event.value;
}
}; |
@Nekotekina are you still having trouble with irc? Have you tried something like https://kiwiirc.com/? It should work. |
@Nekotekina Thank you very much, it works great. |
da9ac7f
to
b87e4d5
Compare
@Nekotekina Not sure about other commands, but it would seem that socket() in libnet is broken on your branch compared to latest master. Couple games that use it are: Terraria and Puzzle Quest. My guess is, that Nekotekina@b1c5ff5 somehow broke it, but I'm not sure. |
I didn't finish TLS allocator for sys_net and some other things yet. |
Fixed UB in get_current_id()
ID manager refactoring, redundant "type" information removed
Since it's vector union type
Used ARMv7Thread instead of ARMv7Context in PSV HLE functions and callbacks. However, interpreter still uses ARMv7Context. Various PSV functions partially implemented: sceKernelCreateEventFlag sceKernelDeleteEventFlag sceKernelOpenEventFlag sceKernelCloseEventFlag sceKernelWaitEventFlag sceKernelWaitEventFlagCB sceKernelPollEventFlag sceKernelSetEventFlag sceKernelClearEventFlag sceKernelCancelEventFlag sceKernelGetEventFlagInfo sceKernelCreateSema sceKernelDeleteSema sceKernelCreateMutex sceKernelDeleteMutex sceKernelCreateCond sceKernelDeleteCond
VFS::DeleteAll, VFS::GetDirSize, VFS::Exists, VFS::Rename (VFS::RenameFile, VFS::RenameDir removed)
id_traits for file/dir descriptors idm::get_current_id() removed, thread-local last ID
Method ptr for vm::ptr (renamed "of") Method ref for vm::ptr (returns vm::ref) Operator & for vm::ref (returns vm::ptr)
thread_t renamed to named_thread_t
New functionality added ("fixed ID"). Allows to avoid some global variables.
Some functions also added which should have been in my previous PR.