Skip to content
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

JitArm64/Jit64: Extend the fast lookup mmap-ed segment further to avoid needing to check the msr bits. #12155

Merged
merged 1 commit into from Sep 17, 2023

Conversation

krnlyng
Copy link
Contributor

@krnlyng krnlyng commented Sep 2, 2023

And in order to avoid a double dereference in the dispatcher, directly store the normalEntry in the map.

The index to the block map becomes ((((DR<<1) | IR) << 30) | (address >> 2)). This has been chosen since the msr bits change less often than the address, thus we keep nearby entries together.

Also in the fast lookup table case, do not call the C dispatcher in case the assembly dispatcher didn't find a block, since it wouldn't find a block either due to the 1:1 mapping.

Source/Core/Core/PowerPC/JitArm64/JitAsm.cpp Outdated Show resolved Hide resolved
Source/Core/Core/PowerPC/JitArm64/JitAsm.cpp Outdated Show resolved Hide resolved
Source/Core/Core/PowerPC/JitArm64/JitAsm.cpp Outdated Show resolved Hide resolved
…id needing to check the msr bits.

And in order to avoid a double dereference in the dispatcher, directly store
the normalEntry in the map.

The index to the block map becomes ((((DR<<1) | IR) << 30) | (address >> 2)).
This has been chosen since the msr bits change less often than the address,
thus we keep nearby entries together.

Also do not call the C dispatcher in case the assembly dispatcher didn't
find a block, since it wouldn't find a block either due to the 1:1 mapping,
except when falling back to the non shm segment lookup table.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants