Fix AArch64 register-offset load/store memory operand access (#2802)#2929
Merged
Conversation
52abc77 to
f81bb13
Compare
Rot127
requested changes
May 22, 2026
Collaborator
Rot127
left a comment
There was a problem hiding this comment.
lgtm. Please add the two tests and we are good to go.
…e-engine#2802) The auto-generated mapping for AArch64 register-offset addressing mode (roW/roX) load, store, and prefetch instructions incorrectly had CS_AC_INVALID for the memory operand access. For example, LDRSW with register offset (ldrsw x10, [x22, x10, lsl capstone-engine#2]) had no access type set on the memory operand, when it should be CS_AC_READ. Fix this by: - Correcting the entries directly in AArch64GenCSMappingInsn.inc - Adding an inc_patches entry so the fix is reapplied on regeneration - Adding a test case for LDRSW with register offset Affected instructions: - Loads (CS_AC_READ): LDR, LDRB, LDRH, LDRSB, LDRSH, LDRSW (roW/roX) - Stores (CS_AC_WRITE): STR, STRB, STRH, STRD (roW/roX) - Prefetch (CS_AC_READ): PRFM (roW/roX) Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
Rot127
approved these changes
May 22, 2026
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.
Fix issue #2802 where AArch64 load and store instructions with register-offset addressing modes were not correctly marking memory operands with READ/WRITE access type. Closes #2802