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 |
| opc | 1 | 0 | 1 | 1 | 0 | 0 | 1 | 1 | imm7 | Rt2 | Rn | Rt | |||||||||||||||||||
| L | |||||||||||||||||||||||||||||||
xx10110011xxxxxxxxxxxxxxxxxxxxxx
let wback : bool = true;
let postindex : bool = true;
let 'n = UInt(Rn);
let 't = UInt(Rt);
let 't2 = UInt(Rt2);
let nontemporal : bool = false;
let memop : MemOp = if L == 0b1 then MemOp_LOAD else MemOp_STORE;
if opc == 0b11 then {
throw(Error_Undefined())
};
let 'scale = 2 + UInt(opc);
let 'datasize = (8 << scale);
let offset : bits(64) = LSL(SignExtend(imm7, 64), scale);
let tagchecked : bool = wback | n != 31;
rt_unknown : bool = false;
if memop == MemOp_LOAD & t == t2 then {
let c : Constraint = ConstrainUnpredictable(Unpredictable_LDPOVERLAP);
assert(c == Constraint_UNKNOWN | c == Constraint_UNDEF | c == Constraint_NOP);
match c {
Constraint_UNKNOWN => {
rt_unknown = true
},
Constraint_UNDEF => {
throw(Error_Undefined())
},
Constraint_NOP => {
EndOfInstruction()
},
_ => ()
}
};
assert(constraint('datasize in {32, 64, 128, 256}));
execute_aarch64_instrs_memory_pair_simdfp_post_idx(datasize, memop, n, nontemporal, offset, postindex, rt_unknown, t, t2, tagchecked, wback)
| 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 |
| opc | 1 | 0 | 1 | 1 | 0 | 1 | 1 | 1 | imm7 | Rt2 | Rn | Rt | |||||||||||||||||||
| L | |||||||||||||||||||||||||||||||
xx10110111xxxxxxxxxxxxxxxxxxxxxx
let wback : bool = true;
let postindex : bool = false;
let 'n = UInt(Rn);
let 't = UInt(Rt);
let 't2 = UInt(Rt2);
let nontemporal : bool = false;
let memop : MemOp = if L == 0b1 then MemOp_LOAD else MemOp_STORE;
if opc == 0b11 then {
throw(Error_Undefined())
};
let 'scale = 2 + UInt(opc);
let 'datasize = (8 << scale);
let offset : bits(64) = LSL(SignExtend(imm7, 64), scale);
let tagchecked : bool = wback | n != 31;
rt_unknown : bool = false;
if memop == MemOp_LOAD & t == t2 then {
let c : Constraint = ConstrainUnpredictable(Unpredictable_LDPOVERLAP);
assert(c == Constraint_UNKNOWN | c == Constraint_UNDEF | c == Constraint_NOP);
match c {
Constraint_UNKNOWN => {
rt_unknown = true
},
Constraint_UNDEF => {
throw(Error_Undefined())
},
Constraint_NOP => {
EndOfInstruction()
},
_ => ()
}
};
assert(constraint('datasize in {32, 64, 128, 256}));
execute_aarch64_instrs_memory_pair_simdfp_post_idx(datasize, memop, n, nontemporal, offset, postindex, rt_unknown, t, t2, tagchecked, wback)
| 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 |
| opc | 1 | 0 | 1 | 1 | 0 | 1 | 0 | 1 | imm7 | Rt2 | Rn | Rt | |||||||||||||||||||
| L | |||||||||||||||||||||||||||||||
xx10110101xxxxxxxxxxxxxxxxxxxxxx
let wback : bool = false;
let postindex : bool = false;
let 'n = UInt(Rn);
let 't = UInt(Rt);
let 't2 = UInt(Rt2);
let nontemporal : bool = false;
let memop : MemOp = if L == 0b1 then MemOp_LOAD else MemOp_STORE;
if opc == 0b11 then {
throw(Error_Undefined())
};
let 'scale = 2 + UInt(opc);
let 'datasize = (8 << scale);
let offset : bits(64) = LSL(SignExtend(imm7, 64), scale);
let tagchecked : bool = wback | n != 31;
rt_unknown : bool = false;
if memop == MemOp_LOAD & t == t2 then {
let c : Constraint = ConstrainUnpredictable(Unpredictable_LDPOVERLAP);
assert(c == Constraint_UNKNOWN | c == Constraint_UNDEF | c == Constraint_NOP);
match c {
Constraint_UNKNOWN => {
rt_unknown = true
},
Constraint_UNDEF => {
throw(Error_Undefined())
},
Constraint_NOP => {
EndOfInstruction()
},
_ => ()
}
};
assert(constraint('datasize in {32, 64, 128, 256}));
execute_aarch64_instrs_memory_pair_simdfp_post_idx(datasize, memop, n, nontemporal, offset, postindex, rt_unknown, t, t2, tagchecked, wback)
CheckFPEnabled64();
address : bits(64) = undefined;
data1 : bits('datasize) = undefined;
data2 : bits('datasize) = undefined;
let 'dbytes = DIV(datasize, 8);
let accdesc : AccessDescriptor = CreateAccDescASIMD(memop, nontemporal, tagchecked);
if n == 31 then {
CheckSPAlignment();
address = SP_read()
} else {
address = X_read(n, 64)
};
if not_bool(postindex) then {
address = address + offset
};
match memop {
MemOp_STORE => {
assert(constraint('datasize in {8, 16, 32, 64, 128}));
let data1 : bits('datasize) = V_read(t, datasize);
let data2 : bits('datasize) = V_read(t2, datasize);
Mem_set(address + 0, dbytes, accdesc) = data1;
Mem_set(address + dbytes, dbytes, accdesc) = data2
},
MemOp_LOAD => {
data1 : bits('datasize) = Mem_read(address + 0, dbytes, accdesc);
data2 : bits('datasize) = Mem_read(address + dbytes, dbytes, accdesc);
if rt_unknown then {
data1 = __UNKNOWN_bits(datasize);
data2 = __UNKNOWN_bits(datasize)
};
assert(constraint('datasize in {8, 16, 32, 64, 128}));
V_set(t, datasize) = data1;
V_set(t2, datasize) = data2
},
_ => ()
};
if wback then {
if postindex then {
address = address + offset
};
if n == 31 then {
SP_set() = address
} else {
X_set(n, 64) = address
}
};
if SPESampleInFlight then {
SPESampleSIMDFPLoadStore()
};
()
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.