From 9570dae514462f4a823e54de11e6dc86587de1b7 Mon Sep 17 00:00:00 2001 From: Mitchell Johnson Date: Sun, 4 Sep 2022 19:49:46 -0400 Subject: Fix 32-bit conditional thumb branches Correct the shift used to select condition bits and correctly compute the branch offset. --- tests/armv7/thumb.rs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'tests/armv7') diff --git a/tests/armv7/thumb.rs b/tests/armv7/thumb.rs index dc912a6..8e1796d 100644 --- a/tests/armv7/thumb.rs +++ b/tests/armv7/thumb.rs @@ -738,6 +738,10 @@ fn test_decode_32b_branch_cases() { &[0x0c, 0xf0, 0x84, 0xb9], "b.w $+0xc308" ); + test_display( + &[0x3f, 0xf4, 0xfe, 0xaf], + "b.weq $-0x4" + ); } #[test] fn test_decode_bkpt_cases() { -- cgit v1.1