SM3SS1 (vector)

Data processing (scalar floating-point and Advanced SIMD)

fixed bit field field the encoding fixes should be

Vector crypto sm3 sm3ss1

313029282726252423222120191817161514131211109876543210
11001110010Rm0RaRnRd

11001110010xxxxx0xxxxxxxxxxxxxxx

Decode Sail

if not_bool(HaveSM3Ext()) then {
    throw(Error_Undefined())
};
let 'd = UInt(Rd);
let 'n = UInt(Rn);
let 'm = UInt(Rm);
let 'a = UInt(Ra);
execute_aarch64_instrs_vector_crypto_sm3_sm3ss1(a, d, m, n)

Operation Sail

AArch64_CheckFPAdvSIMDEnabled();
let Vm : bits(128) = V_read(m, 128);
let Vn : bits(128) = V_read(n, 128);
let Va : bits(128) = V_read(a, 128);
result : bits(128) = undefined;
result[127 .. 96] = ROL(ROL(Vn[127 .. 96], 12) + Vm[127 .. 96] + Va[127 .. 96], 7);
result[95 .. 0] = Zeros(96);
V_set(d, 128) = result

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.