-
Notifications
You must be signed in to change notification settings - Fork 571
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
ASSERT FAILURE: .../raw2trace.cpp:3056: *pc - desc->pc_ == instr_length(dcontext, instr) () #7132
Comments
If it has the wrong ISA mode then it's going to get everything else wrong. No, please do not remove the assert. Sounds like there's a bug in setting the mode somewhere. |
I'm not talking about the two ISA modes: there are multiple Thumb encodings for LDR (immediate). |
Just to get tests passing, do you think we could do something like the following?
|
OK. |
egrimley-arm
added a commit
that referenced
this issue
Jan 13, 2025
Until i#4016 is fixed, on 32-bit ARM a 4-byte T32 instruction may turn into a 2-byte instruction when decoded and then reencoded. Fixes: #7132 Change-Id: I342656a833b3221848897d0516705a359552bc39
egrimley-arm
added a commit
that referenced
this issue
Jan 13, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Reproduce like this on a 32-bit Arm system:
Get:
It appears that
DEBUG_ASSERT(*pc - desc->pc_ == instr_length(dcontext, instr))
incorrectly assumes that the instruction will be encoded in a particular way. Some Thumb instructions have both a 2-byte and a 4-byte encoding, and the 4-byte encoding seems to be used instead of an alternative 2-byte encoding in the C library code that comes with Debian 10 so you might be able to reproduce this with ana.out
built fromint main() { return 0; }
; I could.The fix is to delete that line with that
DEBUG_ASSERT
?The text was updated successfully, but these errors were encountered: