a byte (size 0, 1 signed) or halfword (2, 3 signed) of a word, at its address's place in the word
function SubwordOffset(address : bits(32), size : int) -> bits(32) =
(address & (if size < 2 then 0x00000003 else 0x00000002)) << 3Made from ScarletNX's Sail at 166ad3910f80. The Sail and the encodings' file are ScarletNX's (GPL-3.0-or-later); its encodings are from Eden's maxwell.inc (GPL-2.0-or-later).