##ldpsw_execute
bits(64) address;
bits(datasize) data1;
bits(datasize) data2;
constant integer dbytes = datasize / 8;
boolean rt_unknown = FALSE;
boolean wb_unknown = FALSE;

if memop == MemOp_LOAD && wback && (t == n || t2 == n) && n != 31 then
    case c of
end

if memop == MemOp_STORE && wback && (t == n || t2 == n) && n != 31 then
    case c of
end

if memop == MemOp_LOAD && t == t2 then
    case c of
end

if n == 31 then
    address = SP[];
else
    address = X[n];
end

if ! postindex then
    address = address + offset;
end

case memop of
    when MemOp_STORE
        if rt_unknown && t == n then
            data1 = bits(datasize) UNKNOWN;
        else
            data1 = X[t];
        end
        if rt_unknown && t2 == n then
            data2 = bits(datasize) UNKNOWN;
        else
            data2 = X[t2];
        end
        Mem[address + 0     , dbytes, acctype] = data1;
        Mem[address + dbytes, dbytes, acctype] = data2;
    end

    when MemOp_LOAD
        data1 = Mem[address + 0     , dbytes, acctype];
        data2 = Mem[address + dbytes, dbytes, acctype];
        if rt_unknown then
            data1 = bits(datasize) UNKNOWN;
            data2 = bits(datasize) UNKNOWN;
        end
        if signed then
            X[t]  = SignExtend(data1, 64);
            X[t2] = SignExtend(data2, 64);
        else
            X[t]  = data1;
            X[t2] = data2;
        end

    end
if wback then
    if wb_unknown then
        address = bits(64) UNKNOWN;
    elsif postindex then
        address = address + offset;
    end
    if n == 31 then
        SP[] = address;
    else
        X[n] = address;
    end
end
@@
