the test of op of src1 and src2's components the mask enables (zero_test 1 includes equality; sign_test 0 is (in)equality, 1 less than, 2 greater than), each a bool (SetTest): how many
function TestCompare(kind : int, eq : bool, sign : int, x : bits(32), y : bits(32)) -> bool =
if kind == K_FLOAT then FCompare(if eq then (if sign == 0 then 2 else if sign == 1 then 3 else 6)
else (if sign == 0 then 5 else if sign == 1 then 1 else 4), x, y)
else if sign == 0 then { if eq then IEqT(x, y) else INeT(x, y) }
else if kind == K_INT then {
if sign == 1 then { if eq then SLeT(x, y) else SLtT(x, y) } else { if eq then SGeT(x, y) else SGtT(x, y) }
} else {
if sign == 1 then { if eq then ULeT(x, y) else ULtT(x, y) } else { if eq then UGeT(x, y) else UGtT(x, y) }
}Made from ScarletNX's Sail at 166ad3910f80. The Sail and the encodings' file are ScarletNX's (GPL-3.0-or-later); its encodings are from Vita3K's usse_translator_entry.cpp (GPL-2.0-or-later).