Implement syscall 0x83 (FindAddress) with kernel tests#93
Merged
ran-j merged 1 commit intoran-j:mainfrom Mar 6, 2026
Merged
Conversation
ran-j
requested changes
Mar 4, 2026
| // - a1: table end (exclusive) | ||
| // - a2: target address to locate inside the table (word entries) | ||
| // Returns the guest address of the matching word entry, or 0 if not found. | ||
| void FindAddress(uint8_t *rdram, R5900Context *ctx, PS2Runtime *runtime) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR implements numeric syscall
0x83(FindAddress) in the runtime kernel syscall dispatcher and adds proper tests. This emerged due to issue #90Changes
ps2xRuntime/src/lib/ps2_syscalls.cppcase 0x83: FindAddress(...)ps2xRuntime/src/lib/syscalls/ps2_syscalls_system.inlFindAddress:a0=start,a1=end(exclusive),a2=targetv00if not foundaddr & 0x1FFFFFFF) for stronger match behaviorps2xTest/src/ps2_runtime_kernel_tests.cppWhy this shape
__NR_FindAddress = 0x83).(start, end, symbol)and requirev0as an address.Out of scope
0x74mapping/semantics (SetSyscallvs current runtime mapping) is intentionally not changed here and will be handled in a separate PR.