fixed bit field field the encoding fixes should be
| 15 | 14 | 13 | 12 | 11 | 10 | 9 | 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 |
| 1 | 1 | 1 | 1 | 0 | |||||||||||
11110xxxxxxxxxxx
ArchVersion() < 7
ScarletNX's fixup: Thumb's BL and BLX before Thumb-2 (ArchVersion() < 7: the ARM7TDMI, the ARM946E-S, the ARM11) are two 16-bit instructions, each one run alone (a game calls through LR into a suffix), as the ARMv5 ARM's pseudocode has them: the prefix (11110) puts the PC plus the high offset, sign extended, in LR; a suffix branches to LR plus its offset, and leaves the address after it in LR with bit 0 set: BL's (11111) stays in Thumb, BLX's (11101, from ARMv5, the offset's bit 0 clear) goes to A32 at a word. Thumb-2 made the pair one 32-bit instruction, which is sail-arm's
if ConditionPassed() then {
R_set(14) = PC_read__1() + SignExtend(offset @ Zeros(12), 32)
};
()
Made from ScarletNX's Sail at 166ad3910f80. sail-arm's definitions are Arm's ASL in Sail (BSD 3-Clause Clear, license); ScarletNX's fixups are GPL-3.0-or-later.