Data processing (scalar floating-point and Advanced SIMD)
fixed bit field field the encoding fixes should be
| 31 | 30 | 29 | 28 | 27 | 26 | 25 | 24 | 23 | 22 | 21 | 20 | 19 | 18 | 17 | 16 | 15 | 14 | 13 | 12 | 11 | 10 | 9 | 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 |
| 0 | Q | 0 | 0 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | a | b | c | 1 | 1 | 1 | 1 | 1 | 1 | d | e | f | g | h | Rd | ||||
0x00111100000xxx111111xxxxxxxxxx
if not_bool(HaveFP16Ext()) then {
throw(Error_Undefined())
};
let 'rd = UInt(Rd);
let 'datasize = if Q == 0b1 then 128 else 64;
let imm8 : bits(8) = ((((((a @ b) @ c) @ d) @ e) @ f) @ g) @ h;
let imm16 : bits(16) = ((([imm8[7]] @ not_vec([imm8[6]])) @ Replicate([imm8[6]], 2)) @ imm8[5 .. 0]) @ Zeros(6);
let imm : bits('datasize) = Replicate(imm16, DIV(datasize, 16));
execute_aarch64_instrs_vector_fp16_movi(datasize, imm, rd)
| 31 | 30 | 29 | 28 | 27 | 26 | 25 | 24 | 23 | 22 | 21 | 20 | 19 | 18 | 17 | 16 | 15 | 14 | 13 | 12 | 11 | 10 | 9 | 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 |
| 0 | Q | op | 0 | 1 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | a | b | c | 1 | 1 | 1 | 1 | 0 | 1 | d | e | f | g | h | Rd | ||||
| cmode | |||||||||||||||||||||||||||||||
0xx0111100000xxx111101xxxxxxxxxx
let 'rd = UInt(Rd);
let 'datasize = if Q == 0b1 then 128 else 64;
operation : ImmediateOp = undefined;
match cmode @ op {
[bitzero, _, _, bitzero, bitzero] => {
operation = ImmediateOp_MOVI
},
[bitzero, _, _, bitzero, bitone] => {
operation = ImmediateOp_MVNI
},
[bitzero, _, _, bitone, bitzero] => {
operation = ImmediateOp_ORR
},
[bitzero, _, _, bitone, bitone] => {
operation = ImmediateOp_BIC
},
[bitone, bitzero, _, bitzero, bitzero] => {
operation = ImmediateOp_MOVI
},
[bitone, bitzero, _, bitzero, bitone] => {
operation = ImmediateOp_MVNI
},
[bitone, bitzero, _, bitone, bitzero] => {
operation = ImmediateOp_ORR
},
[bitone, bitzero, _, bitone, bitone] => {
operation = ImmediateOp_BIC
},
[bitone, bitone, bitzero, _, bitzero] => {
operation = ImmediateOp_MOVI
},
[bitone, bitone, bitzero, _, bitone] => {
operation = ImmediateOp_MVNI
},
[bitone, bitone, bitone, bitzero, _] => {
operation = ImmediateOp_MOVI
},
0b11110 => {
operation = ImmediateOp_MOVI
},
0b11111 => {
if Q == 0b0 then {
throw(Error_Undefined())
};
operation = ImmediateOp_MOVI
}
};
let operation = operation;
let imm64 : bits(64) = AdvSIMDExpandImm(op, cmode, ((((((a @ b) @ c) @ d) @ e) @ f) @ g) @ h);
let imm : bits('datasize) = Replicate(imm64, DIV(datasize, 64));
execute_aarch64_instrs_vector_fp16_movi(datasize, imm, rd)
CheckFPAdvSIMDEnabled64(); V_set(rd, datasize) = imm
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.