An UNPREDICTABLE encoding (sail-arm's throw of Error_Unpredictable, which sailgen walks as UnpredictableEncoding()) runs as it is written: a high-register CMP or ADD of two low registers, a write of the PC inside an IT block, an empty PUSH or POP's transfer of nothing (an empty LDM's or STM's is above). Old toolchains and hand-written code leave such forms in games, and the guests' cores run them so. The 3DS's ARM11 (ArchVersion() 6) refuses them: they are UNDEFINED there, as its profile has always decoded them (profile.c); and so is every A32 one, on every guest, as the A32 decoder has always had them (a32.decode: a PC operand of a register-shifted register, ...)
val UnpredictableEncoding : unit -> unit
function UnpredictableEncoding () = if ArchVersion() == 6 | CurrentInstrSet() == InstrSet_A32 then
throw(Error_Undefined())
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.