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

ARM ldrsh parameter failure #238

Open
KarisaAdvynia opened this issue Jun 1, 2023 · 0 comments
Open

ARM ldrsh parameter failure #238

KarisaAdvynia opened this issue Jun 1, 2023 · 0 comments

Comments

@KarisaAdvynia
Copy link

The ARM instruction ldrsh fails to assemble, when an offset is added after loading from a register:

ldrsh r3,[r0],2   ; expected: F2 30 D0 E0
ldrsh r3,[r0],-2  ; expected: F2 30 50 E0
ldrsh r3,[r0],r2  ; expected: F2 30 90 E0
                  ; instead: "ldrsh-test.asm(5) error: ARM parameter failure"

The error occurs on any target ARM architecture (.gba .arm, .nds, or .3ds)

I've tested other closely related instructions, and they are successfully assembled:

ldrh r3,[r0],2    ; output: B2 30 D0 E0
ldrsb r3,[r0],2   ; output: D2 30 D0 E0
ldrsh r3,[r0,2]   ; output: F2 30 D0 E1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant