// Copyright (c) 2026 Petr BalvĂ­n (https://petrbalvin.org) // SPDX-License-Identifier: BSD-3-Clause // This file carries the extended-instruction layer: instructions the Go // toolchain does not know at all, described as data and validated against // golden vectors from the Arm Architecture Reference Manual rather than // against the toolchain. It sits beside the generated tables, never inside // them: arch/arm64_gen.go stays untouched, and Extensions returns the layer // per architecture; the amd64 side of the layer lives in amd64_ext.go and // attaches through the same door. // // The first entries are the arm64 SVE and SVE2 integer add/subtract/multiply // family (twenty-three forms over four word shapes) and the SVE and SVE2.1 // predicate family (logical operations, breaks, permutations, tests, the // first-fault register group and the while compares). The encodings are // transcribed from the manual and cross-checked against the Go toolchain's // generated encoding table and corpus; the golden vectors in // arm64_ext_test.go pin the bytes. package arch import "fmt" // ExtOperandKind classifies one operand of an extended instruction. type ExtOperandKind uint8 // Operand kinds. const ( ExtZReg ExtOperandKind = iota // scalable vector register Z0-Z31 ExtPReg // predicate register P0-P15 ExtImm // immediate // The amd64 layer's register kinds. ExtXMM // 128-bit vector register XMM0-XMM31 ExtYMM // 256-bit vector register YMM0-YMM31 ExtZMM // 512-bit vector register ZMM0-ZMM31 ExtKReg // opmask register K0-K7 ExtR32 // 32-bit general register EAX-R15D ExtR64 // 64-bit general register RAX-R15 ExtMem // base-relative memory operand, 4660(R8) style // The arm64 layer's general and counter registers. ExtGReg // general register R0-R30 ExtPNReg // predicate-as-counter register PN8-PN15 ExtVReg // 128-bit SIMD register V0-V31, the scalar lanes of Z0-Z31 // ExtSveMem is the arm64 gather/scatter memory operand, the parenthesised // register pair or immediate-offset base the SVE loads and stores address // through: (R6)(R14), (Z23.D<<1)(R24), (Z4.S.UXTW)(R3), 6(Z7.S). ExtSveMem ) // String returns a short label for the kind. func (k ExtOperandKind) String() string { switch k { case ExtZReg: return "scalable vector register" case ExtPReg: return "predicate register" case ExtImm: return "immediate" case ExtXMM: return "XMM register" case ExtYMM: return "YMM register" case ExtZMM: return "ZMM register" case ExtKReg: return "opmask register" case ExtR32: return "32-bit general register" case ExtR64: return "64-bit general register" case ExtMem: return "memory operand" case ExtGReg: return "general register" case ExtPNReg: return "predicate-as-counter register" case ExtVReg: return "SIMD register" case ExtSveMem: return "SVE memory operand" default: return "operand" } } // ExtArrangement is the element-size suffix a scalable vector operand // carries: .B, .H, .S, .D or .Q. ExtArrNone means the operand is written // bare, which the SVE forms in this layer reject. type ExtArrangement uint8 // Arrangements, widest last. const ( ExtArrNone ExtArrangement = iota ExtArrB // 8-bit elements ExtArrH // 16-bit elements ExtArrS // 32-bit elements ExtArrD // 64-bit elements ExtArrQ // 128-bit elements ) // String returns the assembler suffix, with the leading dot. func (a ExtArrangement) String() string { switch a { case ExtArrB: return ".B" case ExtArrH: return ".H" case ExtArrS: return ".S" case ExtArrD: return ".D" case ExtArrQ: return ".Q" default: return "" } } // Width returns the byte width of one element under the arrangement. func (a ExtArrangement) Width() int { switch a { case ExtArrB: return 1 case ExtArrH: return 2 case ExtArrS: return 4 case ExtArrD: return 8 case ExtArrQ: return 16 default: return 0 } } // elemBits returns the arrangement's element size in bits, the scale the // shift-immediate classes encode their amounts against. func (a ExtArrangement) elemBits() int { return a.Width() * 8 } // sizeBits maps the arrangement onto the two-bit size field the integer SVE // classes carry at bits 23..22: 00=B, 01=H, 10=S, 11=D. ok is false for the // arrangements no such class accepts (.Q and the bare spelling). func (a ExtArrangement) sizeBits() (uint32, bool) { switch a { case ExtArrB, ExtArrH, ExtArrS, ExtArrD: return uint32(a) - 1, true default: return 0, false } } // ExtQualifier is the predicate qualifier spelled after the slash. type ExtQualifier uint8 // Predicate qualifiers. const ( ExtQualNone ExtQualifier = iota // bare Pn (non-predicating position) ExtQualMerging // /M, inactive lanes keep the destination ExtQualZeroing // /Z, inactive lanes become zero ExtQualAny // metadata only: the row takes /M or /Z ) // String returns the assembler spelling, with the leading slash. func (q ExtQualifier) String() string { switch q { case ExtQualMerging: return "/M" case ExtQualZeroing: return "/Z" default: return "" } } // ExtOperand is one operand of an extended instruction, already resolved to // its pieces: a register with its arrangement and qualifier, or an immediate // with its optional left shift. The assembler's future hook constructs these // from the parsed statement; Encode consumes them. type ExtOperand struct { Kind ExtOperandKind // Reg is the register number (Z: 0..31, P: 0..15, R: 0..30, PN: 8..15); // under ExtMem it is the base general register, 0..15. Reg int Arr ExtArrangement // element-size suffix; ExtArrNone when bare Qual ExtQualifier // predicate qualifier; ExtQualNone elsewhere // Imm is the immediate value under ExtImm; under ExtMem it is the // signed displacement the base carries. Imm int64 // Shift carries the LSL amount an immediate form shifts the constant by // before use (0 or 8 in the SVE add/subtract immediate class). HasShift // separates a spelled shift (validated as written) from an unshifted // operand (the encoder may derive the sh bit from the value). Shift int HasShift bool // Broadcast spells the {1toN} broadcast on an amd64 memory operand: the // base-relative location holds one element the hardware splats across // every lane of the destination, which the encoder lays down as EVEX.b. // Only the memory positions of the entries that carry Bcast accept it. Broadcast bool // Index and Scale spell the scaled index of an amd64 memory operand, // the SIB byte's shape: base plus index times scale. Scale carries the // byte multiplier 1, 2, 4 or 8, and HasIndex separates a spelled index // from the plain base-plus-displacement operand. The index is a // general register 0..15, and RSP is no index. Index int Scale int HasIndex bool // Mask spells the write mask of an amd64 EVEX destination, the {k1} // through {k7} decorations: only the masked lanes take the result. // HasMask separates a spelled mask from the unmasked destination, and // K0 never masks, so the register runs 1..7. Only the packed // destinations of the entries that carry Mask accept it. Mask int HasMask bool // Zeroing spells the {z} decoration beside a write mask: the inactive // lanes become zero instead of keeping the destination. It is valid // only together with a spelled mask. Zeroing bool // Reg31 names how the thirty-first general-register slot was spelled on // an arm64 ExtGReg operand: the zero register ZR or the stack pointer // RSP. Both encode as 31 in the five-bit register fields, and the forms // of this layer accept one spelling or the other, never a plain R31, so // the marker carries the distinction into the diagnostics. Reg31 uint8 // 0 = a register 0..30, 1 = ZR, 2 = RSP // The arm64 gather/scatter memory operand (Kind ExtSveMem) carries its // addressing in these fields beside Reg, Arr, Imm, Shift and Reg31: the // first parenthesised register in Reg (general or scalable vector, told // apart by BaseVec, its element size in Arr), the optional UXTW or SXTW // extension in Extend, the <> (32 - f.Width) } // extSet ORs v into the field of word. func extSet(word uint32, f ExtField, v uint32) uint32 { return word | (v&extMask(f))< 31 { return nil, fmt.Errorf("%s: operand %d is Z%d, outside Z0-Z31", in.Name, i+1, op.Reg) } } arr, err := in.sharedArrangement(ops) if err != nil { return nil, err } size, ok := arr.sizeBits() if !ok { return nil, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, arr) } word := in.Word word = extSet(word, extFieldRn, uint32(ops[0].Reg)) word = extSet(word, extFieldRm, uint32(ops[1].Reg)) word = extSet(word, extFieldRd, uint32(ops[2].Reg)) word = extSet(word, in.Size, size) return extWordLE(word), nil } // encodePredicated fills the governed destructive form: Zm, Pg/M, Zdn. The // predicate is a 3-bit field, the merging qualifier alone, and carries no // arrangement suffix in this class. func (in ExtInstr) encodePredicated(ops []ExtOperand) ([]byte, error) { zm, pg, zdn := ops[0], ops[1], ops[2] if zm.Kind != ExtZReg { return nil, fmt.Errorf("%s: operand 1 wants a scalable vector register, got %s", in.Name, zm.Kind) } if zm.Reg < 0 || zm.Reg > 31 { return nil, fmt.Errorf("%s: operand 1 is Z%d, outside Z0-Z31", in.Name, zm.Reg) } if pg.Kind != ExtPReg { return nil, fmt.Errorf("%s: operand 2 wants a predicate register, got %s", in.Name, pg.Kind) } if pg.Reg < 0 || pg.Reg > 7 { return nil, fmt.Errorf("%s: operand 2 is P%d, outside P0-P7 in this class", in.Name, pg.Reg) } if pg.Qual != ExtQualMerging { return nil, fmt.Errorf("%s: operand 2 wants the merging qualifier /M, got %q", in.Name, pg.Qual) } if pg.Arr != ExtArrNone { return nil, fmt.Errorf("%s: the governing predicate carries no arrangement suffix, got %s", in.Name, pg.Arr) } if zdn.Kind != ExtZReg { return nil, fmt.Errorf("%s: operand 3 wants a scalable vector register, got %s", in.Name, zdn.Kind) } if zdn.Reg < 0 || zdn.Reg > 31 { return nil, fmt.Errorf("%s: operand 3 is Z%d, outside Z0-Z31", in.Name, zdn.Reg) } if zm.Arr != zdn.Arr { return nil, fmt.Errorf("%s: operands 1 and 3 carry arrangements %s and %s, they must match", in.Name, zm.Arr, zdn.Arr) } size, ok := zdn.Arr.sizeBits() if !ok { return nil, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, zdn.Arr) } word := in.Word word = extSet(word, extFieldRn, uint32(zm.Reg)) word = extSet(word, extFieldPg, uint32(pg.Reg)) word = extSet(word, extFieldRd, uint32(zdn.Reg)) word = extSet(word, in.Size, size) return extWordLE(word), nil } // encodeImmediate fills the add/subtract immediate form: imm{, LSL #8}, Zdn. // The class encodes an unsigned imm8 with one shift bit, so a bare multiple // of 256 derives the shift the way the GNU assembler canonicalises it. func (in ExtInstr) encodeImmediate(ops []ExtOperand) ([]byte, error) { imm, zdn := ops[0], ops[1] imm8, sh, err := in.addSubImmediate(imm, zdn.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldImm8, uint32(imm8)) if sh != 0 { word = extSet(word, extFieldSh, 1) } word, err = in.setDestAndSize(word, zdn) if err != nil { return nil, err } return extWordLE(word), nil } // encodeSignedImmediate fills the multiply immediate form: simm8, Zdn, with // no shift bit in the class. func (in ExtInstr) encodeSignedImmediate(ops []ExtOperand) ([]byte, error) { imm, zdn := ops[0], ops[1] if imm.Kind != ExtImm { return nil, fmt.Errorf("%s: operand 1 wants an immediate, got %s", in.Name, imm.Kind) } if imm.HasShift { return nil, fmt.Errorf("%s: the signed immediate class takes no shift", in.Name) } if imm.Imm < -128 || imm.Imm > 127 { return nil, fmt.Errorf("%s: immediate %d is outside the signed 8-bit range -128..127", in.Name, imm.Imm) } word := in.Word word = extSet(word, extFieldImm8, uint32(imm.Imm)) word, err := in.setDestAndSize(word, zdn) if err != nil { return nil, err } return extWordLE(word), nil } // addSubImmediate resolves the immediate operand of the add/subtract // immediate class into its imm8 and shift bit: a spelled shift is validated // as written, a bare multiple of 256 (on .H, .S or .D) derives one. func (in ExtInstr) addSubImmediate(op ExtOperand, arr ExtArrangement) (imm8, sh int, err error) { if op.Kind != ExtImm { return 0, 0, fmt.Errorf("%s: operand 1 wants an immediate, got %s", in.Name, op.Kind) } switch { case op.HasShift: if op.Shift != 0 && op.Shift != 8 { return 0, 0, fmt.Errorf("%s: the shift amount must be 0 or 8, got %d", in.Name, op.Shift) } if arr == ExtArrB && op.Shift != 0 { return 0, 0, fmt.Errorf("%s: arrangement .B takes no shift", in.Name) } if op.Imm < 0 || op.Imm > 255 { return 0, 0, fmt.Errorf("%s: immediate %d is outside the unsigned 8-bit range 0..255", in.Name, op.Imm) } return int(op.Imm), op.Shift, nil case op.Imm >= 0 && op.Imm <= 255: return int(op.Imm), 0, nil case arr != ExtArrB && op.Imm >= 256 && op.Imm <= 255<<8 && op.Imm%256 == 0: // A bare multiple of 256 rides the shift bit, 65280 = 255<<8 included. return int(op.Imm / 256), 8, nil default: return 0, 0, fmt.Errorf("%s: immediate %d is not an unsigned imm8%s, nor a multiple of 256 the shift bit can carry", in.Name, op.Imm, arr.shiftNote()) } } // shiftNote describes where a shifted constant is expressible, for the // immediate range error. func (arr ExtArrangement) shiftNote() string { if arr == ExtArrB { return " (and .B takes no shifted constant)" } return " (a multiple of 256 up to 65280 shifts)" } // predicateOperand validates one predicate operand: its kind, its register // range and, when want is non-empty, the one arrangement the class takes. func (in ExtInstr) predicateOperand(op ExtOperand, position int, lo, hi int, want ExtArrangement) error { if op.Kind != ExtPReg { return fmt.Errorf("%s: operand %d wants a predicate register, got %s", in.Name, position, op.Kind) } if op.Reg < lo || op.Reg > hi { return fmt.Errorf("%s: operand %d is P%d, outside P%d-P%d in this class", in.Name, position, op.Reg, lo, hi) } if want != ExtArrNone && op.Arr != want { return fmt.Errorf("%s: operand %d carries arrangement %s, want %s", in.Name, position, op.Arr, want) } return nil } // encodePredicateLogical fills the four-operand predicate logical form: // Pm.B, Pn.B, Pg{qualifier}, Pd.B. Pm takes P0-P7, Pn and Pd P0-P15; the // governing predicate takes P0-P7 and its qualifier is zeroing for the // logical operations and bare for PSEL, which the form distinguishes. func (in ExtInstr) encodePredicateLogical(ops []ExtOperand) ([]byte, error) { pm, pn, pg, pd := ops[0], ops[1], ops[2], ops[3] if err := in.predicateOperand(pm, 1, 0, 7, ExtArrB); err != nil { return nil, err } if err := in.predicateOperand(pn, 2, 0, 15, ExtArrB); err != nil { return nil, err } // The governing predicate carries its qualifier in place of an // arrangement (P1.Z), so the form judges the qualifier below. if err := in.predicateOperand(pg, 3, 0, 7, ExtArrNone); err != nil { return nil, err } if pg.Arr != ExtArrNone { return nil, fmt.Errorf("%s: the governing predicate carries no arrangement suffix, got %s", in.Name, pg.Arr) } if err := in.predicateOperand(pd, 4, 0, 15, ExtArrB); err != nil { return nil, err } wantQual := ExtQualZeroing if in.Form == ExtFormPredicateSelect { wantQual = ExtQualNone } if pg.Qual != wantQual { if wantQual == ExtQualNone { return nil, fmt.Errorf("%s: operand 3 takes no qualifier, got %q", in.Name, pg.Qual) } return nil, fmt.Errorf("%s: operand 3 wants the zeroing qualifier, got %q", in.Name, pg.Qual) } word := in.Word word = extSet(word, extFieldPm, uint32(pm.Reg)) word = extSet(word, extFieldPn, uint32(pn.Reg)) word = extSet(word, extFieldPgN, uint32(pg.Reg)) word = extSet(word, extFieldPd, uint32(pd.Reg)) return extWordLE(word), nil } // encodePredicateLogicalDest fills the break form whose first operand is the // destination read back: Pdm.B, Pn.B, Pg/Z, Pdm.B. The encoding carries the // register once, so operands 1 and 4 must name the same register. func (in ExtInstr) encodePredicateLogicalDest(ops []ExtOperand) ([]byte, error) { pdm, pn, pg := ops[0], ops[1], ops[2] if err := in.predicateOperand(pdm, 1, 0, 15, ExtArrB); err != nil { return nil, err } if err := in.predicateOperand(pn, 2, 0, 15, ExtArrB); err != nil { return nil, err } if err := in.predicateOperand(pg, 3, 0, 7, ExtArrNone); err != nil { return nil, err } if pg.Arr != ExtArrNone { return nil, fmt.Errorf("%s: the governing predicate carries no arrangement suffix, got %s", in.Name, pg.Arr) } if err := in.predicateOperand(ops[3], 4, 0, 15, ExtArrB); err != nil { return nil, err } if pg.Qual != ExtQualZeroing { return nil, fmt.Errorf("%s: operand 3 wants the zeroing qualifier, got %q", in.Name, pg.Qual) } if ops[3].Reg != pdm.Reg { return nil, fmt.Errorf("%s: operands 1 and 4 are the same register Pdm, got P%d and P%d", in.Name, pdm.Reg, ops[3].Reg) } word := in.Word word = extSet(word, extFieldPn, uint32(pn.Reg)) word = extSet(word, extFieldPgN, uint32(pg.Reg)) word = extSet(word, extFieldPd, uint32(pdm.Reg)) return extWordLE(word), nil } // encodePredicateBreak fills the three-operand break form: Pn.B, Pg{qual}, // Pd.B. The governing predicate is the wide four-bit field (P0-P15); the // plain break accepts the merging or the zeroing qualifier, the S variant // the zeroing alone. func (in ExtInstr) encodePredicateBreak(ops []ExtOperand) ([]byte, error) { pn, pg, pd := ops[0], ops[1], ops[2] if err := in.predicateOperand(pn, 1, 0, 15, ExtArrB); err != nil { return nil, err } if err := in.predicateOperand(pg, 2, 0, 15, ExtArrNone); err != nil { return nil, err } if err := in.predicateOperand(pd, 3, 0, 15, ExtArrB); err != nil { return nil, err } switch { case pg.Qual == ExtQualZeroing: case pg.Qual == ExtQualMerging && in.Form == ExtFormPredicateBreak: default: return nil, fmt.Errorf("%s: operand 2 wants the zeroing qualifier%s, got %q", in.Name, mergingNote(in.Form), pg.Qual) } word := in.Word word = extSet(word, extFieldPn, uint32(pn.Reg)) word = extSet(word, extFieldPgW, uint32(pg.Reg)) word = extSet(word, extFieldPd, uint32(pd.Reg)) return extWordLE(word), nil } // mergingNote describes the qualifier rule of a break form, for the error. func mergingNote(f ExtForm) string { if f == ExtFormPredicateBreak { return " or the merging qualifier" } return "" } // encodePredicatePermute fills the predicate permutation form: Pm.T, Pn.T, // Pd.T under one shared arrangement, which feeds the size field. func (in ExtInstr) encodePredicatePermute(ops []ExtOperand) ([]byte, error) { pm, pn, pd := ops[0], ops[1], ops[2] if err := in.predicateOperand(pm, 1, 0, 7, ExtArrNone); err != nil { return nil, err } if err := in.predicateOperand(pn, 2, 0, 15, ExtArrNone); err != nil { return nil, err } if err := in.predicateOperand(pd, 3, 0, 15, ExtArrNone); err != nil { return nil, err } size, err := in.sharedSize(pm.Arr, pn.Arr, pd.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldPm, uint32(pm.Reg)) word = extSet(word, extFieldPn, uint32(pn.Reg)) word = extSet(word, extFieldPd, uint32(pd.Reg)) word = extSet(word, in.Size, size) return extWordLE(word), nil } // encodePredicateReadBack fills the destination-read-back forms of PFIRST // and PNEXT: Pdn{.B or .T}, Pg or Pv (bare), Pdn. Operands 1 and 3 name the // same register; PNEXT carries the size field, PFIRST is .B alone. func (in ExtInstr) encodePredicateReadBack(ops []ExtOperand) ([]byte, error) { pdn, pg := ops[0], ops[1] if err := in.predicateOperand(pdn, 1, 0, 15, ExtArrNone); err != nil { return nil, err } if err := in.predicateOperand(pg, 2, 0, 15, ExtArrNone); err != nil { return nil, err } if err := in.predicateOperand(ops[2], 3, 0, 15, ExtArrNone); err != nil { return nil, err } if pg.Arr != ExtArrNone { return nil, fmt.Errorf("%s: operand 2 carries no arrangement suffix, got %s", in.Name, pg.Arr) } if pg.Qual != ExtQualNone { return nil, fmt.Errorf("%s: operand 2 takes no qualifier, got %q", in.Name, pg.Qual) } if ops[2].Reg != pdn.Reg || ops[2].Arr != pdn.Arr { return nil, fmt.Errorf("%s: operands 1 and 3 are the same register Pdn, got P%d and P%d", in.Name, pdn.Reg, ops[2].Reg) } var size uint32 if in.Form == ExtFormPredicateNext { var ok bool size, ok = pdn.Arr.sizeBits() if !ok { return nil, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, pdn.Arr) } } else if pdn.Arr != ExtArrB { return nil, fmt.Errorf("%s: operand 1 carries arrangement %s, want .B", in.Name, pdn.Arr) } word := in.Word word = extSet(word, extFieldPn, uint32(pg.Reg)) word = extSet(word, extFieldPd, uint32(pdn.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // encodePredicateOne fills the single-predicate form: Pd.B, destination in // the four-bit field. func (in ExtInstr) encodePredicateOne(ops []ExtOperand) ([]byte, error) { if err := in.predicateOperand(ops[0], 1, 0, 15, ExtArrB); err != nil { return nil, err } word := extSet(in.Word, extFieldPd, uint32(ops[0].Reg)) return extWordLE(word), nil } // encodePredicateWrite fills WRFFR's single-source form: Pn.B in the // five-bit source slot. func (in ExtInstr) encodePredicateWrite(ops []ExtOperand) ([]byte, error) { if err := in.predicateOperand(ops[0], 1, 0, 15, ExtArrB); err != nil { return nil, err } word := extSet(in.Word, extFieldPn, uint32(ops[0].Reg)) return extWordLE(word), nil } // encodePredicateFFRRead fills the predicated first-fault read: Pg/Z, Pd.B. // The first operand is the mask the read passes through, so it sits in the // five-bit source slot, not in a governing-predicate field. func (in ExtInstr) encodePredicateFFRRead(ops []ExtOperand) ([]byte, error) { pg, pd := ops[0], ops[1] if err := in.predicateOperand(pg, 1, 0, 15, ExtArrNone); err != nil { return nil, err } if err := in.predicateOperand(pd, 2, 0, 15, ExtArrB); err != nil { return nil, err } if pg.Qual != ExtQualZeroing { return nil, fmt.Errorf("%s: operand 1 wants the zeroing qualifier, got %q", in.Name, pg.Qual) } word := in.Word word = extSet(word, extFieldPn, uint32(pg.Reg)) word = extSet(word, extFieldPd, uint32(pd.Reg)) return extWordLE(word), nil } // encodePredicateMove fills the predicate reverse: Pn.T, Pd.T under one // shared arrangement. func (in ExtInstr) encodePredicateMove(ops []ExtOperand) ([]byte, error) { pn, pd := ops[0], ops[1] if err := in.predicateOperand(pn, 1, 0, 15, ExtArrNone); err != nil { return nil, err } if err := in.predicateOperand(pd, 2, 0, 15, ExtArrNone); err != nil { return nil, err } size, err := in.sharedSize(pn.Arr, pd.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldPn, uint32(pn.Reg)) word = extSet(word, extFieldPd, uint32(pd.Reg)) word = extSet(word, in.Size, size) return extWordLE(word), nil } // encodePredicateUnpack fills the predicate unpack: Pn.B, Pd.H, both // arrangements fixed by the class. func (in ExtInstr) encodePredicateUnpack(ops []ExtOperand) ([]byte, error) { pn, pd := ops[0], ops[1] if err := in.predicateOperand(pn, 1, 0, 15, ExtArrB); err != nil { return nil, err } if err := in.predicateOperand(pd, 2, 0, 15, ExtArrH); err != nil { return nil, err } word := in.Word word = extSet(word, extFieldPn, uint32(pn.Reg)) word = extSet(word, extFieldPd, uint32(pd.Reg)) return extWordLE(word), nil } // encodePredicateTest fills PTEST: Pn.B, Pg (bare), no destination. func (in ExtInstr) encodePredicateTest(ops []ExtOperand) ([]byte, error) { pn, pg := ops[0], ops[1] if err := in.predicateOperand(pn, 1, 0, 15, ExtArrB); err != nil { return nil, err } if err := in.predicateOperand(pg, 2, 0, 15, ExtArrNone); err != nil { return nil, err } if pg.Qual != ExtQualNone { return nil, fmt.Errorf("%s: operand 2 takes no qualifier, got %q", in.Name, pg.Qual) } word := in.Word word = extSet(word, extFieldPn, uint32(pn.Reg)) word = extSet(word, extFieldPgW, uint32(pg.Reg)) return extWordLE(word), nil } // encodeWhile fills the while-compare form: Rm, Rn, Pd.T, the arrangement // feeding the size field. The general registers run R0-R30; the class takes // no stack pointer and no zero register spelling. func (in ExtInstr) encodeWhile(ops []ExtOperand) ([]byte, error) { rm, rn, pd := ops[0], ops[1], ops[2] for i, op := range []ExtOperand{rm, rn} { if op.Kind != ExtGReg { return nil, fmt.Errorf("%s: operand %d wants a general register, got %s", in.Name, i+1, op.Kind) } if op.Reg < 0 || op.Reg > 30 { return nil, fmt.Errorf("%s: operand %d is R%d, outside R0-R30", in.Name, i+1, op.Reg) } } if err := in.predicateOperand(pd, 3, 0, 15, ExtArrNone); err != nil { return nil, err } size, ok := pd.Arr.sizeBits() if !ok { return nil, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, pd.Arr) } word := in.Word word = extSet(word, extFieldRm, uint32(rm.Reg)) word = extSet(word, extFieldPn, uint32(rn.Reg)) word = extSet(word, extFieldPd, uint32(pd.Reg)) word = extSet(word, in.Size, size) return extWordLE(word), nil } // encodePredicateCounter fills PTRUE's counter form: PNd.T, the // predicate-as-counter destination spelled PN8-PN15 and encoded as reg-8. func (in ExtInstr) encodePredicateCounter(ops []ExtOperand) ([]byte, error) { pnd := ops[0] if pnd.Kind != ExtPNReg { return nil, fmt.Errorf("%s: operand 1 wants a predicate-as-counter register, got %s", in.Name, pnd.Kind) } if pnd.Reg < 8 || pnd.Reg > 15 { return nil, fmt.Errorf("%s: operand 1 is PN%d, outside PN8-PN15", in.Name, pnd.Reg) } size, ok := pnd.Arr.sizeBits() if !ok { return nil, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, pnd.Arr) } word := in.Word word = extSet(word, extFieldPnc, uint32(pnd.Reg-8)) word = extSet(word, in.Size, size) return extWordLE(word), nil } // zVector validates one Z operand for the Z-alias classes: kind, range and // the row's arrangement rule, shared when in.Arr is none, fixed otherwise. func (in ExtInstr) zVector(op ExtOperand, position int) error { if op.Kind != ExtZReg { return fmt.Errorf("%s: operand %d wants a scalable vector register, got %s", in.Name, position, op.Kind) } if op.Reg < 0 || op.Reg > 31 { return fmt.Errorf("%s: operand %d is Z%d, outside Z0-Z31", in.Name, position, op.Reg) } if in.Arr != ExtArrNone { if op.Arr != in.Arr { return fmt.Errorf("%s: operand %d carries arrangement %s, want %s", in.Name, position, op.Arr, in.Arr) } } else if op.Arr == ExtArrNone { return fmt.Errorf("%s: operand %d carries no arrangement suffix", in.Name, position) } return nil } // zBare validates a Z operand that must carry no suffix at all (the bare // MOVPRFX spelling). func (in ExtInstr) zBare(op ExtOperand, position int) error { if op.Kind != ExtZReg { return fmt.Errorf("%s: operand %d wants a scalable vector register, got %s", in.Name, position, op.Kind) } if op.Reg < 0 || op.Reg > 31 { return fmt.Errorf("%s: operand %d is Z%d, outside Z0-Z31", in.Name, position, op.Reg) } if op.Arr != ExtArrNone { return fmt.Errorf("%s: operand %d takes no arrangement suffix, got %s", in.Name, position, op.Arr) } return nil } // zGov validates the bare governing predicate of the Z-alias forms: a // wide four-bit predicate (P0-P15, the field at bits 13..10 that the // ZSEL corpus line pins) with no suffix. func (in ExtInstr) zGov(op ExtOperand, position int) error { if op.Kind != ExtPReg { return fmt.Errorf("%s: operand %d wants a predicate register, got %s", in.Name, position, op.Kind) } if op.Reg < 0 || op.Reg > 15 { return fmt.Errorf("%s: operand %d is P%d, outside P0-P15 in this class", in.Name, position, op.Reg) } if op.Arr != ExtArrNone || op.Qual != ExtQualNone { return fmt.Errorf("%s: operand %d takes no suffix, got %s%s", in.Name, position, op.Arr, op.Qual) } return nil } // zSize returns the size encoding for a Z-alias arrangement: the shared // arrangement when the row locks none, else nothing (the fixed arrangement // rides the word's own bits). func (in ExtInstr) zSize(arrs ...ExtArrangement) (uint32, error) { if in.Arr != ExtArrNone { return 0, nil } return in.sharedSize(arrs...) } // encodeZUnary fills the Z-alias unary predicated form: Zn.T, Pg{qual}, // Zd.T. The row's PgQual says which qualifier the governing predicate // takes; the arrangement is shared, or fixed where the row locks one. func (in ExtInstr) encodeZUnary(ops []ExtOperand) ([]byte, error) { pn, pg, pd := ops[0], ops[1], ops[2] if err := in.zVector(pn, 1); err != nil { return nil, err } if err := in.zVector(pd, 3); err != nil { return nil, err } if err := in.predicateOperand(pg, 2, 0, 7, ExtArrNone); err != nil { return nil, err } if pg.Arr != ExtArrNone { return nil, fmt.Errorf("%s: the governing predicate carries no arrangement suffix, got %s", in.Name, pg.Arr) } switch { case pg.Qual == in.PgQual: case in.PgQual == ExtQualAny && (pg.Qual == ExtQualMerging || pg.Qual == ExtQualZeroing): default: if in.PgQual == ExtQualAny { return nil, fmt.Errorf("%s: operand 2 wants the merging or zeroing qualifier, got %q", in.Name, pg.Qual) } return nil, fmt.Errorf("%s: operand 2 wants the %s qualifier, got %q", in.Name, in.PgQual, pg.Qual) } size, err := in.zSize(pn.Arr, pd.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldPn, uint32(pn.Reg)) word = extSet(word, extFieldPgN, uint32(pg.Reg)) word = extSet(word, extFieldRd, uint32(pd.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // encodeZPredicatedSource fills the Z-alias binary predicated form: Zm.T, // Zdn.T, Pg/M, Zdn.T, the source copy spelled and equal to the destination. // Zm rides the first-source slot at bits 9..5 and Zdn the destination slot; // bits 16..20 carry the class opcode and stay clear of operands. func (in ExtInstr) encodeZPredicatedSource(ops []ExtOperand) ([]byte, error) { zm, zdn, pg := ops[0], ops[1], ops[2] if err := in.zVector(zm, 1); err != nil { return nil, err } if err := in.zVector(zdn, 2); err != nil { return nil, err } if err := in.predicateOperand(pg, 3, 0, 7, ExtArrNone); err != nil { return nil, err } if pg.Arr != ExtArrNone { return nil, fmt.Errorf("%s: the governing predicate carries no arrangement suffix, got %s", in.Name, pg.Arr) } if err := in.zVector(ops[3], 4); err != nil { return nil, err } if want := in.PgQual; pg.Qual != want { return nil, fmt.Errorf("%s: operand 3 wants the %s qualifier, got %q", in.Name, want.String(), pg.Qual) } if ops[3].Reg != zdn.Reg || ops[3].Arr != zdn.Arr { return nil, fmt.Errorf("%s: operands 2 and 4 are the same register Zdn, got Z%d and Z%d", in.Name, zdn.Reg, ops[3].Reg) } size, err := in.zSize(zm.Arr, zdn.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldRn, uint32(zm.Reg)) word = extSet(word, extFieldPgN, uint32(pg.Reg)) word = extSet(word, extFieldRd, uint32(zdn.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // encodeZImmediateSource fills the Z-alias immediate form: imm{, LSL #8}, // Zdn.T, Zdn.T, the register encoded once from the repeated spelling. func (in ExtInstr) encodeZImmediateSource(ops []ExtOperand) ([]byte, error) { imm, zdn := ops[0], ops[1] if imm.Kind != ExtImm { return nil, fmt.Errorf("%s: operand 1 wants an immediate, got %s", in.Name, imm.Kind) } if err := in.zVector(zdn, 2); err != nil { return nil, err } if err := in.zVector(ops[2], 3); err != nil { return nil, err } if ops[2].Reg != zdn.Reg || ops[2].Arr != zdn.Arr { return nil, fmt.Errorf("%s: operands 2 and 3 are the same register Zdn, got Z%d and Z%d", in.Name, zdn.Reg, ops[2].Reg) } imm8, sh, err := in.addSubImmediate(imm, zdn.Arr) if err != nil { return nil, err } size, err := in.zSize(zdn.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldImm8, uint32(imm8)) if sh != 0 { word = extSet(word, extFieldSh, 1) } word = extSet(word, extFieldRd, uint32(zdn.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // encodeZSelect fills the vector select: Zm.T, Zn.T, Pv, Zd.T. func (in ExtInstr) encodeZSelect(ops []ExtOperand) ([]byte, error) { zm, zn, pv, zd := ops[0], ops[1], ops[2], ops[3] if err := in.zVector(zm, 1); err != nil { return nil, err } if err := in.zVector(zn, 2); err != nil { return nil, err } if err := in.zVector(zd, 4); err != nil { return nil, err } if err := in.zGov(pv, 3); err != nil { return nil, err } size, err := in.zSize(zm.Arr, zn.Arr, zd.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldRm, uint32(zm.Reg)) word = extSet(word, extFieldPn, uint32(zn.Reg)) word = extSet(word, extFieldPgW, uint32(pv.Reg)) word = extSet(word, extFieldRd, uint32(zd.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // encodeZGov fills the governed compact/expand: Zn.T, Pg, Zd.T. func (in ExtInstr) encodeZGov(ops []ExtOperand) ([]byte, error) { pn, pg, zd := ops[0], ops[1], ops[2] if err := in.zVector(pn, 1); err != nil { return nil, err } if err := in.zVector(zd, 3); err != nil { return nil, err } if err := in.zGov(pg, 2); err != nil { return nil, err } size, err := in.zSize(pn.Arr, zd.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldPn, uint32(pn.Reg)) word = extSet(word, extFieldPgW, uint32(pg.Reg)) word = extSet(word, extFieldRd, uint32(zd.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // encodeZMove fills the vector reverse: Zn.T, Zd.T, one shared arrangement. func (in ExtInstr) encodeZMove(ops []ExtOperand) ([]byte, error) { pn, zd := ops[0], ops[1] if err := in.zVector(pn, 1); err != nil { return nil, err } if err := in.zVector(zd, 2); err != nil { return nil, err } size, err := in.zSize(pn.Arr, zd.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldPn, uint32(pn.Reg)) word = extSet(word, extFieldRd, uint32(zd.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // encodeZMoveBare fills MOVPRFX's arrangement-less spelling: Zn, Zd. func (in ExtInstr) encodeZMoveBare(ops []ExtOperand) ([]byte, error) { if err := in.zBare(ops[0], 1); err != nil { return nil, err } if err := in.zBare(ops[1], 2); err != nil { return nil, err } word := extSet(in.Word, extFieldPn, uint32(ops[0].Reg)) word = extSet(word, extFieldRd, uint32(ops[1].Reg)) return extWordLE(word), nil } // encodeVectorsZm fills the Z-alias three-vector form whose spelled order // starts with Zm: ZADD Z7.D, Z23.D, Z13.D puts Zm in the second-source // slot, Zn in the first-source slot and Zd in the destination. Rows with // a fixed arrangement validate it and leave the size bits to the word. func (in ExtInstr) encodeVectorsZm(ops []ExtOperand) ([]byte, error) { for i, op := range ops { if err := in.zVector(op, i+1); err != nil { return nil, err } } var size uint32 if in.Arr == ExtArrNone { var err error size, err = in.sharedSize(ops[0].Arr, ops[1].Arr, ops[2].Arr) if err != nil { return nil, err } } word := in.Word word = extSet(word, extFieldRm, uint32(ops[0].Reg)) word = extSet(word, extFieldRn, uint32(ops[1].Reg)) word = extSet(word, extFieldRd, uint32(ops[2].Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // encodeZUnpack fills the vector unpack: Zn.B, Zd.T, the size field // riding the destination's arrangement. func (in ExtInstr) encodeZUnpack(ops []ExtOperand) ([]byte, error) { pn, zd := ops[0], ops[1] if pn.Kind != ExtZReg { return nil, fmt.Errorf("%s: operand 1 wants a scalable vector register, got %s", in.Name, pn.Kind) } if pn.Reg < 0 || pn.Reg > 31 { return nil, fmt.Errorf("%s: operand 1 is Z%d, outside Z0-Z31", in.Name, pn.Reg) } if pn.Arr != ExtArrB { return nil, fmt.Errorf("%s: operand 1 carries arrangement %s, want .B", in.Name, pn.Arr) } if err := in.zVector(zd, 2); err != nil { return nil, err } size, err := in.zSize(zd.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldPn, uint32(pn.Reg)) word = extSet(word, extFieldRd, uint32(zd.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // encodeZFromGeneral fills the general-into-vector forms, ZDUP and ZINSR: // R, Zd.T with the arrangement locked by the row. func (in ExtInstr) encodeZFromGeneral(ops []ExtOperand) ([]byte, error) { rn, zd := ops[0], ops[1] if rn.Kind != ExtGReg { return nil, fmt.Errorf("%s: operand 1 wants a general register, got %s", in.Name, rn.Kind) } if rn.Reg < 0 || rn.Reg > 30 { return nil, fmt.Errorf("%s: operand 1 is R%d, outside R0-R30", in.Name, rn.Reg) } if err := in.zVector(zd, 2); err != nil { return nil, err } word := extSet(in.Word, extFieldPn, uint32(rn.Reg)) word = extSet(word, extFieldRd, uint32(zd.Reg)) return extWordLE(word), nil } // encodeZLastReg fills the last-active-element to register: Zn.T, Pg, R. func (in ExtInstr) encodeZLastReg(ops []ExtOperand) ([]byte, error) { pn, pg, rd := ops[0], ops[1], ops[2] if err := in.zVector(pn, 1); err != nil { return nil, err } if err := in.zGov(pg, 2); err != nil { return nil, err } if rd.Kind != ExtGReg { return nil, fmt.Errorf("%s: operand 3 wants a general register, got %s", in.Name, rd.Kind) } if rd.Reg < 0 || rd.Reg > 30 { return nil, fmt.Errorf("%s: operand 3 is R%d, outside R0-R30", in.Name, rd.Reg) } size, err := in.zSize(pn.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldPn, uint32(pn.Reg)) word = extSet(word, extFieldPgW, uint32(pg.Reg)) word = extSet(word, extFieldRd, uint32(rd.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // encodeZReadBack fills the SVE2 crypto form whose written order spells the // destination twice: Zn.T, Zd.T, Zd.T (SM4E, AESD, AESE). The row's // arrangement is locked into the word; operands 2 and 3 name the same // register and the encoding carries it once. func (in ExtInstr) encodeZReadBack(ops []ExtOperand) ([]byte, error) { zn := ops[0] if err := in.zVector(zn, 1); err != nil { return nil, err } if err := in.zVector(ops[1], 2); err != nil { return nil, err } if err := in.zVector(ops[2], 3); err != nil { return nil, err } if ops[2].Reg != ops[1].Reg || ops[2].Arr != ops[1].Arr { return nil, fmt.Errorf("%s: operands 2 and 3 are the same register Zd, got Z%d and Z%d", in.Name, ops[1].Reg, ops[2].Reg) } word := in.Word word = extSet(word, extFieldRn, uint32(zn.Reg)) word = extSet(word, extFieldRd, uint32(ops[1].Reg)) return extWordLE(word), nil } // encodeZSameReg fills the in-place SVE2 AES form: Zd.T, Zd.T (AESIMC, // AESMC), the register encoded once in the destination slot. func (in ExtInstr) encodeZSameReg(ops []ExtOperand) ([]byte, error) { if err := in.zVector(ops[0], 1); err != nil { return nil, err } if err := in.zVector(ops[1], 2); err != nil { return nil, err } if ops[1].Reg != ops[0].Reg || ops[1].Arr != ops[0].Arr { return nil, fmt.Errorf("%s: operands 1 and 2 are the same register Zd, got Z%d and Z%d", in.Name, ops[0].Reg, ops[1].Reg) } return extWordLE(extSet(in.Word, extFieldRd, uint32(ops[0].Reg))), nil } // reg31Name spells how the thirty-first general-register slot was written. func reg31Name(r uint8) string { switch r { case 1: return "ZR" case 2: return "RSP" default: return "" } } // generalOperand validates a general-register operand: R0-R30, or ZR or RSP // where allow31 names the one spelling of the thirty-first slot the class // takes. A register outside the range is an error, never a wrap. func (in ExtInstr) generalOperand(op ExtOperand, position int, allow31 uint8) error { if op.Kind != ExtGReg { return fmt.Errorf("%s: operand %d wants a general register, got %s", in.Name, position, op.Kind) } if op.Reg31 == 0 { if op.Reg < 0 || op.Reg > 30 { return fmt.Errorf("%s: operand %d is R%d, outside R0-R30", in.Name, position, op.Reg) } return nil } if op.Reg31 != allow31 { return fmt.Errorf("%s: operand %d wants %s here, got %s", in.Name, position, reg31Name(allow31), reg31Name(op.Reg31)) } return nil } // encodeCTerm fills the SVE2 loop terminator: Rm, Rn, both in the standard // five-bit slots, the zero register allowed in either. func (in ExtInstr) encodeCTerm(ops []ExtOperand) ([]byte, error) { for i, op := range ops { if err := in.generalOperand(op, i+1, 1); err != nil { return nil, err } } word := in.Word word = extSet(word, extFieldRm, uint32(ops[0].Reg)) word = extSet(word, extFieldRn, uint32(ops[1].Reg)) return extWordLE(word), nil } // barePredicate validates a governing predicate of the counter and reduction // classes: a plain P0-P15 with no suffix and no qualifier, the spelling the // corpus writes between the source and the destination. func (in ExtInstr) barePredicate(op ExtOperand, position, lo, hi int) error { if err := in.predicateOperand(op, position, lo, hi, ExtArrNone); err != nil { return err } if op.Arr != ExtArrNone { return fmt.Errorf("%s: operand %d carries no arrangement suffix, got %s", in.Name, position, op.Arr) } if op.Qual != ExtQualNone { return fmt.Errorf("%s: operand %d takes no qualifier, got %q", in.Name, position, op.Qual) } return nil } // encodeCountP fills the count form: Pn.T, Pg (bare), Rd. The arrangement // feeds the size field, Pg occupies the wide four-bit field and Pn the // five-bit source slot. func (in ExtInstr) encodeCountP(ops []ExtOperand) ([]byte, error) { pn, pg, rd := ops[0], ops[1], ops[2] if err := in.predicateOperand(pn, 1, 0, 15, ExtArrNone); err != nil { return nil, err } if err := in.barePredicate(pg, 2, 0, 15); err != nil { return nil, err } if err := in.generalOperand(rd, 3, 1); err != nil { return nil, err } size, ok := pn.Arr.sizeBits() if !ok { return nil, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, pn.Arr) } word := in.Word word = extSet(word, extFieldPgW, uint32(pg.Reg)) word = extSet(word, extFieldRn, uint32(pn.Reg)) word = extSet(word, extFieldRd, uint32(rd.Reg)) word = extSet(word, in.Size, size) return extWordLE(word), nil } // encodeCountPn fills the predicate-counter step whose scalar result the // class drops: Pn.T, ZR. The predicate occupies the four-bit field at bits // 8..5 and its arrangement feeds the size field; the second operand is the // zero register, the spelling that discards the count. func (in ExtInstr) encodeCountPn(ops []ExtOperand) ([]byte, error) { pn, rd := ops[0], ops[1] if err := in.predicateOperand(pn, 1, 0, 15, ExtArrNone); err != nil { return nil, err } // The scalar result of this class is architecturally dropped, and the // spelling that says so is the zero register alone: a plain R0-R30 has // no meaning here. if rd.Kind != ExtGReg || rd.Reg31 != 1 { return nil, fmt.Errorf("%s: operand 2 is the dropped scalar result, spelled ZR, got a %s", in.Name, rd.Kind) } size, ok := pn.Arr.sizeBits() if !ok { return nil, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, pn.Arr) } word := in.Word word = extSet(word, extFieldPn4, uint32(pn.Reg)) word = extSet(word, extFieldRd, uint32(rd.Reg)) word = extSet(word, in.Size, size) return extWordLE(word), nil } // encodeCountPnVec fills the predicate-counter step on a vector: Pm.T, // Zdn.T, the vector decremented in place by the predicate's active element // count. The predicate occupies the four-bit field at bits 8..5, the // vector the destination slot, and the predicate's arrangement feeds the // size field. func (in ExtInstr) encodeCountPnVec(ops []ExtOperand) ([]byte, error) { pm, zdn := ops[0], ops[1] if err := in.predicateOperand(pm, 1, 0, 15, ExtArrNone); err != nil { return nil, err } if err := in.zVector(zdn, 2); err != nil { return nil, err } size, ok := pm.Arr.sizeBits() if !ok { return nil, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, pm.Arr) } word := in.Word word = extSet(word, extFieldPn4, uint32(pm.Reg)) word = extSet(word, extFieldRd, uint32(zdn.Reg)) word = extSet(word, in.Size, size) return extWordLE(word), nil } // shiftImmAmount validates the immediate shift operand against the closed // range lo..hi and refuses the LSL spelling, which belongs to the // immediate-constant classes and not to the shift-immediate ones. func (in ExtInstr) shiftImmAmount(op ExtOperand, position, lo, hi int) (int, error) { if op.Kind != ExtImm { return 0, fmt.Errorf("%s: operand %d wants an immediate, got %s", in.Name, position, op.Kind) } if op.HasShift { return 0, fmt.Errorf("%s: the shift-immediate class takes no LSL shift", in.Name) } v := int(op.Imm) if v < lo || v > hi { return 0, fmt.Errorf("%s: shift amount %d is outside the range %d..%d in this class", in.Name, v, lo, hi) } return v, nil } // encodeShiftImmPred fills the predicated left shift by immediate: imm, // Zdn.T, Pg/M, Zdn.T, the destination spelled twice and encoded once. func (in ExtInstr) encodeShiftImmPred(ops []ExtOperand) ([]byte, error) { return in.encodeShiftImmPredC(ops, func(esize, v int) int { return esize + v }) } // encodeShiftImmPredRight fills the predicated right shift by immediate, // the right-shift counterpart of the predicated left shifts. func (in ExtInstr) encodeShiftImmPredRight(ops []ExtOperand) ([]byte, error) { return in.encodeShiftImmPredC(ops, func(esize, v int) int { return 2*esize - v }) } // encodeShiftImmPredC carries the predicated shift-by-immediate layout the // left and right shifts share: the amount rides the class's tsz:imm3 // fields, C = dir(esize, amount), split imm3 into bits 7..5, the low tsz // pair into bits 9..8 and the top tsz pair into bits 23..22, where the tsz // bits spell the arrangement and stand in for the size field the class // does not carry. func (in ExtInstr) encodeShiftImmPredC(ops []ExtOperand, dir func(esize, v int) int) ([]byte, error) { imm, zdn, pg, zdn2 := ops[0], ops[1], ops[2], ops[3] if err := in.zVector(zdn, 2); err != nil { return nil, err } if _, ok := zdn.Arr.sizeBits(); !ok { return nil, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, zdn.Arr) } esize := zdn.Arr.elemBits() v, err := in.shiftImmAmount(imm, 1, 1, esize-1) if err != nil { return nil, err } if err := in.predicateOperand(pg, 3, 0, 15, ExtArrNone); err != nil { return nil, err } if pg.Qual != ExtQualMerging { return nil, fmt.Errorf("%s: operand 3 wants the merging qualifier /M, got %q", in.Name, pg.Qual) } if err := in.zVector(zdn2, 4); err != nil { return nil, err } if zdn2.Reg != zdn.Reg || zdn2.Arr != zdn.Arr { return nil, fmt.Errorf("%s: operands 2 and 4 are the same register Zdn, got Z%d and Z%d", in.Name, zdn.Reg, zdn2.Reg) } c := dir(esize, v) word := in.Word word = extSet(word, extFieldImm3T5, uint32(c)) word = extSet(word, extFieldTszM8, uint32(c>>3)) word = extSet(word, extFieldTszH22W, uint32(c>>5)) word = extSet(word, extFieldRd, uint32(zdn.Reg)) word = extSet(word, extFieldPgW, uint32(pg.Reg)) return extWordLE(word), nil } // setShiftImmTsz16 ORs the three-vector tsz:imm3 chunks of c into the // word: imm3 into bits 18..16, the low tsz pair into bits 20..19 and the // top tsz pair into bits 23..22. func setShiftImmTsz16(word uint32, c int) uint32 { word = extSet(word, extFieldImm3T16, uint32(c)) word = extSet(word, extFieldTszM19, uint32(c>>3)) word = extSet(word, extFieldTszH22W, uint32(c>>5)) return word } // encodeShiftImmSame fills the same-size shift by immediate: imm, Zn.T, // Zd.T, a right shift within one shared arrangement, the destination (or // the read-modify-write accumulator) in the destination slot. C = 2 x // esize - amount over the shared element size. func (in ExtInstr) encodeShiftImmSame(ops []ExtOperand) ([]byte, error) { imm, zn, zd := ops[0], ops[1], ops[2] if err := in.zVector(zn, 2); err != nil { return nil, err } if _, ok := zn.Arr.sizeBits(); !ok { return nil, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, zn.Arr) } if err := in.zVector(zd, 3); err != nil { return nil, err } if zd.Arr != zn.Arr { return nil, fmt.Errorf("%s: operands 2 and 3 carry arrangements %s and %s, they must match", in.Name, zn.Arr, zd.Arr) } esize := zn.Arr.elemBits() v, err := in.shiftImmAmount(imm, 1, 1, esize-1) if err != nil { return nil, err } c := 2*esize - v word := setShiftImmTsz16(in.Word, c) word = extSet(word, extFieldRn, uint32(zn.Reg)) word = extSet(word, extFieldRd, uint32(zd.Reg)) return extWordLE(word), nil } // encodeShiftImmXar fills the three-source extract and narrow: imm, Zm.T, // Zdn.T, Zdn.T, the destination spelled twice and encoded once. C = 2 x // esize - amount over the shared element size. func (in ExtInstr) encodeShiftImmXar(ops []ExtOperand) ([]byte, error) { imm, zm, zdn, zdn2 := ops[0], ops[1], ops[2], ops[3] if err := in.zVector(zm, 2); err != nil { return nil, err } if _, ok := zm.Arr.sizeBits(); !ok { return nil, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, zm.Arr) } if err := in.zVector(zdn, 3); err != nil { return nil, err } if err := in.zVector(zdn2, 4); err != nil { return nil, err } if zdn2.Reg != zdn.Reg || zdn2.Arr != zdn.Arr { return nil, fmt.Errorf("%s: operands 3 and 4 are the same register Zdn, got Z%d and Z%d", in.Name, zdn.Reg, zdn2.Reg) } if zdn.Arr != zm.Arr { return nil, fmt.Errorf("%s: operands 2 and 3 carry arrangements %s and %s, they must match", in.Name, zm.Arr, zdn.Arr) } esize := zm.Arr.elemBits() v, err := in.shiftImmAmount(imm, 1, 1, esize-1) if err != nil { return nil, err } c := 2*esize - v word := setShiftImmTsz16(in.Word, c) word = extSet(word, extFieldRn, uint32(zm.Reg)) word = extSet(word, extFieldRd, uint32(zdn.Reg)) return extWordLE(word), nil } // encodeShiftImmNarrow fills the three-vector narrowing shift by immediate: // imm, Zn.Tb, Zd.T, a right shift of the wide source whose result the // destination one element step down keeps (.H+.B, .S+.H, .D+.S). The // amount runs 1..esize over the destination's element size and C = 2 x // esize - amount, split imm3 into bits 18..16, the low tsz pair into bits // 20..19 and the top tsz bit into bit 22. func (in ExtInstr) encodeShiftImmNarrow(ops []ExtOperand) ([]byte, error) { imm, zn, zd := ops[0], ops[1], ops[2] if err := in.zVector(zn, 2); err != nil { return nil, err } if zn.Arr < ExtArrH || zn.Arr > ExtArrD { return nil, fmt.Errorf("%s: operand 2 carries arrangement %s, want .H, .S or .D", in.Name, zn.Arr) } if err := in.zVector(zd, 3); err != nil { return nil, err } if zd.Arr != zn.Arr-1 { return nil, fmt.Errorf("%s: operand 3 carries arrangement %s, want one element step below %s", in.Name, zd.Arr, zn.Arr) } esize := zd.Arr.elemBits() v, err := in.shiftImmAmount(imm, 1, 1, esize) if err != nil { return nil, err } c := 2*esize - v word := in.Word word = extSet(word, extFieldImm3T16, uint32(c)) word = extSet(word, extFieldTszM19, uint32(c>>3)) word = extSet(word, extFieldTszH22, uint32(c>>5)) word = extSet(word, extFieldRn, uint32(zn.Reg)) word = extSet(word, extFieldRd, uint32(zd.Reg)) return extWordLE(word), nil } // encodeShiftImmWide fills the three-vector widening shift by immediate: // imm, Zn.Tb, Zd.T, a left shift of the narrow source into a destination // one element step up (.B+.H, .H+.S, .S+.D). The amount runs // 0..esize-1 over the source's element size and C = esize + amount, split // like the narrowing class. func (in ExtInstr) encodeShiftImmWide(ops []ExtOperand) ([]byte, error) { imm, zn, zd := ops[0], ops[1], ops[2] if err := in.zVector(zn, 2); err != nil { return nil, err } if zn.Arr < ExtArrB || zn.Arr > ExtArrS { return nil, fmt.Errorf("%s: operand 2 carries arrangement %s, want .B, .H or .S", in.Name, zn.Arr) } if err := in.zVector(zd, 3); err != nil { return nil, err } if zd.Arr != zn.Arr+1 { return nil, fmt.Errorf("%s: operand 3 carries arrangement %s, want one element step above %s", in.Name, zd.Arr, zn.Arr) } esize := zn.Arr.elemBits() v, err := in.shiftImmAmount(imm, 1, 0, esize-1) if err != nil { return nil, err } c := esize + v word := in.Word word = extSet(word, extFieldImm3T16, uint32(c)) word = extSet(word, extFieldTszM19, uint32(c>>3)) word = extSet(word, extFieldTszH22, uint32(c>>5)) word = extSet(word, extFieldRn, uint32(zn.Reg)) word = extSet(word, extFieldRd, uint32(zd.Reg)) return extWordLE(word), nil } // encodeCountPnW fills the predicate-counter step with a scalar result: // Rd, Pn.T, Rd, the destination spelled twice. The predicate occupies the // four-bit field at bits 8..5 and its arrangement feeds the size field. func (in ExtInstr) encodeCountPnW(ops []ExtOperand) ([]byte, error) { rd, pn := ops[0], ops[1] if err := in.generalOperand(rd, 1, 1); err != nil { return nil, err } if err := in.predicateOperand(pn, 2, 0, 15, ExtArrNone); err != nil { return nil, err } if err := in.generalOperand(ops[2], 3, 1); err != nil { return nil, err } if ops[2].Reg != rd.Reg || ops[2].Reg31 != rd.Reg31 { return nil, fmt.Errorf("%s: operands 1 and 3 are the same register, got R%d and R%d", in.Name, rd.Reg, ops[2].Reg) } size, ok := pn.Arr.sizeBits() if !ok { return nil, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, pn.Arr) } word := in.Word word = extSet(word, extFieldPn4, uint32(pn.Reg)) word = extSet(word, extFieldRd, uint32(rd.Reg)) word = extSet(word, in.Size, size) return extWordLE(word), nil } // simdReg validates a 128-bit SIMD register operand of the reduction // classes: V0-V31, written bare, no suffix and no qualifier. func (in ExtInstr) simdReg(op ExtOperand, position int) error { if op.Kind != ExtVReg { return fmt.Errorf("%s: operand %d wants a SIMD register, got %s", in.Name, position, op.Kind) } if op.Reg < 0 || op.Reg > 31 { return fmt.Errorf("%s: operand %d is V%d, outside V0-V31", in.Name, position, op.Reg) } if op.Arr != ExtArrNone || op.Qual != ExtQualNone { return fmt.Errorf("%s: operand %d takes no suffix, got %s%s", in.Name, position, op.Arr, op.Qual) } return nil } // encodeReduce fills the SVE reduction into a SIMD scalar: Zn.T, Pg (bare), // Vd. The governing predicate is the narrow three-bit field; the size bits // ride the row's word where the class locks the arrangement, and follow the // source's arrangement where it does not. func (in ExtInstr) encodeReduce(ops []ExtOperand) ([]byte, error) { zn, pg, vd := ops[0], ops[1], ops[2] if err := in.zVector(zn, 1); err != nil { return nil, err } if err := in.barePredicate(pg, 2, 0, 7); err != nil { return nil, err } if err := in.simdReg(vd, 3); err != nil { return nil, err } size, err := in.zSize(zn.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldPgN, uint32(pg.Reg)) word = extSet(word, extFieldRn, uint32(zn.Reg)) word = extSet(word, extFieldRd, uint32(vd.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // encodeReduceReadBack fills the strict-accumulation reduction: Zn.T, Vd, // Pg (bare), Vd, the SIMD destination spelled twice. func (in ExtInstr) encodeReduceReadBack(ops []ExtOperand) ([]byte, error) { zn, vd, pg := ops[0], ops[1], ops[2] if err := in.zVector(zn, 1); err != nil { return nil, err } if err := in.simdReg(vd, 2); err != nil { return nil, err } if err := in.barePredicate(pg, 3, 0, 7); err != nil { return nil, err } if err := in.simdReg(ops[3], 4); err != nil { return nil, err } if ops[3].Reg != vd.Reg { return nil, fmt.Errorf("%s: operands 2 and 4 are the same register Vd, got V%d and V%d", in.Name, vd.Reg, ops[3].Reg) } size, err := in.zSize(zn.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldPgN, uint32(pg.Reg)) word = extSet(word, extFieldRn, uint32(zn.Reg)) word = extSet(word, extFieldRd, uint32(vd.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // sveMemFill validates one gather/scatter memory operand against the row's // addressing mode and fills the register slots: the first parenthesised // register or the scaled immediate goes to the second-source slot, the // second parenthesis or the immediate-mode base to the first-source slot. func (in ExtInstr) sveMemFill(word uint32, op ExtOperand, position int) (uint32, error) { if op.Kind != ExtSveMem { return 0, fmt.Errorf("%s: operand %d wants an SVE memory operand, got %s", in.Name, position, op.Kind) } switch in.SveMode { case extMemPair: if op.BaseVec || op.Extend != 0 || op.Arr != ExtArrNone { return 0, fmt.Errorf("%s: operand %d wants two general registers, (Rn{<<%d})(Rm)", in.Name, position, in.SveShift) } if op.Shift != in.SveShift { return 0, fmt.Errorf("%s: operand %d wants the base scaled by <<%d, got <<%d", in.Name, position, in.SveShift, op.Shift) } if op.Reg < 0 || op.Reg > 30 { return 0, fmt.Errorf("%s: operand %d's base is R%d, outside R0-R30", in.Name, position, op.Reg) } word = extSet(word, extFieldRm, uint32(op.Reg)) word, err := in.sveMemOff(word, op, position) if err != nil { return 0, err } return word, nil case extMemVecOff, extMemExt32: if !op.BaseVec { return 0, fmt.Errorf("%s: operand %d wants a vector base, (Zn.%s{<<%d})(Rm)", in.Name, position, in.SveBase, in.SveShift) } if op.Arr != in.SveBase { return 0, fmt.Errorf("%s: operand %d's base carries arrangement %s, want %s", in.Name, position, op.Arr, in.SveBase) } if in.SveMode == extMemExt32 && op.Extend != 1 { return 0, fmt.Errorf("%s: operand %d wants the UXTW extension on the base", in.Name, position) } if in.SveMode == extMemVecOff && op.Extend != 0 { return 0, fmt.Errorf("%s: operand %d takes no extension on the base", in.Name, position) } if op.Shift != in.SveShift { return 0, fmt.Errorf("%s: operand %d wants the base scaled by <<%d, got <<%d", in.Name, position, in.SveShift, op.Shift) } if op.Reg < 0 || op.Reg > 31 { return 0, fmt.Errorf("%s: operand %d's base is Z%d, outside Z0-Z31", in.Name, position, op.Reg) } word = extSet(word, extFieldRm, uint32(op.Reg)) word, err := in.sveMemOff(word, op, position) if err != nil { return 0, err } return word, nil case extMemImm: if !op.BaseVec || op.Extend != 0 || op.Shift != 0 || op.Off != -1 { return 0, fmt.Errorf("%s: operand %d wants an immediate offset on a vector base, imm(Zn.%s)", in.Name, position, in.SveBase) } if op.Arr != in.SveBase { return 0, fmt.Errorf("%s: operand %d's base carries arrangement %s, want %s", in.Name, position, op.Arr, in.SveBase) } if op.Reg < 0 || op.Reg > 31 { return 0, fmt.Errorf("%s: operand %d's base is Z%d, outside Z0-Z31", in.Name, position, op.Reg) } esize := int64(1) << uint(in.SveShift) if op.Imm < 0 || op.Imm%esize != 0 || op.Imm/esize > 31 { return 0, fmt.Errorf("%s: operand %d's displacement %d is not a multiple of %d up to %d", in.Name, position, op.Imm, esize, 31*esize) } word = extSet(word, extFieldRm, uint32(op.Imm/esize)) word = extSet(word, extFieldRn, uint32(op.Reg)) return word, nil case extMemVecBase: if !op.BaseVec || op.Extend != 0 || op.Shift != 0 || op.Off != -1 { return 0, fmt.Errorf("%s: operand %d wants the vector base alone, (Zn.%s)", in.Name, position, in.SveBase) } if op.Arr != in.SveBase { return 0, fmt.Errorf("%s: operand %d's base carries arrangement %s, want %s", in.Name, position, op.Arr, in.SveBase) } if op.Reg < 0 || op.Reg > 31 { return 0, fmt.Errorf("%s: operand %d's base is Z%d, outside Z0-Z31", in.Name, position, op.Reg) } return extSet(word, extFieldRn, uint32(op.Reg)), nil default: return 0, fmt.Errorf("%s: the row names no addressing mode", in.Name) } } // sveMemOff validates the offset register of the parenthesised memory modes // and fills the first-source slot: a plain R0-R30, or the stack-pointer // spelling of the thirty-first slot. func (in ExtInstr) sveMemOff(word uint32, op ExtOperand, position int) (uint32, error) { if op.Off < 0 { return 0, fmt.Errorf("%s: operand %d wants a second register in the memory operand", in.Name, position) } if op.Reg31 == 2 && op.Off == 31 { return extSet(word, extFieldRn, 31), nil } if op.Reg31 != 0 || op.Off < 0 || op.Off > 30 { return 0, fmt.Errorf("%s: operand %d's offset register is outside R0-R30, with RSP allowed", in.Name, position) } return extSet(word, extFieldRn, uint32(op.Off)), nil } // svePredicate validates the governing predicate of a gather or scatter: the // narrow three-bit field, no arrangement suffix, zeroing on the loads and // bare on the stores. func (in ExtInstr) svePredicate(op ExtOperand, position int, zeroing bool) (uint32, error) { if err := in.predicateOperand(op, position, 0, 7, ExtArrNone); err != nil { return 0, err } if op.Arr != ExtArrNone { return 0, fmt.Errorf("%s: operand %d carries no arrangement suffix, got %s", in.Name, position, op.Arr) } if zeroing && op.Qual != ExtQualZeroing { return 0, fmt.Errorf("%s: operand %d wants the zeroing qualifier, got %q", in.Name, position, op.Qual) } if !zeroing && op.Qual != ExtQualNone { return 0, fmt.Errorf("%s: operand %d takes no qualifier, got %q", in.Name, position, op.Qual) } return uint32(op.Reg), nil } // sveList validates the destination or source vector of a gather or scatter // against the row's locked list arrangement. func (in ExtInstr) sveList(op ExtOperand, position int) (uint32, error) { if op.Kind != ExtZReg { return 0, fmt.Errorf("%s: operand %d wants a scalable vector register, got %s", in.Name, position, op.Kind) } if op.Reg < 0 || op.Reg > 31 { return 0, fmt.Errorf("%s: operand %d is Z%d, outside Z0-Z31", in.Name, position, op.Reg) } if op.Arr != in.Arr { return 0, fmt.Errorf("%s: operand %d carries arrangement %s, want %s", in.Name, position, op.Arr, in.Arr) } return uint32(op.Reg), nil } // encodeSveLoad fills the gather load: mem, Pg/Z, Zt.T. The addressing mode // is the row's own, its fixed word carrying the mode and list-size bits, and // the operands fill the register slots the mode names. func (in ExtInstr) encodeSveLoad(ops []ExtOperand) ([]byte, error) { word, err := in.sveMemFill(in.Word, ops[0], 1) if err != nil { return nil, err } pg, err := in.svePredicate(ops[1], 2, true) if err != nil { return nil, err } zt, err := in.sveList(ops[2], 3) if err != nil { return nil, err } word = extSet(word, extFieldPgN, pg) word = extSet(word, extFieldRd, zt) return extWordLE(word), nil } // encodeSveStore fills the scatter store: Zt.T, Pg, mem, mirroring the load // with the list first and a bare governing predicate. func (in ExtInstr) encodeSveStore(ops []ExtOperand) ([]byte, error) { zt, err := in.sveList(ops[0], 1) if err != nil { return nil, err } pg, err := in.svePredicate(ops[1], 2, false) if err != nil { return nil, err } word, err := in.sveMemFill(in.Word, ops[2], 3) if err != nil { return nil, err } word = extSet(word, extFieldPgN, pg) word = extSet(word, extFieldRd, zt) return extWordLE(word), nil } // encodeNarrow fills the two-to-one narrowing form: Zm.T2, Zn.T2, Zd.T, // where T is one step below T2. The wide sources combine and the // destination keeps the high half of each result; the single size field // serves both widths, the wide ladder on the sources and the narrow ladder // on the destination carrying the same value, so the arrangement pair is // validated as a whole. func (in ExtInstr) encodeNarrow(ops []ExtOperand) ([]byte, error) { zm, zn, zd := ops[0], ops[1], ops[2] for i, op := range []ExtOperand{zm, zn, zd} { if err := in.zVector(op, i+1); err != nil { return nil, err } } if zm.Arr != zn.Arr { return nil, fmt.Errorf("%s: operands 1 and 2 carry arrangements %s and %s, they must match", in.Name, zm.Arr, zn.Arr) } if zm.Arr < ExtArrH || zm.Arr > ExtArrD { return nil, fmt.Errorf("%s: the wide sources carry arrangement %s, want .H, .S or .D", in.Name, zm.Arr) } if zd.Arr != zm.Arr-1 { return nil, fmt.Errorf("%s: the destination carries arrangement %s, want %s", in.Name, zd.Arr, zm.Arr-1) } size, _ := zm.Arr.sizeBits() word := in.Word word = extSet(word, extFieldRm, uint32(zm.Reg)) word = extSet(word, extFieldRn, uint32(zn.Reg)) word = extSet(word, extFieldRd, uint32(zd.Reg)) word = extSet(word, in.Size, size) return extWordLE(word), nil } // encodeQuadReduce fills the SVE2.1 quadword reduction, the accumulator // first: Zdn.T, Pg (bare), Vn.T2. The scalable vector register accumulates // the reduction of the quadword vector, whose counted spelling (.B16, .H8, // .S4, .D2) names the lane width the class reduces over and must match the // accumulator's arrangement; the encoding carries the accumulator's own // size field. The fields mirror the reduction class: Zdn in the // first-source slot, the predicate in the narrow governing field, the // vector in the destination slot. func (in ExtInstr) encodeQuadReduce(ops []ExtOperand) ([]byte, error) { zdn, pg, vn := ops[0], ops[1], ops[2] if err := in.zVector(zdn, 1); err != nil { return nil, err } if err := in.barePredicate(pg, 2, 0, 7); err != nil { return nil, err } if vn.Kind != ExtVReg { return nil, fmt.Errorf("%s: operand 3 wants a SIMD register, got %s", in.Name, vn.Kind) } if vn.Reg < 0 || vn.Reg > 31 { return nil, fmt.Errorf("%s: operand 3 is V%d, outside V0-V31", in.Name, vn.Reg) } if vn.Qual != ExtQualNone { return nil, fmt.Errorf("%s: operand 3 takes no qualifier, got %q", in.Name, vn.Qual) } if vn.Arr == ExtArrNone { return nil, fmt.Errorf("%s: operand 3 carries no quadword suffix, want .B16, .H8, .S4 or .D2", in.Name) } if vn.Arr != zdn.Arr { return nil, fmt.Errorf("%s: operand 3 carries arrangement %s, want %s", in.Name, vn.Arr, zdn.Arr) } size, err := in.zSize(zdn.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldRn, uint32(zdn.Reg)) word = extSet(word, extFieldPgN, uint32(pg.Reg)) word = extSet(word, extFieldRd, uint32(vn.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // encodeShiftWide fills the wide-vector shift: Zm.D, Zn.T, Zd.T. The shift // amounts ride a double-width vector locked to .D while the shifted data // carries one shared narrower arrangement, which feeds the size field. func (in ExtInstr) encodeShiftWide(ops []ExtOperand) ([]byte, error) { zm, zn, zd := ops[0], ops[1], ops[2] if err := in.zVector(zm, 1); err != nil { return nil, err } if zm.Arr != ExtArrD { return nil, fmt.Errorf("%s: operand 1 carries arrangement %s, want .D", in.Name, zm.Arr) } if err := in.zVector(zn, 2); err != nil { return nil, err } if err := in.zVector(zd, 3); err != nil { return nil, err } if zn.Arr != zd.Arr { return nil, fmt.Errorf("%s: operands 2 and 3 carry arrangements %s and %s, they must match", in.Name, zn.Arr, zd.Arr) } size, err := in.zSize(zn.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldRm, uint32(zm.Reg)) word = extSet(word, extFieldRn, uint32(zn.Reg)) word = extSet(word, extFieldRd, uint32(zd.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } // encodeThreeSource fills the SVE2 three-source bitwise form: Za.D, Zm.D, // Zdn.D, Zdn.D, the destination read back, the whole class locked to // quadwords. Operands 3 and 4 name the same register and the encoding // carries it once, in the destination slot. func (in ExtInstr) encodeThreeSource(ops []ExtOperand) ([]byte, error) { za, zm, zdn := ops[0], ops[1], ops[2] if err := in.zVector(za, 1); err != nil { return nil, err } if err := in.zVector(zm, 2); err != nil { return nil, err } if err := in.zVector(zdn, 3); err != nil { return nil, err } if err := in.zVector(ops[3], 4); err != nil { return nil, err } if ops[3].Reg != zdn.Reg || ops[3].Arr != zdn.Arr { return nil, fmt.Errorf("%s: operands 3 and 4 are the same register Zdn, got Z%d and Z%d", in.Name, zdn.Reg, ops[3].Reg) } word := in.Word word = extSet(word, extFieldRn, uint32(za.Reg)) word = extSet(word, extFieldRm, uint32(zm.Reg)) word = extSet(word, extFieldRd, uint32(zdn.Reg)) return extWordLE(word), nil } // encodeConvert fills the SVE2 BFloat16 convert with a governing // predicate: Zn.S, Pg{M or Z}, Zd.H, the source locked to .S and the // destination to .H, the qualifier the row's PgQual names. func (in ExtInstr) encodeConvert(ops []ExtOperand) ([]byte, error) { if err := in.zVector(ops[0], 1); err != nil { return nil, err } if ops[0].Arr != ExtArrS { return nil, fmt.Errorf("%s: operand 1 carries arrangement %s, want .S", in.Name, ops[0].Arr) } pg := ops[1] if err := in.predicateOperand(pg, 2, 0, 7, ExtArrNone); err != nil { return nil, err } pg.Arr = ExtArrNone want := in.PgQual if want != ExtQualMerging && want != ExtQualZeroing { want = ExtQualMerging } if pg.Qual != want { return nil, fmt.Errorf("%s: operand 2 wants the %s qualifier, got %q", in.Name, want.String(), pg.Qual) } if err := in.zVector(ops[2], 3); err != nil { return nil, err } if ops[2].Arr != ExtArrH { return nil, fmt.Errorf("%s: operand 3 carries arrangement %s, want .H", in.Name, ops[2].Arr) } word := in.Word word = extSet(word, extFieldPn, uint32(ops[0].Reg)) word = extSet(word, extFieldPgN, uint32(pg.Reg)) word = extSet(word, extFieldRd, uint32(ops[2].Reg)) return extWordLE(word), nil } // encodeMulPred fills the SVE2 BFloat16 multiply-accumulate with an // independent destination: Zm.H, Zn.H, Pg/M, Zda.H. func (in ExtInstr) encodeMulPred(ops []ExtOperand) ([]byte, error) { zm, zn, pg, zda := ops[0], ops[1], ops[2], ops[3] if err := in.zVector(zm, 1); err != nil { return nil, err } if zm.Arr != ExtArrH { return nil, fmt.Errorf("%s: operand 1 carries arrangement %s, want .H", in.Name, zm.Arr) } if err := in.zVector(zn, 2); err != nil { return nil, err } if zn.Arr != ExtArrH { return nil, fmt.Errorf("%s: operand 2 carries arrangement %s, want .H", in.Name, zn.Arr) } if err := in.predicateOperand(pg, 3, 0, 7, ExtArrNone); err != nil { return nil, err } if pg.Qual != ExtQualMerging { return nil, fmt.Errorf("%s: operand 3 wants the merging qualifier, got %q", in.Name, pg.Qual) } if err := in.zVector(zda, 4); err != nil { return nil, err } if zda.Arr != ExtArrH { return nil, fmt.Errorf("%s: operand 4 carries arrangement %s, want .H", in.Name, zda.Arr) } word := in.Word word = extSet(word, extFieldRm, uint32(zm.Reg)) word = extSet(word, extFieldRn, uint32(zn.Reg)) word = extSet(word, extFieldPgN, uint32(pg.Reg)) word = extSet(word, extFieldRd, uint32(zda.Reg)) return extWordLE(word), nil } // encodeLongMul fills the SVE2 BFloat16 lengthened multiply: Za.H, Zn.H, // Zm.S, the two halfword vectors under the row's Arr and the wide source // one step above it. // encodeVLArith fills the vector-length arithmetic: imm, Rn|SP, Rd|SP. // The signed imm6 counts multiples of the vector length; the register // slots spell RSP, never a plain R31. func (in ExtInstr) encodeVLArith(ops []ExtOperand) ([]byte, error) { imm, rn, rd := ops[0], ops[1], ops[2] if imm.Kind != ExtImm { return nil, fmt.Errorf("%s: operand 1 wants an immediate, got %s", in.Name, imm.Kind) } if imm.Imm < -32 || imm.Imm > 31 { return nil, fmt.Errorf("%s: immediate %d is outside the signed 6-bit range -32..31", in.Name, imm.Imm) } if err := in.generalOperand(rn, 2, 2); err != nil { return nil, err } if err := in.generalOperand(rd, 3, 2); err != nil { return nil, err } word := in.Word word = extSet(word, extFieldImm6, uint32(imm.Imm)) word = extSet(word, extFieldRm, uint32(rn.Reg)) word = extSet(word, extFieldRd, uint32(rd.Reg)) return extWordLE(word), nil } // encodeVLRead fills the vector-length read: imm, Rd (R0-R30). func (in ExtInstr) encodeVLRead(ops []ExtOperand) ([]byte, error) { imm, rd := ops[0], ops[1] if imm.Kind != ExtImm { return nil, fmt.Errorf("%s: operand 1 wants an immediate, got %s", in.Name, imm.Kind) } if imm.Imm < -32 || imm.Imm > 31 { return nil, fmt.Errorf("%s: immediate %d is outside the signed 6-bit range -32..31", in.Name, imm.Imm) } if err := in.generalOperand(rd, 2, 0); err != nil { return nil, err } word := in.Word word = extSet(word, extFieldImm6, uint32(imm.Imm)) word = extSet(word, extFieldRd, uint32(rd.Reg)) return extWordLE(word), nil } // encodeCompare fills the SVE2 compare forms, the shared-arrangement and // the wide shape alike: Zm, Zn, Pg/Z, Pd. The comparison writes the // zeroing predicate P0-P7; under the wide shape the magnitudes ride the // double-width vector locked to .D. Fields: Zm at bits 16..20, Zn in the // first-source slot, Pg narrow, Pd in the four-bit destination slot. func (in ExtInstr) encodeCompare(ops []ExtOperand) ([]byte, error) { zm, zn, pg, pd := ops[0], ops[1], ops[2], ops[3] if err := in.zVector(zm, 1); err != nil { return nil, err } if in.Form == ExtFormCompareWide { if zm.Arr != ExtArrD { return nil, fmt.Errorf("%s: operand 1 carries arrangement %s, want .D", in.Name, zm.Arr) } } if err := in.zVector(zn, 2); err != nil { return nil, err } if in.Form == ExtFormCompare && zn.Arr != zm.Arr { return nil, fmt.Errorf("%s: operands 1 and 2 carry arrangements %s and %s, they must match", in.Name, zm.Arr, zn.Arr) } if in.Form == ExtFormCompareWide { if zn.Arr == ExtArrD { return nil, fmt.Errorf("%s: operand 2 carries arrangement .D, want .B, .H or .S", in.Name) } } if err := in.predicateOperand(pg, 3, 0, 7, ExtArrNone); err != nil { return nil, err } if pg.Qual != ExtQualZeroing { return nil, fmt.Errorf("%s: operand 3 wants the zeroing qualifier, got %q", in.Name, pg.Qual) } if pd.Kind != ExtPReg { return nil, fmt.Errorf("%s: operand 4 wants a predicate register, got %s", in.Name, pd.Kind) } if pd.Reg < 0 || pd.Reg > 15 { return nil, fmt.Errorf("%s: operand 4 is P%d, outside P0-P15", in.Name, pd.Reg) } if in.Form == ExtFormCompare && pd.Arr != zn.Arr { return nil, fmt.Errorf("%s: operand 4 carries arrangement %s, want %s", in.Name, pd.Arr, zn.Arr) } size, err := in.zSize(zn.Arr) if err != nil { return nil, err } word := in.Word word = extSet(word, extFieldRm, uint32(zm.Reg)) word = extSet(word, extFieldRn, uint32(zn.Reg)) word = extSet(word, extFieldPgN, uint32(pg.Reg)) word = extSet(word, extFieldPd, uint32(pd.Reg)) if size != 0 { word = extSet(word, in.Size, size) } return extWordLE(word), nil } func (in ExtInstr) encodeLongMul(ops []ExtOperand) ([]byte, error) { za, zn, zm := ops[0], ops[1], ops[2] if err := in.zVector(za, 1); err != nil { return nil, err } if in.Arr != ExtArrNone && za.Arr != in.Arr { return nil, fmt.Errorf("%s: operand 1 carries arrangement %s, want %s", in.Name, za.Arr, in.Arr) } if err := in.zVector(zn, 2); err != nil { return nil, err } if zn.Arr != za.Arr { return nil, fmt.Errorf("%s: operands 1 and 2 carry arrangements %s and %s, they must match", in.Name, za.Arr, zn.Arr) } if zm.Kind != ExtZReg { return nil, fmt.Errorf("%s: operand 3 wants a scalable vector register, got %s", in.Name, zm.Kind) } if zm.Reg < 0 || zm.Reg > 31 { return nil, fmt.Errorf("%s: operand 3 is Z%d, outside Z0-Z31", in.Name, zm.Reg) } if zm.Arr != za.Arr+1 { return nil, fmt.Errorf("%s: operand 3 carries arrangement %s, want %s", in.Name, zm.Arr, za.Arr+1) } word := in.Word word = extSet(word, extFieldRm, uint32(za.Reg)) word = extSet(word, extFieldRn, uint32(zn.Reg)) word = extSet(word, extFieldRd, uint32(zm.Reg)) return extWordLE(word), nil } // sharedSize returns the one element-size encoding the given arrangements // agree on, or an error when any operand is bare, they disagree, or the // arrangement has no size field. func (in ExtInstr) sharedSize(arrs ...ExtArrangement) (uint32, error) { arr := arrs[0] for i, a := range arrs { if a == ExtArrNone { return 0, fmt.Errorf("%s: operand %d carries no arrangement suffix", in.Name, i+1) } if a != arr { return 0, fmt.Errorf("%s: operand %d carries arrangement %s, want %s", in.Name, i+1, a, arr) } } size, ok := arr.sizeBits() if !ok { return 0, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, arr) } return size, nil } // setDestAndSize fills the destructive destination register and the size // field from the arrangement the vector carries. func (in ExtInstr) setDestAndSize(word uint32, zdn ExtOperand) (uint32, error) { if zdn.Kind != ExtZReg { return 0, fmt.Errorf("%s: operand 2 wants a scalable vector register, got %s", in.Name, zdn.Kind) } if zdn.Reg < 0 || zdn.Reg > 31 { return 0, fmt.Errorf("%s: operand 2 is Z%d, outside Z0-Z31", in.Name, zdn.Reg) } size, ok := zdn.Arr.sizeBits() if !ok { return 0, fmt.Errorf("%s: arrangement %s has no size encoding in this class", in.Name, zdn.Arr) } word = extSet(word, extFieldRd, uint32(zdn.Reg)) word = extSet(word, in.Size, size) return word, nil } // sharedArrangement returns the one arrangement all vector operands carry, or // an error when any operand is bare or they disagree. func (in ExtInstr) sharedArrangement(ops []ExtOperand) (ExtArrangement, error) { arr := ops[0].Arr for i, op := range ops { if op.Arr == ExtArrNone { return 0, fmt.Errorf("%s: operand %d carries no arrangement suffix", in.Name, i+1) } if op.Arr != arr { return 0, fmt.Errorf("%s: operand %d carries arrangement %s, want %s", in.Name, i+1, op.Arr, arr) } } return arr, nil } // extWordLE returns a 32-bit encoding word as 4 little-endian bytes. func extWordLE(w uint32) []byte { return []byte{byte(w), byte(w >> 8), byte(w >> 16), byte(w >> 24)} } // --- the arm64 SVE/SVE2 table ------------------------------------------------ // arm64Extensions is the extended instruction layer of arm64: the SVE and // SVE2 integer add/subtract/multiply family. The Go toolchain knows none of // these; the encodings are transcribed from the ARM Architecture Reference // Manual (DDI 0487J, Part C, Chapter C8, the alphabetical list of SVE // instructions) and cross-checked against the GNU assembler's and LLVM's // published encodings. var arm64Extensions = []ExtInstr{ // Unpredicated three-vector forms: ADD Z0.S, Z1.S, Z2.S. {Name: "ADD", Summary: "Add scalable vector elements, unpredicated", Word: 0x04200000, Form: ExtFormVectors, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: ADD (vectors, unpredicated)"}, {Name: "SUB", Summary: "Subtract scalable vector elements, unpredicated", Word: 0x04200400, Form: ExtFormVectors, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: SUB (vectors, unpredicated)"}, {Name: "SQADD", Summary: "Add signed saturating scalable vector elements, unpredicated", Word: 0x04201000, Form: ExtFormVectors, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: SQADD (vectors, unpredicated)"}, {Name: "UQADD", Summary: "Add unsigned saturating scalable vector elements, unpredicated", Word: 0x04201400, Form: ExtFormVectors, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: UQADD (vectors, unpredicated)"}, {Name: "SQSUB", Summary: "Subtract signed saturating scalable vector elements, unpredicated", Word: 0x04201800, Form: ExtFormVectors, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: SQSUB (vectors, unpredicated)"}, {Name: "UQSUB", Summary: "Subtract unsigned saturating scalable vector elements, unpredicated", Word: 0x04201c00, Form: ExtFormVectors, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: UQSUB (vectors, unpredicated)"}, {Name: "MUL", Summary: "Multiply scalable vector elements, unpredicated", Word: 0x04206000, Form: ExtFormVectors, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: MUL (vectors, unpredicated)"}, {Name: "SMULH", Summary: "Multiply signed scalable vector elements, keeping the high half, unpredicated", Word: 0x04206800, Form: ExtFormVectors, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: SMULH (vectors, unpredicated)"}, {Name: "UMULH", Summary: "Multiply unsigned scalable vector elements, keeping the high half, unpredicated", Word: 0x04206c00, Form: ExtFormVectors, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: UMULH (vectors, unpredicated)"}, // Governed destructive forms, merging: ADD Z1.S, P0/M, Z0.S. {Name: "ADD", Summary: "Add scalable vector elements under a governing predicate, merging", Word: 0x04000000, Form: ExtFormPredicated, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: ADD (vectors, predicated)"}, {Name: "SUB", Summary: "Subtract scalable vector elements under a governing predicate, merging", Word: 0x04010000, Form: ExtFormPredicated, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: SUB (vectors, predicated)"}, {Name: "SUBR", Summary: "Reverse-subtract scalable vector elements under a governing predicate, merging", Word: 0x04030000, Form: ExtFormPredicated, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: SUBR (vectors, predicated)"}, {Name: "MUL", Summary: "Multiply scalable vector elements under a governing predicate, merging", Word: 0x04100000, Form: ExtFormPredicated, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: MUL (vectors, predicated)"}, {Name: "SMULH", Summary: "Multiply signed scalable vector elements, keeping the high half, under a governing predicate, merging", Word: 0x04120000, Form: ExtFormPredicated, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: SMULH (vectors, predicated)"}, {Name: "UMULH", Summary: "Multiply unsigned scalable vector elements, keeping the high half, under a governing predicate, merging", Word: 0x04130000, Form: ExtFormPredicated, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: UMULH (vectors, predicated)"}, // Immediate forms: ADD $255, Z0.S. {Name: "ADD", Summary: "Add an unsigned immediate to scalable vector elements", Word: 0x2520c000, Form: ExtFormImmediate, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: ADD (vectors, immediate)"}, {Name: "SUB", Summary: "Subtract an unsigned immediate from scalable vector elements", Word: 0x2521c000, Form: ExtFormImmediate, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: SUB (vectors, immediate)"}, {Name: "SUBR", Summary: "Subtract scalable vector elements from an unsigned immediate", Word: 0x2523c000, Form: ExtFormImmediate, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: SUBR (vectors, immediate)"}, {Name: "SQADD", Summary: "Add a signed saturating unsigned immediate to scalable vector elements", Word: 0x2524c000, Form: ExtFormImmediate, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: SQADD (vectors, immediate)"}, {Name: "UQADD", Summary: "Add an unsigned saturating immediate to scalable vector elements", Word: 0x2525c000, Form: ExtFormImmediate, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: UQADD (vectors, immediate)"}, {Name: "SQSUB", Summary: "Subtract an unsigned immediate from scalable vector elements with signed saturation", Word: 0x2526c000, Form: ExtFormImmediate, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: SQSUB (vectors, immediate)"}, {Name: "UQSUB", Summary: "Subtract an unsigned immediate from scalable vector elements with unsigned saturation", Word: 0x2527c000, Form: ExtFormImmediate, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: UQSUB (vectors, immediate)"}, // The signed immediate of the multiply class: MUL $-128, Z0.B. {Name: "MUL", Summary: "Multiply scalable vector elements by a signed immediate", Word: 0x2530c000, Form: ExtFormSignedImmediate, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J, C8.2 SVE instruction descriptions: MUL (vectors, immediate)"}, // --- the SVE and SVE2.1 predicate family --------------------------------- // // The classes below operate on predicates and predicate-as-counter // registers. Their encodings follow the field layouts the ARM // Architecture Reference Manual's SVE2.1 predicate classes give, as laid // out in the toolchain's generated encoding table // (cmd/internal/obj/arm64/inst_gen.go, itself generated by // x/arch/arm64/instgen from Arm's official ISA description) and in its // generated corpus file arm64sveenc.s: the golden test pins every // corpus line of each class byte for byte, so no class rests on // transcription alone. The toolchain's spellings are kept, including // its P prefix on the predicate-register instructions (PRDFFR for // RDFFR, PPTRUE for PTRUE, PREV for the predicate REV), because those // are the names the corpus assembles under. // Predicate logical operations, SVE2.1: PAND P4.B, P2.B, P1.Z, P14.B. {Name: "PAND", Summary: "And predicates over a governing predicate's active lanes", Word: 0x25004000, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PAND (predicates); inst_gen.go + arm64sveenc.s"}, {Name: "PANDS", Summary: "And predicates, setting the condition flags", Word: 0x25404000, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PANDS (predicates); inst_gen.go + arm64sveenc.s"}, {Name: "PBIC", Summary: "And-complement predicates over a governing predicate's active lanes", Word: 0x25004010, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PBIC (predicates); inst_gen.go + arm64sveenc.s"}, {Name: "PBICS", Summary: "And-complement predicates, setting the condition flags", Word: 0x25404010, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PBICS (predicates); inst_gen.go + arm64sveenc.s"}, {Name: "PEOR", Summary: "Exclusive-or predicates over a governing predicate's active lanes", Word: 0x25004200, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PEOR (predicates); inst_gen.go + arm64sveenc.s"}, {Name: "PEORS", Summary: "Exclusive-or predicates, setting the condition flags", Word: 0x25404200, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PEORS (predicates); inst_gen.go + arm64sveenc.s"}, {Name: "PNAND", Summary: "And-complement two predicates into one", Word: 0x25804210, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PNAND (predicates); inst_gen.go + arm64sveenc.s"}, {Name: "PNANDS", Summary: "And-complement two predicates, setting the condition flags", Word: 0x25c04210, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PNANDS (predicates); inst_gen.go + arm64sveenc.s"}, {Name: "PNOR", Summary: "Or-complement two predicates into one", Word: 0x25804200, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PNOR (predicates); inst_gen.go + arm64sveenc.s"}, {Name: "PNORS", Summary: "Or-complement two predicates, setting the condition flags", Word: 0x25c04200, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PNORS (predicates); inst_gen.go + arm64sveenc.s"}, {Name: "PORN", Summary: "Or-complement two predicates into one, complement reversed", Word: 0x25804010, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PORN (predicates); inst_gen.go + arm64sveenc.s"}, {Name: "PORNS", Summary: "Or-complement two predicates, complement reversed, setting the flags", Word: 0x25c04010, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PORNS (predicates); inst_gen.go + arm64sveenc.s"}, {Name: "PORR", Summary: "Or two predicates into one", Word: 0x25804000, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: POR (predicates) as PORR; inst_gen.go + arm64sveenc.s"}, {Name: "PORRS", Summary: "Or two predicates, setting the condition flags", Word: 0x25c04000, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PORS (predicates) as PORR; inst_gen.go + arm64sveenc.s"}, {Name: "PSEL", Summary: "Select predicate elements by a governing predicate", Word: 0x25004210, Form: ExtFormPredicateSelect, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PSEL (predicates); inst_gen.go + arm64sveenc.s"}, // Break operations, SVE2.1 generalised breaks. {Name: "PBRKA", Summary: "Break after the first true of the governing predicate", Word: 0x25104000, Form: ExtFormPredicateBreak, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PBRKA (break after first true); inst_gen.go + arm64sveenc.s"}, {Name: "PBRKAS", Summary: "Break after the first false, setting the condition flags", Word: 0x25504000, Form: ExtFormPredicateBreakZero, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PBRKAS (break after first false); inst_gen.go + arm64sveenc.s"}, {Name: "PBRKB", Summary: "Break before the first true of the governing predicate", Word: 0x25904000, Form: ExtFormPredicateBreak, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PBRKB (break before first true); inst_gen.go + arm64sveenc.s"}, {Name: "PBRKBS", Summary: "Break before the first false, setting the condition flags", Word: 0x25d04000, Form: ExtFormPredicateBreakZero, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PBRKBS (break before first false); inst_gen.go + arm64sveenc.s"}, {Name: "PBRKN", Summary: "Break after the first true of the second source", Word: 0x25184000, Form: ExtFormPredicateLogicalDest, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PBRKN (break after first true); inst_gen.go + arm64sveenc.s"}, {Name: "PBRKNS", Summary: "Break after the first true of the second source, setting the flags", Word: 0x25584000, Form: ExtFormPredicateLogicalDest, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PBRKNS; inst_gen.go + arm64sveenc.s"}, {Name: "PBRKPA", Summary: "Break after the first true, preserving the first source's leading lanes", Word: 0x2500c000, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PBRKPA (break propagating after); inst_gen.go + arm64sveenc.s"}, {Name: "PBRKPAS", Summary: "Break propagating after the first false, setting the flags", Word: 0x2540c000, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PBRKPAS; inst_gen.go + arm64sveenc.s"}, {Name: "PBRKPB", Summary: "Break propagating before the first true", Word: 0x2500c010, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PBRKPB (break propagating before); inst_gen.go + arm64sveenc.s"}, {Name: "PBRKPBS", Summary: "Break propagating before the first false, setting the flags", Word: 0x2540c010, Form: ExtFormPredicateLogical, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PBRKPBS; inst_gen.go + arm64sveenc.s"}, // Predicate permutations, SVE2.1. {Name: "PTRN1", Summary: "Transpose odd predicate elements", Word: 0x05205000, Form: ExtFormPredicatePermute, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: TRN1 (predicates) as PTRN1; inst_gen.go + arm64sveenc.s"}, {Name: "PTRN2", Summary: "Transpose even predicate elements", Word: 0x05205400, Form: ExtFormPredicatePermute, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: TRN2 (predicates) as PTRN2; inst_gen.go + arm64sveenc.s"}, {Name: "PUZP1", Summary: "Unzip odd predicate elements", Word: 0x05204800, Form: ExtFormPredicatePermute, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: UZP1 (predicates) as PUZP1; inst_gen.go + arm64sveenc.s"}, {Name: "PUZP2", Summary: "Unzip even predicate elements", Word: 0x05204c00, Form: ExtFormPredicatePermute, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: UZP2 (predicates) as PUZP2; inst_gen.go + arm64sveenc.s"}, {Name: "PZIP1", Summary: "Zip odd predicate elements", Word: 0x05204000, Form: ExtFormPredicatePermute, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZIP1 (predicates) as PZIP1; inst_gen.go + arm64sveenc.s"}, {Name: "PZIP2", Summary: "Zip even predicate elements", Word: 0x05204400, Form: ExtFormPredicatePermute, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZIP2 (predicates) as PZIP2; inst_gen.go + arm64sveenc.s"}, // Predicate initialise, test and permute singles. {Name: "PPFALSE", Summary: "Initialise a predicate to false", Word: 0x2518e400, Form: ExtFormPredicateOne, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: PFALSE as PPFALSE; inst_gen.go + arm64sveenc.s"}, {Name: "PPFIRST", Summary: "Set the first active element of a predicate", Word: 0x2558c000, Form: ExtFormPredicateFirst, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: PFIRST as PPFIRST; inst_gen.go + arm64sveenc.s"}, {Name: "PPNEXT", Summary: "Set the next active element of a predicate", Word: 0x2519c400, Form: ExtFormPredicateNext, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: PNEXT as PPNEXT; inst_gen.go + arm64sveenc.s"}, {Name: "PPTEST", Summary: "Test a predicate against a governing predicate, setting the flags", Word: 0x2550c000, Form: ExtFormPredicateTest, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: PTEST as PPTEST; inst_gen.go + arm64sveenc.s"}, {Name: "PPTRUE", Summary: "Initialise a predicate-as-counter register from a pattern", Word: 0x25207810, Form: ExtFormPredicateCounter, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: PTRUE (counter form) as PPTRUE; inst_gen.go + arm64sveenc.s"}, {Name: "PPUNPKHI", Summary: "Unpack the even elements of a half-word predicate", Word: 0x05314000, Form: ExtFormPredicateUnpack, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: PUNPKHI as PPUNPKHI; inst_gen.go + arm64sveenc.s"}, {Name: "PPUNPKLO", Summary: "Unpack the odd elements of a half-word predicate", Word: 0x05304000, Form: ExtFormPredicateUnpack, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: PUNPKLO as PPUNPKLO; inst_gen.go + arm64sveenc.s"}, // First-fault register and predicate reverse. {Name: "PRDFFR", Summary: "Read the first-fault register to a predicate, zeroing", Word: 0x2518f000, Form: ExtFormPredicateFFRRead, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: RDFFR (predicated) as PRDFFR; inst_gen.go + arm64sveenc.s"}, {Name: "PRDFFR", Summary: "Read the first-fault register to a predicate whole", Word: 0x2519f000, Form: ExtFormPredicateOne, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: RDFFR (unpredicated) as PRDFFR; inst_gen.go + arm64sveenc.s"}, {Name: "PRDFFRS", Summary: "Read the first-fault register to a predicate, zeroing, setting the flags", Word: 0x2558f000, Form: ExtFormPredicateFFRRead, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: RDFFRS as PRDFFRS; inst_gen.go + arm64sveenc.s"}, {Name: "PWRFFR", Summary: "Write the first-fault register from a predicate", Word: 0x25289000, Form: ExtFormPredicateWrite, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WRFFR as PWRFFR; inst_gen.go + arm64sveenc.s"}, {Name: "PREV", Summary: "Reverse the elements of a predicate", Word: 0x05344000, Form: ExtFormPredicateMove, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: REV (predicate) as PREV; inst_gen.go + arm64sveenc.s"}, {Name: "SETFFR", Summary: "Set the first-fault register to all true", Word: 0x252c9000, Form: ExtFormNone, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: SETFFR; inst_gen.go + arm64sveenc.s"}, // While compares: build a predicate from a scalar loop condition. {Name: "PWHILEGE", Summary: "Build a predicate while the signed greater-or-equal comparison holds", Word: 0x25201000, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILEGE as PWHILEGE; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILEGT", Summary: "Build a predicate while the signed greater comparison holds", Word: 0x25201010, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILEGT as PWHILEGT; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILEHI", Summary: "Build a predicate while the unsigned higher comparison holds", Word: 0x25201810, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILEHI as PWHILEHI; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILEHS", Summary: "Build a predicate while the unsigned higher-or-same comparison holds", Word: 0x25201800, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILEHS as PWHILEHS; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILELE", Summary: "Build a predicate while the signed less-or-equal comparison holds", Word: 0x25201410, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILELE as PWHILELE; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILELO", Summary: "Build a predicate while the unsigned lower comparison holds", Word: 0x25201c00, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILELO as PWHILELO; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILELS", Summary: "Build a predicate while the unsigned lower-or-same comparison holds", Word: 0x25201c10, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILELS as PWHILELS; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILELT", Summary: "Build a predicate while the signed less comparison holds", Word: 0x25201400, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILELT as PWHILELT; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILERW", Summary: "Build a predicate over a read-write region", Word: 0x25203010, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: PWHILERW (SVE2.1); inst_gen.go + arm64sveenc.s"}, {Name: "PWHILEWR", Summary: "Build a predicate over a write region", Word: 0x25203000, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: PWHILEWR (SVE2.1); inst_gen.go + arm64sveenc.s"}, // --- the SVE2.1 Z-alias permutations, copies and unary forms ------------- // // The Z-prefixed names are the toolchain corpus spellings of the SVE2.1 // alias families: the unary and binary predicated forms, the immediate // aliases, the vector permutations and selects, and the register-copy // forms. Provenance as above: the toolchain encoding table and its // generated corpus agree with the manual layouts, and the golden test // pins every corpus line of each covered class. {Name: "ZABS", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x0416a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZABS; inst_gen.go + arm64sveenc.s"}, {Name: "ZREVB", Summary: "Reverse byte order within elements, predicated", Word: 0x05248000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZREVB; inst_gen.go + arm64sveenc.s"}, {Name: "ZREVB", Summary: "Reverse byte order within elements, zeroing", Word: 0x0524a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZREVB; inst_gen.go + arm64sveenc.s"}, {Name: "ZREVH", Summary: "Reverse halfword order within elements, predicated", Word: 0x05a58000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZREVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZREVH", Summary: "Reverse halfword order within elements, zeroing", Word: 0x05a5a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZREVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZSXTB", Summary: "Sign-extend bytes to the element width, predicated", Word: 0x0410a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSXTB; inst_gen.go + arm64sveenc.s"}, {Name: "ZSXTB", Summary: "Sign-extend bytes to the element width, zeroing", Word: 0x0400a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSXTB; inst_gen.go + arm64sveenc.s"}, {Name: "ZSXTH", Summary: "Sign-extend halfwords to the element width, predicated", Word: 0x0492a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSXTH; inst_gen.go + arm64sveenc.s"}, {Name: "ZSXTH", Summary: "Sign-extend halfwords to the element width, zeroing", Word: 0x0482a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSXTH; inst_gen.go + arm64sveenc.s"}, {Name: "ZUXTB", Summary: "Zero-extend bytes to the element width, predicated", Word: 0x0411a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUXTB; inst_gen.go + arm64sveenc.s"}, {Name: "ZUXTB", Summary: "Zero-extend bytes to the element width, zeroing", Word: 0x0401a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUXTB; inst_gen.go + arm64sveenc.s"}, {Name: "ZUXTH", Summary: "Zero-extend halfwords to the element width, predicated", Word: 0x0493a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUXTH; inst_gen.go + arm64sveenc.s"}, {Name: "ZUXTH", Summary: "Zero-extend halfwords to the element width, zeroing", Word: 0x0483a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUXTH; inst_gen.go + arm64sveenc.s"}, {Name: "ZABS", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x0406a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZABS; inst_gen.go + arm64sveenc.s"}, {Name: "ZADD", Summary: "Z-alias of the predicated binary form, source copy spelled", Word: 0x04000000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZADD; inst_gen.go + arm64sveenc.s"}, {Name: "ZADD", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x04200000, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZADD; inst_gen.go + arm64sveenc.s"}, {Name: "ZADD", Summary: "Z-alias of the immediate form, destination copy spelled", Word: 0x2520c000, Form: ExtFormZImmediateSource, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZADD; inst_gen.go + arm64sveenc.s"}, {Name: "ZAND", Summary: "Z-alias of the unpredicated three-vector form, locked to .D", Word: 0x04203000, Form: ExtFormVectorsZm, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZAND; inst_gen.go + arm64sveenc.s"}, {Name: "ZAND", Summary: "Z-alias of the predicated binary form, source copy spelled", Word: 0x041a0000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZAND; inst_gen.go + arm64sveenc.s"}, {Name: "ZBIC", Summary: "Z-alias of the unpredicated three-vector form, locked to .D", Word: 0x04e03000, Form: ExtFormVectorsZm, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZBIC; inst_gen.go + arm64sveenc.s"}, {Name: "ZBIC", Summary: "Z-alias of the predicated binary form, source copy spelled", Word: 0x041b0000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZBIC; inst_gen.go + arm64sveenc.s"}, {Name: "ZCLS", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x0418a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZCLS; inst_gen.go + arm64sveenc.s"}, {Name: "ZCLS", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x0408a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZCLS; inst_gen.go + arm64sveenc.s"}, {Name: "ZCLZ", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x0419a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZCLZ; inst_gen.go + arm64sveenc.s"}, {Name: "ZCLZ", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x0409a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZCLZ; inst_gen.go + arm64sveenc.s"}, {Name: "ZCNOT", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x041ba000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZCNOT; inst_gen.go + arm64sveenc.s"}, {Name: "ZCNOT", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x040ba000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZCNOT; inst_gen.go + arm64sveenc.s"}, {Name: "ZCNT", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x041aa000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZCNT; inst_gen.go + arm64sveenc.s"}, {Name: "ZCNT", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x040aa000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZCNT; inst_gen.go + arm64sveenc.s"}, {Name: "ZCOMPACT", Summary: "Compact or expand over a governing predicate", Word: 0x05218000, Form: ExtFormZGov, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZCOMPACT; inst_gen.go + arm64sveenc.s"}, {Name: "ZDECP", Summary: "Decrement a vector by a predicate's active elements", Word: 0x252d8000, Form: ExtFormCountPnVec, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: DECP (vector) as ZDECP; inst_gen.go + arm64sveenc.s"}, {Name: "ZDUP", Summary: "Copy or insert a general register, .D locked", Word: 0x05e03800, Form: ExtFormZFromGeneral, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZDUP; inst_gen.go + arm64sveenc.s"}, {Name: "ZEOR", Summary: "Z-alias of the unpredicated three-vector form, locked to .D", Word: 0x04a03000, Form: ExtFormVectorsZm, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZEOR; inst_gen.go + arm64sveenc.s"}, {Name: "ZEOR", Summary: "Z-alias of the predicated binary form, source copy spelled", Word: 0x04190000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZEOR; inst_gen.go + arm64sveenc.s"}, {Name: "ZEXPAND", Summary: "Compact or expand over a governing predicate", Word: 0x05318000, Form: ExtFormZGov, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZEXPAND; inst_gen.go + arm64sveenc.s"}, {Name: "ZINSR", Summary: "Copy or insert a general register, .D locked", Word: 0x05e43800, Form: ExtFormZFromGeneral, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZINSR; inst_gen.go + arm64sveenc.s"}, {Name: "ZLASTA", Summary: "Last active element into a register, .D locked", Word: 0x05e0a000, Form: ExtFormZLastReg, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZLASTA; inst_gen.go + arm64sveenc.s"}, {Name: "ZLASTB", Summary: "Last active element into a register, .D locked", Word: 0x05e1a000, Form: ExtFormZLastReg, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZLASTB; inst_gen.go + arm64sveenc.s"}, {Name: "ZMOVPRFX", Summary: "Z-alias of the predicated form, either qualifier, one encoding", Word: 0x04102000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualAny, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZMOVPRFX; inst_gen.go + arm64sveenc.s"}, {Name: "ZREVD", Summary: "Reverse the order of quadwords, zeroing", Word: 0x052ea000, Form: ExtFormZUnary, PgQual: ExtQualZeroing, Arr: ExtArrQ, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZREVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZREVW", Summary: "Reverse word order within doublewords, zeroing", Word: 0x05e6a000, Form: ExtFormZUnary, PgQual: ExtQualZeroing, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZREVW; inst_gen.go + arm64sveenc.s"}, {Name: "ZSXTW", Summary: "Sign-extend words to doublewords, zeroing", Word: 0x04c4a000, Form: ExtFormZUnary, PgQual: ExtQualZeroing, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSXTW; inst_gen.go + arm64sveenc.s"}, {Name: "ZUXTW", Summary: "Zero-extend words to doublewords, zeroing", Word: 0x04c5a000, Form: ExtFormZUnary, PgQual: ExtQualZeroing, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUXTW; inst_gen.go + arm64sveenc.s"}, {Name: "ZMOVPRFX", Summary: "MOVPRFX prefix spelling without arrangements", Word: 0x0420bc00, Form: ExtFormZMoveBare, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZMOVPRFX; inst_gen.go + arm64sveenc.s"}, {Name: "ZNEG", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x0417a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZNEG; inst_gen.go + arm64sveenc.s"}, {Name: "ZNEG", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x0407a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZNEG; inst_gen.go + arm64sveenc.s"}, {Name: "ZNOT", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x041ea000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZNOT; inst_gen.go + arm64sveenc.s"}, {Name: "ZNOT", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x040ea000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZNOT; inst_gen.go + arm64sveenc.s"}, {Name: "ZORR", Summary: "Z-alias of the unpredicated three-vector form, locked to .D", Word: 0x04603000, Form: ExtFormVectorsZm, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZORR; inst_gen.go + arm64sveenc.s"}, {Name: "ZORR", Summary: "Z-alias of the predicated binary form, source copy spelled", Word: 0x04180000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZORR; inst_gen.go + arm64sveenc.s"}, {Name: "ZRBIT", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x05278000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZRBIT; inst_gen.go + arm64sveenc.s"}, {Name: "ZRBIT", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x0527a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZRBIT; inst_gen.go + arm64sveenc.s"}, {Name: "ZREV", Summary: "Reverse the elements of a vector", Word: 0x05383800, Form: ExtFormZMove, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZREV; inst_gen.go + arm64sveenc.s"}, {Name: "ZREVD", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x052e8000, Form: ExtFormZUnary, PgQual: ExtQualMerging, Arr: ExtArrQ, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZREVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZREVD", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x052ea000, Form: ExtFormZUnary, PgQual: ExtQualZeroing, Arr: ExtArrQ, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZREVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZREVW", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x05e68000, Form: ExtFormZUnary, PgQual: ExtQualMerging, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZREVW; inst_gen.go + arm64sveenc.s"}, {Name: "ZREVW", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x05e6a000, Form: ExtFormZUnary, PgQual: ExtQualZeroing, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZREVW; inst_gen.go + arm64sveenc.s"}, {Name: "ZSEL", Summary: "Select vector elements by a predicate", Word: 0x0520c000, Form: ExtFormZSelect, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSEL; inst_gen.go + arm64sveenc.s"}, {Name: "ZSQABS", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x4408a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSQABS; inst_gen.go + arm64sveenc.s"}, {Name: "ZSQABS", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x440aa000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSQABS; inst_gen.go + arm64sveenc.s"}, {Name: "ZSQNEG", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x4409a000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSQNEG; inst_gen.go + arm64sveenc.s"}, {Name: "ZSQNEG", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x440ba000, Form: ExtFormZUnary, Size: extSizeBHSD, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSQNEG; inst_gen.go + arm64sveenc.s"}, {Name: "ZSUB", Summary: "Z-alias of the predicated binary form, source copy spelled", Word: 0x04010000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSUB; inst_gen.go + arm64sveenc.s"}, {Name: "ZSUB", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x04200400, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSUB; inst_gen.go + arm64sveenc.s"}, {Name: "ZSUB", Summary: "Z-alias of the immediate form, destination copy spelled", Word: 0x2521c000, Form: ExtFormZImmediateSource, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSUB; inst_gen.go + arm64sveenc.s"}, {Name: "ZSUBR", Summary: "Z-alias of the predicated binary form, source copy spelled", Word: 0x04030000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSUBR; inst_gen.go + arm64sveenc.s"}, {Name: "ZSUBR", Summary: "Z-alias of the immediate form, destination copy spelled", Word: 0x2523c000, Form: ExtFormZImmediateSource, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSUBR; inst_gen.go + arm64sveenc.s"}, {Name: "ZSUNPKHI", Summary: "Unpack a byte vector into a wider one", Word: 0x05313800, Form: ExtFormZUnpack, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSUNPKHI; inst_gen.go + arm64sveenc.s"}, {Name: "ZSUNPKLO", Summary: "Unpack a byte vector into a wider one", Word: 0x05303800, Form: ExtFormZUnpack, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSUNPKLO; inst_gen.go + arm64sveenc.s"}, {Name: "ZSXTW", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x04d4a000, Form: ExtFormZUnary, PgQual: ExtQualMerging, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSXTW; inst_gen.go + arm64sveenc.s"}, {Name: "ZSXTW", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x04c4a000, Form: ExtFormZUnary, PgQual: ExtQualZeroing, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSXTW; inst_gen.go + arm64sveenc.s"}, {Name: "ZTBX", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x05202c00, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZTBX; inst_gen.go + arm64sveenc.s"}, {Name: "ZTBXQ", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x05203400, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZTBXQ; inst_gen.go + arm64sveenc.s"}, {Name: "ZTRN1", Summary: "Z-alias of the unpredicated three-vector form, locked to .Q", Word: 0x05a01800, Form: ExtFormVectorsZm, Arr: ExtArrQ, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZTRN1; inst_gen.go + arm64sveenc.s"}, {Name: "ZTRN1", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x05207000, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZTRN1; inst_gen.go + arm64sveenc.s"}, {Name: "ZTRN2", Summary: "Z-alias of the unpredicated three-vector form, locked to .Q", Word: 0x05a01c00, Form: ExtFormVectorsZm, Arr: ExtArrQ, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZTRN2; inst_gen.go + arm64sveenc.s"}, {Name: "ZTRN2", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x05207400, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZTRN2; inst_gen.go + arm64sveenc.s"}, {Name: "ZUUNPKHI", Summary: "Unpack a byte vector into a wider one", Word: 0x05333800, Form: ExtFormZUnpack, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUUNPKHI; inst_gen.go + arm64sveenc.s"}, {Name: "ZUUNPKLO", Summary: "Unpack a byte vector into a wider one", Word: 0x05323800, Form: ExtFormZUnpack, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUUNPKLO; inst_gen.go + arm64sveenc.s"}, {Name: "ZUXTW", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x04d5a000, Form: ExtFormZUnary, PgQual: ExtQualMerging, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUXTW; inst_gen.go + arm64sveenc.s"}, {Name: "ZUXTW", Summary: "Z-alias of the predicated form, over a governing predicate", Word: 0x04c5a000, Form: ExtFormZUnary, PgQual: ExtQualZeroing, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUXTW; inst_gen.go + arm64sveenc.s"}, {Name: "ZUZP1", Summary: "Z-alias of the unpredicated three-vector form, locked to .Q", Word: 0x05a00800, Form: ExtFormVectorsZm, Arr: ExtArrQ, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUZP1; inst_gen.go + arm64sveenc.s"}, {Name: "ZUZP1", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x05206800, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUZP1; inst_gen.go + arm64sveenc.s"}, {Name: "ZUZP2", Summary: "Z-alias of the unpredicated three-vector form, locked to .Q", Word: 0x05a00c00, Form: ExtFormVectorsZm, Arr: ExtArrQ, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUZP2; inst_gen.go + arm64sveenc.s"}, {Name: "ZUZP2", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x05206c00, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUZP2; inst_gen.go + arm64sveenc.s"}, {Name: "ZUZPQ1", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x4400e800, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUZPQ1; inst_gen.go + arm64sveenc.s"}, {Name: "ZUZPQ2", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x4400ec00, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUZPQ2; inst_gen.go + arm64sveenc.s"}, {Name: "ZZIP1", Summary: "Z-alias of the unpredicated three-vector form, locked to .Q", Word: 0x05a00000, Form: ExtFormVectorsZm, Arr: ExtArrQ, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZZIP1; inst_gen.go + arm64sveenc.s"}, {Name: "ZZIP1", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x05206000, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZZIP1; inst_gen.go + arm64sveenc.s"}, {Name: "ZZIP2", Summary: "Z-alias of the unpredicated three-vector form, locked to .Q", Word: 0x05a00400, Form: ExtFormVectorsZm, Arr: ExtArrQ, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZZIP2; inst_gen.go + arm64sveenc.s"}, {Name: "ZZIP2", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x05206400, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZZIP2; inst_gen.go + arm64sveenc.s"}, {Name: "ZZIPQ1", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x4400e000, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZZIPQ1; inst_gen.go + arm64sveenc.s"}, {Name: "ZZIPQ2", Summary: "Z-alias of the unpredicated three-vector form", Word: 0x4400e400, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZZIPQ2; inst_gen.go + arm64sveenc.s"}, // --- the SVE2.1 narrowing two-to-one family ------------------------------ // // The add, rounding add, subtract and rounding subtract narrow steps: // two wide vectors combine and the destination keeps the high half of // each result, bottom or top. The sources carry .H, .S or .D and the // destination the arrangement one step below; one size field serves // both. Provenance as above: the toolchain encoding table and its // generated corpus, both produced from Arm's official ISA description, // and the golden test pins every corpus line of the family. {Name: "ZADDHNB", Summary: "Add narrow high, bottom half destination", Word: 0x45206000, Form: ExtFormNarrow, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZADDHNB; inst_gen.go + arm64sveenc.s"}, {Name: "ZADDHNT", Summary: "Add narrow high, top half destination", Word: 0x45206400, Form: ExtFormNarrow, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZADDHNT; inst_gen.go + arm64sveenc.s"}, {Name: "ZRADDHNB", Summary: "Add narrow high with rounding, bottom half destination", Word: 0x45206800, Form: ExtFormNarrow, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZRADDHNB; inst_gen.go + arm64sveenc.s"}, {Name: "ZRADDHNT", Summary: "Add narrow high with rounding, top half destination", Word: 0x45206c00, Form: ExtFormNarrow, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZRADDHNT; inst_gen.go + arm64sveenc.s"}, {Name: "ZRSUBHNB", Summary: "Subtract narrow high with rounding, bottom half destination", Word: 0x45207800, Form: ExtFormNarrow, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZRSUBHNB; inst_gen.go + arm64sveenc.s"}, {Name: "ZRSUBHNT", Summary: "Subtract narrow high with rounding, top half destination", Word: 0x45207c00, Form: ExtFormNarrow, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZRSUBHNT; inst_gen.go + arm64sveenc.s"}, {Name: "ZSUBHNB", Summary: "Subtract narrow high, bottom half destination", Word: 0x45207000, Form: ExtFormNarrow, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSUBHNB; inst_gen.go + arm64sveenc.s"}, {Name: "ZSUBHNT", Summary: "Subtract narrow high, top half destination", Word: 0x45207400, Form: ExtFormNarrow, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSUBHNT; inst_gen.go + arm64sveenc.s"}, // --- the SVE2.1 pairwise and quadword-reduction families ------------------ // // ADDP sums the halves of two vectors pairwise under a governing // predicate, ADDPT the top halves of 128-bit pairs (predicated and // unpredicated), and the QV class reduces a quadword vector into a // scalable accumulator. The QV vector operand carries the counted // quadword spelling the corpus writes, V5.S4 and friends. Provenance // as above: the toolchain encoding table and its generated corpus, both // produced from Arm's official ISA description, and the golden test // pins every corpus line of each class. {Name: "ZADDP", Summary: "Add vector halves pairwise, merging", Word: 0x4411a000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZADDP; inst_gen.go + arm64sveenc.s"}, {Name: "ZADDPT", Summary: "Add the top halves of 128-bit pairs, merging", Word: 0x04c40000, Form: ExtFormZPredicatedSource, Arr: ExtArrD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZADDPT; inst_gen.go + arm64sveenc.s"}, {Name: "ZADDPT", Summary: "Add the top halves of 128-bit pairs, unpredicated", Word: 0x04e00800, Form: ExtFormVectorsZm, Arr: ExtArrD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZADDPT; inst_gen.go + arm64sveenc.s"}, {Name: "ZADDQV", Summary: "Add a quadword vector into a scalable accumulator", Word: 0x04052000, Form: ExtFormQuadReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZADDQV; inst_gen.go + arm64sveenc.s"}, {Name: "ZANDQV", Summary: "And a quadword vector into a scalable accumulator", Word: 0x041e2000, Form: ExtFormQuadReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZANDQV; inst_gen.go + arm64sveenc.s"}, {Name: "ZEORQV", Summary: "Exclusive-or a quadword vector into a scalable accumulator", Word: 0x041d2000, Form: ExtFormQuadReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZEORQV; inst_gen.go + arm64sveenc.s"}, {Name: "ZFADDQV", Summary: "Add floating-point a quadword vector into a scalable accumulator", Word: 0x6410a000, Form: ExtFormQuadReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZFADDQV; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMAXNMQV", Summary: "Maximum number of a quadword vector into a scalable accumulator", Word: 0x6414a000, Form: ExtFormQuadReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZFMAXNMQV; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMAXQV", Summary: "Maximum of a quadword vector into a scalable accumulator", Word: 0x6416a000, Form: ExtFormQuadReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZFMAXQV; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMINNMQV", Summary: "Minimum number of a quadword vector into a scalable accumulator", Word: 0x6415a000, Form: ExtFormQuadReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZFMINNMQV; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMINQV", Summary: "Minimum of a quadword vector into a scalable accumulator", Word: 0x6417a000, Form: ExtFormQuadReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZFMINQV; inst_gen.go + arm64sveenc.s"}, {Name: "ZORQV", Summary: "Or a quadword vector into a scalable accumulator", Word: 0x041c2000, Form: ExtFormQuadReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZORQV; inst_gen.go + arm64sveenc.s"}, {Name: "ZSMAXQV", Summary: "Signed maximum of a quadword vector into a scalable accumulator", Word: 0x040c2000, Form: ExtFormQuadReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSMAXQV; inst_gen.go + arm64sveenc.s"}, {Name: "ZSMINQV", Summary: "Signed minimum of a quadword vector into a scalable accumulator", Word: 0x040e2000, Form: ExtFormQuadReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZSMINQV; inst_gen.go + arm64sveenc.s"}, {Name: "ZUMAXQV", Summary: "Unsigned maximum of a quadword vector into a scalable accumulator", Word: 0x040d2000, Form: ExtFormQuadReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUMAXQV; inst_gen.go + arm64sveenc.s"}, {Name: "ZUMINQV", Summary: "Unsigned minimum of a quadword vector into a scalable accumulator", Word: 0x040f2000, Form: ExtFormQuadReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: ZUMINQV; inst_gen.go + arm64sveenc.s"}, // --- the SVE2 shift-by-vector family -------------------------------------- // // The arithmetic, logical and rounding shift steps over a vector of // shift amounts: the predicated-source shapes share one arrangement, // and the wide three-vector shape takes its amounts from a double-width // vector locked to .D. The shift-by-immediate shapes of the same // mnemonics (the tsz:imm3 class) are not wired yet. Provenance as // above: the toolchain encoding table and its generated corpus, both // produced from Arm's official ISA description, and the golden test // pins every corpus line of the covered shapes. {Name: "ZASR", Summary: "Shift right arithmetic by a vector, merging", Word: 0x04108000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZASR; inst_gen.go + arm64sveenc.s"}, {Name: "ZASR", Summary: "Shift right arithmetic by a wide vector, unpredicated", Word: 0x04208000, Form: ExtFormShiftWide, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZASR; inst_gen.go + arm64sveenc.s"}, {Name: "ZASRR", Summary: "Shift right arithmetic by a vector with rounding, merging", Word: 0x04148000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZASRR; inst_gen.go + arm64sveenc.s"}, {Name: "ZLSL", Summary: "Shift left by a vector, merging", Word: 0x04138000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZLSL; inst_gen.go + arm64sveenc.s"}, {Name: "ZLSL", Summary: "Shift left by a wide vector, unpredicated", Word: 0x04208c00, Form: ExtFormShiftWide, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZLSL; inst_gen.go + arm64sveenc.s"}, {Name: "ZLSLR", Summary: "Shift left by a vector with rounding, merging", Word: 0x04178000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZLSLR; inst_gen.go + arm64sveenc.s"}, {Name: "ZLSR", Summary: "Shift right logical by a vector, merging", Word: 0x04118000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZLSR; inst_gen.go + arm64sveenc.s"}, {Name: "ZLSR", Summary: "Shift right logical by a wide vector, unpredicated", Word: 0x04208400, Form: ExtFormShiftWide, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZLSR; inst_gen.go + arm64sveenc.s"}, {Name: "ZLSRR", Summary: "Shift right logical by a vector with rounding, merging", Word: 0x04158000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZLSRR; inst_gen.go + arm64sveenc.s"}, // --- the SVE2 three-source and bitwise combine families ------------------- // // The three-source bitwise operations (EOR3, BCAX, BSL and its // complements, NBSL) locked to quadwords, and the two-vector combines // over a free arrangement (BDEP, BEXT, BGRP, EORBT, EORTB). Provenance // as above: the toolchain encoding table and its generated corpus, both // produced from Arm's official ISA description, and the golden test // pins every corpus line of the family. The XAR rotate rides the // tsz:imm3 immediate class, unwired with the other shift immediates. {Name: "ZBCAX", Summary: "Broadcast-complement and exclusive-or three sources, .D locked", Word: 0x04603800, Form: ExtFormThreeSource, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBCAX; inst_gen.go + arm64sveenc.s"}, {Name: "ZBDEP", Summary: "Deposite bit particles from adjacent pairs", Word: 0x4500b400, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBDEP; inst_gen.go + arm64sveenc.s"}, {Name: "ZBEXT", Summary: "Extract bit particles from adjacent pairs", Word: 0x4500b000, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBEXT; inst_gen.go + arm64sveenc.s"}, {Name: "ZBGRP", Summary: "Group bit particles from adjacent pairs", Word: 0x4500b800, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBGRP; inst_gen.go + arm64sveenc.s"}, {Name: "ZBSL", Summary: "Bitwise select three sources, .D locked", Word: 0x04203c00, Form: ExtFormThreeSource, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBSL; inst_gen.go + arm64sveenc.s"}, {Name: "ZBSL1N", Summary: "Bitwise select with first source inverted, .D locked", Word: 0x04603c00, Form: ExtFormThreeSource, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBSL1N; inst_gen.go + arm64sveenc.s"}, {Name: "ZBSL2N", Summary: "Bitwise select with second source inverted, .D locked", Word: 0x04a03c00, Form: ExtFormThreeSource, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBSL2N; inst_gen.go + arm64sveenc.s"}, {Name: "ZEOR3", Summary: "Exclusive-or three sources, .D locked", Word: 0x04203800, Form: ExtFormThreeSource, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZEOR3; inst_gen.go + arm64sveenc.s"}, {Name: "ZEORBT", Summary: "Exclusive-or bottom of one source with top of the other", Word: 0x45009000, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZEORBT; inst_gen.go + arm64sveenc.s"}, {Name: "ZEORTB", Summary: "Exclusive-or top of one source with bottom of the other", Word: 0x45009400, Form: ExtFormVectorsZm, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZEORTB; inst_gen.go + arm64sveenc.s"}, {Name: "ZNBSL", Summary: "Bitwise select with negated result, .D locked", Word: 0x04e03c00, Form: ExtFormThreeSource, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZNBSL; inst_gen.go + arm64sveenc.s"}, // --- the SVE2 BFloat16 arithmetic core ------------------------------------ // // The two-shape arithmetic (ADD, MAX, MAXNM, MIN, MINNM, MUL, SUB) // over halfwords only: the predicated-source and unpredicated // three-vector spellings, the clamp over the unpredicated shape, and // the B-to-H conversions of the F1CVT and F2CVT pairs. The remaining // BFloat16 shapes (dot products, lengthened multiplies, converts with // a governing predicate) stay unwired. Provenance as above: the // toolchain encoding table and its generated corpus, both produced // from Arm's official ISA description, and the golden test pins every // corpus line of the covered classes. {Name: "ZBF1CVT", Summary: "Convert BFloat16 pairs from bytes to halfwords, bottom", Word: 0x65083800, Form: ExtFormZUnpack, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBF1CVT; inst_gen.go + arm64sveenc.s"}, {Name: "ZBF1CVTLT", Summary: "Convert BFloat16 pairs from bytes to halfwords, bottom, no rounding", Word: 0x65093800, Form: ExtFormZUnpack, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBF1CVTLT; inst_gen.go + arm64sveenc.s"}, {Name: "ZBF2CVT", Summary: "Convert BFloat16 pairs from bytes to halfwords, top", Word: 0x65083c00, Form: ExtFormZUnpack, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBF2CVT; inst_gen.go + arm64sveenc.s"}, {Name: "ZBF2CVTLT", Summary: "Convert BFloat16 pairs from bytes to halfwords, top, no rounding", Word: 0x65093c00, Form: ExtFormZUnpack, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBF2CVTLT; inst_gen.go + arm64sveenc.s"}, {Name: "ZF1CVT", Summary: "Convert FP8 byte pairs to halfwords, bottom", Word: 0x65083000, Form: ExtFormZUnpack, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: F1CVT; inst_gen.go + arm64sveenc.s"}, {Name: "ZF1CVTLT", Summary: "Convert FP8 byte pairs to halfwords, bottom, no rounding", Word: 0x65093000, Form: ExtFormZUnpack, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: F1CVTLT; inst_gen.go + arm64sveenc.s"}, {Name: "ZF2CVT", Summary: "Convert FP8 byte pairs to halfwords, top", Word: 0x65083400, Form: ExtFormZUnpack, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: F2CVT; inst_gen.go + arm64sveenc.s"}, {Name: "ZF2CVTLT", Summary: "Convert FP8 byte pairs to halfwords, top, no rounding", Word: 0x65093400, Form: ExtFormZUnpack, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: F2CVTLT; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFADD", Summary: "Add BFloat16 halfwords, merging", Word: 0x65008000, Form: ExtFormZPredicatedSource, Arr: ExtArrH, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFADD; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFADD", Summary: "Add BFloat16 halfwords, unpredicated", Word: 0x65000000, Form: ExtFormVectorsZm, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFADD; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFCLAMP", Summary: "Clamp BFloat16 halfwords between bounds, unpredicated", Word: 0x64202400, Form: ExtFormVectorsZm, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFCLAMP; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFMAX", Summary: "Maximum of BFloat16 halfwords, merging", Word: 0x65068000, Form: ExtFormZPredicatedSource, Arr: ExtArrH, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFMAX; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFMAXNM", Summary: "Maximum number of BFloat16 halfwords, merging", Word: 0x65048000, Form: ExtFormZPredicatedSource, Arr: ExtArrH, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFMAXNM; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFMIN", Summary: "Minimum of BFloat16 halfwords, merging", Word: 0x65078000, Form: ExtFormZPredicatedSource, Arr: ExtArrH, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFMIN; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFMINNM", Summary: "Minimum number of BFloat16 halfwords, merging", Word: 0x65058000, Form: ExtFormZPredicatedSource, Arr: ExtArrH, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFMINNM; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFMUL", Summary: "Multiply BFloat16 halfwords, merging", Word: 0x65028000, Form: ExtFormZPredicatedSource, Arr: ExtArrH, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFMUL; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFMUL", Summary: "Multiply BFloat16 halfwords, unpredicated", Word: 0x65000800, Form: ExtFormVectorsZm, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFMUL; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFSUB", Summary: "Subtract BFloat16 halfwords, merging", Word: 0x65018000, Form: ExtFormZPredicatedSource, Arr: ExtArrH, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFSUB; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFSUB", Summary: "Subtract BFloat16 halfwords, unpredicated", Word: 0x65000400, Form: ExtFormVectorsZm, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFSUB; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFCVT", Summary: "Convert BFloat16 halfwords to words from a source, merging", Word: 0x658aa000, Form: ExtFormConvert, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFCVT; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFCVT", Summary: "Convert BFloat16 halfwords to words from a source, zeroing", Word: 0x649ac000, Form: ExtFormConvert, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFCVT; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFCVTNT", Summary: "Convert BFloat16 halfwords to words from a source, merging, no rounding", Word: 0x648aa000, Form: ExtFormConvert, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFCVTNT; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFCVTNT", Summary: "Convert BFloat16 halfwords to words from a source, zeroing, no rounding", Word: 0x6482a000, Form: ExtFormConvert, PgQual: ExtQualZeroing, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFCVTNT; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFDOT", Summary: "Dot product of BFloat16 pairs into words", Word: 0x64608000, Form: ExtFormLongMul, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFDOT; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFMLA", Summary: "Multiply-accumulate BFloat16 halfwords, merging", Word: 0x65200000, Form: ExtFormMulPred, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFMLA; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFMLALB", Summary: "Lengthened multiply-accumulate of BFloat16 halfwords, bottom", Word: 0x64e08000, Form: ExtFormLongMul, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFMLALB; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFMLALT", Summary: "Lengthened multiply-accumulate of BFloat16 halfwords, top", Word: 0x64e08400, Form: ExtFormLongMul, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFMLALT; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFMLS", Summary: "Multiply-subtract BFloat16 halfwords, merging", Word: 0x65202000, Form: ExtFormMulPred, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFMLS; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFMLSLB", Summary: "Lengthened multiply-subtract of BFloat16 halfwords, bottom", Word: 0x64e0a000, Form: ExtFormLongMul, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFMLSLB; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFMLSLT", Summary: "Lengthened multiply-subtract of BFloat16 halfwords, top", Word: 0x64e0a400, Form: ExtFormLongMul, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFMLSLT; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFMMLA", Summary: "Matrix multiply-accumulate of BFloat16 halfwords", Word: 0x6460e400, Form: ExtFormLongMul, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFMMLA; inst_gen.go + arm64sveenc.s"}, {Name: "ZBFSCALE", Summary: "Scale BFloat16 halfwords by a power of two, merging", Word: 0x65098000, Form: ExtFormZPredicatedSource, Arr: ExtArrH, PgQual: ExtQualMerging, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZBFSCALE; inst_gen.go + arm64sveenc.s"}, // --- the SVE2.1 last-active and compare families -------------------------- // // The conditionally-extract-last-active-element vector shape and the // compares to a predicate destination, in their shared-arrangement and // wide spellings. The register-destination shapes of CLASTA and // CLASTB, and the immediate compares, stay unwired. Provenance as // above: the toolchain encoding table and its generated corpus, both // produced from Arm's official ISA description, and the golden test // pins every corpus line of the covered classes. {Name: "ZCLASTA", Summary: "Conditionally extract the last active element, vector to vector", Word: 0x05288000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualNone, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCLASTA; inst_gen.go + arm64sveenc.s"}, {Name: "ZCLASTB", Summary: "Conditionally extract the last active element from the bottom, vector to vector", Word: 0x05298000, Form: ExtFormZPredicatedSource, Size: extSizeBHSD, PgQual: ExtQualNone, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCLASTB; inst_gen.go + arm64sveenc.s"}, {Name: "ZCMPEQ", Summary: "Compare equal, writing a zeroing predicate", Word: 0x2400a000, Form: ExtFormCompare, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCMPEQ; inst_gen.go + arm64sveenc.s"}, {Name: "ZCMPEQ", Summary: "Compare equal against wide magnitudes, writing a zeroing predicate", Word: 0x24002000, Form: ExtFormCompareWide, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCMPEQ; inst_gen.go + arm64sveenc.s"}, {Name: "ZCMPGE", Summary: "Compare greater or equal signed, writing a zeroing predicate", Word: 0x24008000, Form: ExtFormCompare, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCMPGE; inst_gen.go + arm64sveenc.s"}, {Name: "ZCMPGE", Summary: "Compare greater or equal signed against wide magnitudes, writing a zeroing predicate", Word: 0x24004000, Form: ExtFormCompareWide, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCMPGE; inst_gen.go + arm64sveenc.s"}, {Name: "ZCMPGT", Summary: "Compare greater signed, writing a zeroing predicate", Word: 0x24008010, Form: ExtFormCompare, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCMPGT; inst_gen.go + arm64sveenc.s"}, {Name: "ZCMPGT", Summary: "Compare greater signed against wide magnitudes, writing a zeroing predicate", Word: 0x24004010, Form: ExtFormCompareWide, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCMPGT; inst_gen.go + arm64sveenc.s"}, {Name: "ZCMPHI", Summary: "Compare higher unsigned, writing a zeroing predicate", Word: 0x24000010, Form: ExtFormCompare, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCMPHI; inst_gen.go + arm64sveenc.s"}, {Name: "ZCMPHI", Summary: "Compare higher unsigned against wide magnitudes, writing a zeroing predicate", Word: 0x2400c010, Form: ExtFormCompareWide, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCMPHI; inst_gen.go + arm64sveenc.s"}, {Name: "ZCMPHS", Summary: "Compare higher or same unsigned, writing a zeroing predicate", Word: 0x24000000, Form: ExtFormCompare, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCMPHS; inst_gen.go + arm64sveenc.s"}, {Name: "ZCMPHS", Summary: "Compare higher or same unsigned against wide magnitudes, writing a zeroing predicate", Word: 0x2400c000, Form: ExtFormCompareWide, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCMPHS; inst_gen.go + arm64sveenc.s"}, {Name: "ZCMPNE", Summary: "Compare not equal, writing a zeroing predicate", Word: 0x2400a010, Form: ExtFormCompare, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCMPNE; inst_gen.go + arm64sveenc.s"}, {Name: "ZCMPNE", Summary: "Compare not equal against wide magnitudes, writing a zeroing predicate", Word: 0x24002010, Form: ExtFormCompareWide, Size: extSizeBHSD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ZCMPNE; inst_gen.go + arm64sveenc.s"}, // --- the vector-length arithmetic pseudo group ---------------------------- // // ADDVL, ADDPL and RDVL over the signed imm6 multiple of the vector // length or the parameter register. Provenance as above: the toolchain // encoding table and its generated corpus, both produced from Arm's // official ISA description, and the golden test pins every corpus line // of the family. {Name: "ADDPL", Summary: "Add a signed multiple of the parameter register count to a register", Word: 0x04605000, Form: ExtFormVLArith, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ADDPL; inst_gen.go + arm64sveenc.s"}, {Name: "ADDVL", Summary: "Add a signed multiple of the vector length to a register", Word: 0x04205000, Form: ExtFormVLArith, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ADDVL; inst_gen.go + arm64sveenc.s"}, {Name: "RDVL", Summary: "Read the vector length multiplied by a signed immediate", Word: 0x04bf5000, Form: ExtFormVLRead, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: RDVL; inst_gen.go + arm64sveenc.s"}, // --- the SVE multiple-structure loads and stores -------------------------- // // The two-, three- and four-register list loads and stores over the // two-general-register addressing mode, the shift scaling the base by // the list element size. The list operand carries consecutive // registers under one arrangement; the encoding takes the first alone // and the conversion validates the rest against the instruction's own // digit. The MUL VL immediate-offset variant of the same shapes stays // unwired. Provenance as above: the toolchain encoding table and its // generated corpus, both produced from Arm's official ISA description. {Name: "ZLD2B", Summary: "Load 2 scalable vector registers, .B list", Word: 0xa420c000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 0, Arr: ExtArrB, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD2B (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD2D", Summary: "Load 2 scalable vector registers, .D list", Word: 0xa5a0c000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 3, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD2D (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD2H", Summary: "Load 2 scalable vector registers, .H list", Word: 0xa4a0c000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 1, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD2H (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD2Q", Summary: "Load 2 scalable vector registers, .Q list", Word: 0xa4a08000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 4, Arr: ExtArrQ, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD2Q (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD2W", Summary: "Load 2 scalable vector registers, .W list", Word: 0xa520c000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 2, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD2W (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD3B", Summary: "Load 3 scalable vector registers, .B list", Word: 0xa440c000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 0, Arr: ExtArrB, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD3B (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD3D", Summary: "Load 3 scalable vector registers, .D list", Word: 0xa5c0c000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 3, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD3D (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD3H", Summary: "Load 3 scalable vector registers, .H list", Word: 0xa4c0c000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 1, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD3H (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD3Q", Summary: "Load 3 scalable vector registers, .Q list", Word: 0xa5208000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 4, Arr: ExtArrQ, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD3Q (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD3W", Summary: "Load 3 scalable vector registers, .W list", Word: 0xa540c000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 2, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD3W (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD4B", Summary: "Load 4 scalable vector registers, .B list", Word: 0xa460c000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 0, Arr: ExtArrB, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD4B (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD4D", Summary: "Load 4 scalable vector registers, .D list", Word: 0xa5e0c000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 3, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD4D (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD4H", Summary: "Load 4 scalable vector registers, .H list", Word: 0xa4e0c000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 1, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD4H (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD4Q", Summary: "Load 4 scalable vector registers, .Q list", Word: 0xa5a08000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 4, Arr: ExtArrQ, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD4Q (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZLD4W", Summary: "Load 4 scalable vector registers, .W list", Word: 0xa560c000, Form: ExtFormSveLoad, SveMode: extMemPair, SveShift: 2, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZLD4W (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST2B", Summary: "Store 2 scalable vector registers, .B list", Word: 0xe4206000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 0, Arr: ExtArrB, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST2B (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST2D", Summary: "Store 2 scalable vector registers, .D list", Word: 0xe5a06000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 3, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST2D (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST2H", Summary: "Store 2 scalable vector registers, .H list", Word: 0xe4a06000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 1, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST2H (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST2Q", Summary: "Store 2 scalable vector registers, .Q list", Word: 0xe4600000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 4, Arr: ExtArrQ, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST2Q (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST2W", Summary: "Store 2 scalable vector registers, .W list", Word: 0xe5206000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 2, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST2W (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST3B", Summary: "Store 3 scalable vector registers, .B list", Word: 0xe4406000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 0, Arr: ExtArrB, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST3B (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST3D", Summary: "Store 3 scalable vector registers, .D list", Word: 0xe5c06000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 3, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST3D (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST3H", Summary: "Store 3 scalable vector registers, .H list", Word: 0xe4c06000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 1, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST3H (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST3Q", Summary: "Store 3 scalable vector registers, .Q list", Word: 0xe4a00000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 4, Arr: ExtArrQ, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST3Q (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST3W", Summary: "Store 3 scalable vector registers, .W list", Word: 0xe5406000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 2, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST3W (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST4B", Summary: "Store 4 scalable vector registers, .B list", Word: 0xe4606000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 0, Arr: ExtArrB, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST4B (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST4D", Summary: "Store 4 scalable vector registers, .D list", Word: 0xe5e06000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 3, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST4D (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST4H", Summary: "Store 4 scalable vector registers, .H list", Word: 0xe4e06000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 1, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST4H (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST4Q", Summary: "Store 4 scalable vector registers, .Q list", Word: 0xe4e00000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 4, Arr: ExtArrQ, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST4Q (multiple structures); inst_gen.go + arm64sveenc.s"}, {Name: "ZST4W", Summary: "Store 4 scalable vector registers, .W list", Word: 0xe5606000, Form: ExtFormSveStore, SveMode: extMemPair, SveShift: 2, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: ZST4W (multiple structures); inst_gen.go + arm64sveenc.s"}, // --- the SVE2 crypto family ---------------------------------------------- // // The multi-precision carry steps (ADCLB, ADCLT, SBCLB, SBCLT), the SHA3 // rotate (RAX1), the SM4 round and key (SM4E, SM4EKEY) and the AES round // and mix columns (AESD, AESE, AESIMC, AESMC). Every arrangement is // locked into the word: .D for the carry steps and RAX1, .S for SM4, .B // for AES. Provenance as above: the toolchain encoding table and its // generated corpus, both produced from Arm's official ISA description, // and the golden test pins every corpus line of the family. {Name: "ZADCLB", Summary: "Add vectors with carry, borrowing from a scalar, low half", Word: 0x4540d000, Form: ExtFormVectorsZm, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ADCLB; inst_gen.go + arm64sveenc.s"}, {Name: "ZADCLT", Summary: "Add vectors with carry, borrowing from a scalar, top half", Word: 0x4540d400, Form: ExtFormVectorsZm, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ADCLT; inst_gen.go + arm64sveenc.s"}, {Name: "ZSBCLB", Summary: "Subtract vectors with borrow, propagating a scalar, low half", Word: 0x45c0d000, Form: ExtFormVectorsZm, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: SBCLOB/SBCLB; inst_gen.go + arm64sveenc.s"}, {Name: "ZSBCLT", Summary: "Subtract vectors with borrow, propagating a scalar, top half", Word: 0x45c0d400, Form: ExtFormVectorsZm, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: SBCLOT/SBCLT; inst_gen.go + arm64sveenc.s"}, {Name: "ZRAX1", Summary: "SHA3 rotate and exclusive-or one quadword", Word: 0x4520f400, Form: ExtFormVectorsZm, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: RAX1; inst_gen.go + arm64sveenc.s"}, {Name: "ZSM4EKEY", Summary: "SM4 key expansion round over vector elements", Word: 0x4520f000, Form: ExtFormVectorsZm, Arr: ExtArrS, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: SM4EKEY; inst_gen.go + arm64sveenc.s"}, {Name: "ZSM4E", Summary: "SM4 encryption round over vector elements", Word: 0x4523e000, Form: ExtFormZReadBack, Arr: ExtArrS, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: SM4E; inst_gen.go + arm64sveenc.s"}, {Name: "ZAESD", Summary: "AES decryption round over vector elements", Word: 0x4522e400, Form: ExtFormZReadBack, Arr: ExtArrB, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: AESD; inst_gen.go + arm64sveenc.s"}, {Name: "ZAESE", Summary: "AES encryption round over vector elements", Word: 0x4522e000, Form: ExtFormZReadBack, Arr: ExtArrB, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: AESE; inst_gen.go + arm64sveenc.s"}, {Name: "ZAESIMC", Summary: "AES inverse mix columns over vector elements", Word: 0x4520e400, Form: ExtFormZSameReg, Arr: ExtArrB, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: AESIMC; inst_gen.go + arm64sveenc.s"}, {Name: "ZAESMC", Summary: "AES mix columns over vector elements", Word: 0x4520e000, Form: ExtFormZSameReg, Arr: ExtArrB, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: AESMC; inst_gen.go + arm64sveenc.s"}, // --- the SVE predicate counters and loop terminators ----------------------- // // The count of active elements into a scalar (CNTP, PFIRSTP, PLASTP), the // predicate-counter steps whose scalar result the class drops (DECP, INCP // and the saturating variants) or writes back (the W spellings), and the // while-terminators CTERMEQ and CTERMNE that close SVE2 while-loops. The // 32-bit while compares carry a W suffix and one bit of their own; the // pattern-immediate forms of CNTP and WHILE (SVE2.1) are not yet in the // layer. Provenance as above, pinned by the golden test. {Name: "CTERMEQ", Summary: "Terminate a while-loop when the counters are equal", Word: 0x25e02000, Form: ExtFormCTerm, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: CTERMEQ; inst_gen.go + arm64sveenc.s"}, {Name: "CTERMEQW", Summary: "Terminate a while-loop when the 32-bit counters are equal", Word: 0x25a02000, Form: ExtFormCTerm, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: CTERMEQ (32-bit); inst_gen.go + arm64sveenc.s"}, {Name: "CTERMNE", Summary: "Terminate a while-loop when the counters differ", Word: 0x25e02030, Form: ExtFormCTerm, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: CTERMNE; inst_gen.go + arm64sveenc.s"}, {Name: "CTERMNEW", Summary: "Terminate a while-loop when the 32-bit counters differ", Word: 0x25a02030, Form: ExtFormCTerm, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: CTERMNE (32-bit); inst_gen.go + arm64sveenc.s"}, {Name: "PCNTP", Summary: "Count the active elements of a predicate into a register", Word: 0x25208000, Form: ExtFormCountP, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: CNTP as PCNTP; inst_gen.go + arm64sveenc.s"}, {Name: "PFIRSTP", Summary: "Write one when the first element of a predicate is active", Word: 0x25218000, Form: ExtFormCountP, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PFIRSTP; inst_gen.go + arm64sveenc.s"}, {Name: "PLASTP", Summary: "Write one when the last element of a predicate is active", Word: 0x25228000, Form: ExtFormCountP, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: PLASTP; inst_gen.go + arm64sveenc.s"}, {Name: "PDECP", Summary: "Decrement a predicate counter by its active elements", Word: 0x252d8800, Form: ExtFormCountPn, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: DECP (predicate) as PDECP; inst_gen.go + arm64sveenc.s"}, {Name: "PINCP", Summary: "Increment a predicate counter by its active elements", Word: 0x252c8800, Form: ExtFormCountPn, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J SVE2.1: INCP (predicate) as PINCP; inst_gen.go + arm64sveenc.s"}, {Name: "PSQDECP", Summary: "Decrement a predicate counter, saturating signed", Word: 0x252a8c00, Form: ExtFormCountPn, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J: SQDECP (predicate) as PSQDECP; inst_gen.go + arm64sveenc.s"}, {Name: "PSQINCP", Summary: "Increment a predicate counter, saturating signed", Word: 0x25288c00, Form: ExtFormCountPn, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J: SQINCP (predicate) as PSQINCP; inst_gen.go + arm64sveenc.s"}, {Name: "PUQDECP", Summary: "Decrement a predicate counter, saturating unsigned", Word: 0x252b8c00, Form: ExtFormCountPn, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J: UQDECP (predicate) as PUQDECP; inst_gen.go + arm64sveenc.s"}, {Name: "PUQINCP", Summary: "Increment a predicate counter, saturating unsigned", Word: 0x25298c00, Form: ExtFormCountPn, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J: UQINCP (predicate) as PUQINCP; inst_gen.go + arm64sveenc.s"}, {Name: "PUQDECPW", Summary: "Decrement a predicate counter, saturating unsigned, 32-bit", Word: 0x252b8800, Form: ExtFormCountPn, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J: UQDECP (predicate, 32-bit) as PUQDECPW; inst_gen.go + arm64sveenc.s"}, {Name: "PUQINCPW", Summary: "Increment a predicate counter, saturating unsigned, 32-bit", Word: 0x25298800, Form: ExtFormCountPn, Size: extSizeBHSD, Feature: ExtFeatureSVE2p1, Ref: "ARM DDI 0487J: UQINCP (predicate, 32-bit) as PUQINCPW; inst_gen.go + arm64sveenc.s"}, {Name: "PSQDECPW", Summary: "Decrement a register by a predicate's active elements, saturating signed", Word: 0x252a8800, Form: ExtFormCountPnW, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: SQDECP (scalar, 32-bit) as PSQDECPW; inst_gen.go + arm64sveenc.s"}, {Name: "PSQINCPW", Summary: "Increment a register by a predicate's active elements, saturating signed", Word: 0x25288800, Form: ExtFormCountPnW, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: SQINCP (scalar, 32-bit) as PSQINCPW; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILEGEW", Summary: "Build a predicate while the signed 32-bit comparison holds", Word: 0x25200000, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILEGE (32-bit) as PWHILEGEW; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILEGTW", Summary: "Build a predicate while the signed 32-bit comparison holds", Word: 0x25200010, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILEGT (32-bit) as PWHILEGTW; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILEHIW", Summary: "Build a predicate while the unsigned 32-bit comparison holds", Word: 0x25200810, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILEHI (32-bit) as PWHILEHIW; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILEHSW", Summary: "Build a predicate while the unsigned 32-bit comparison holds", Word: 0x25200800, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILEHS (32-bit) as PWHILEHSW; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILELEW", Summary: "Build a predicate while the signed 32-bit comparison holds", Word: 0x25200410, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILELE (32-bit) as PWHILELEW; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILELOW", Summary: "Build a predicate while the unsigned 32-bit comparison holds", Word: 0x25200c00, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILELO (32-bit) as PWHILELOW; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILELSW", Summary: "Build a predicate while the unsigned 32-bit comparison holds", Word: 0x25200c10, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILELS (32-bit) as PWHILELSW; inst_gen.go + arm64sveenc.s"}, {Name: "PWHILELTW", Summary: "Build a predicate while the signed 32-bit comparison holds", Word: 0x25200400, Form: ExtFormWhile, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: WHILELT (32-bit) as PWHILELTW; inst_gen.go + arm64sveenc.s"}, // --- the SVE reductions ---------------------------------------------------- // // The integer, bitwise and floating-point reductions into the low lanes // of a SIMD register: ANDV, EORV and ORV (SVE2), SADDV and UADDV with // their D-sized accumulator, the maxima and minima, and the FP sums, // maxima and minima including FADDA's strict accumulation. The size is // baked into the mnemonic and the word for every family but SADDV and // UADDV, where the source's arrangement carries it. {Name: "ZSADDVD", Summary: "Signed sum of the active elements into a SIMD register", Word: 0x04002000, Form: ExtFormReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: SADDV as ZSADDVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZUADDVD", Summary: "Unsigned sum of the active elements into a SIMD register", Word: 0x04012000, Form: ExtFormReduce, Size: extSizeBHSD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: UADDV as ZUADDVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZANDVB", Summary: "Bitwise and of the active elements", Word: 0x041a2000, Form: ExtFormReduce, Arr: ExtArrB, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ANDV as ZANDVB; inst_gen.go + arm64sveenc.s"}, {Name: "ZANDVH", Summary: "Bitwise and of the active elements", Word: 0x045a2000, Form: ExtFormReduce, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ANDV as ZANDVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZANDVS", Summary: "Bitwise and of the active elements", Word: 0x049a2000, Form: ExtFormReduce, Arr: ExtArrS, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ANDV as ZANDVS; inst_gen.go + arm64sveenc.s"}, {Name: "ZANDVD", Summary: "Bitwise and of the active elements", Word: 0x04da2000, Form: ExtFormReduce, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ANDV as ZANDVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZEORVB", Summary: "Bitwise exclusive-or of the active elements", Word: 0x04192000, Form: ExtFormReduce, Arr: ExtArrB, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: EORV as ZEORVB; inst_gen.go + arm64sveenc.s"}, {Name: "ZEORVH", Summary: "Bitwise exclusive-or of the active elements", Word: 0x04592000, Form: ExtFormReduce, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: EORV as ZEORVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZEORVS", Summary: "Bitwise exclusive-or of the active elements", Word: 0x04992000, Form: ExtFormReduce, Arr: ExtArrS, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: EORV as ZEORVS; inst_gen.go + arm64sveenc.s"}, {Name: "ZEORVD", Summary: "Bitwise exclusive-or of the active elements", Word: 0x04d92000, Form: ExtFormReduce, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: EORV as ZEORVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZORVB", Summary: "Bitwise or of the active elements", Word: 0x04182000, Form: ExtFormReduce, Arr: ExtArrB, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ORV as ZORVB; inst_gen.go + arm64sveenc.s"}, {Name: "ZORVH", Summary: "Bitwise or of the active elements", Word: 0x04582000, Form: ExtFormReduce, Arr: ExtArrH, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ORV as ZORVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZORVS", Summary: "Bitwise or of the active elements", Word: 0x04982000, Form: ExtFormReduce, Arr: ExtArrS, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ORV as ZORVS; inst_gen.go + arm64sveenc.s"}, {Name: "ZORVD", Summary: "Bitwise or of the active elements", Word: 0x04d82000, Form: ExtFormReduce, Arr: ExtArrD, Feature: ExtFeatureSVE2, Ref: "ARM DDI 0487J SVE2: ORV as ZORVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZSMAXVB", Summary: "Signed maximum of the active byte elements", Word: 0x04082000, Form: ExtFormReduce, Arr: ExtArrB, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: SMAXV as ZSMAXVB; inst_gen.go + arm64sveenc.s"}, {Name: "ZSMAXVH", Summary: "Signed maximum of the active halfword elements", Word: 0x04482000, Form: ExtFormReduce, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: SMAXV as ZSMAXVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZSMAXVS", Summary: "Signed maximum of the active word elements", Word: 0x04882000, Form: ExtFormReduce, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: SMAXV as ZSMAXVS; inst_gen.go + arm64sveenc.s"}, {Name: "ZSMAXVD", Summary: "Signed maximum of the active doubleword elements", Word: 0x04c82000, Form: ExtFormReduce, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: SMAXV as ZSMAXVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZSMINVB", Summary: "Signed minimum of the active byte elements", Word: 0x040a2000, Form: ExtFormReduce, Arr: ExtArrB, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: SMINV as ZSMINVB; inst_gen.go + arm64sveenc.s"}, {Name: "ZSMINVH", Summary: "Signed minimum of the active halfword elements", Word: 0x044a2000, Form: ExtFormReduce, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: SMINV as ZSMINVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZSMINVS", Summary: "Signed minimum of the active word elements", Word: 0x048a2000, Form: ExtFormReduce, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: SMINV as ZSMINVS; inst_gen.go + arm64sveenc.s"}, {Name: "ZSMINVD", Summary: "Signed minimum of the active doubleword elements", Word: 0x04ca2000, Form: ExtFormReduce, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: SMINV as ZSMINVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZUMAXVB", Summary: "Unsigned maximum of the active byte elements", Word: 0x04092000, Form: ExtFormReduce, Arr: ExtArrB, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: UMAXV as ZUMAXVB; inst_gen.go + arm64sveenc.s"}, {Name: "ZUMAXVH", Summary: "Unsigned maximum of the active halfword elements", Word: 0x04492000, Form: ExtFormReduce, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: UMAXV as ZUMAXVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZUMAXVS", Summary: "Unsigned maximum of the active word elements", Word: 0x04892000, Form: ExtFormReduce, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: UMAXV as ZUMAXVS; inst_gen.go + arm64sveenc.s"}, {Name: "ZUMAXVD", Summary: "Unsigned maximum of the active doubleword elements", Word: 0x04c92000, Form: ExtFormReduce, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: UMAXV as ZUMAXVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZUMINVB", Summary: "Unsigned minimum of the active byte elements", Word: 0x040b2000, Form: ExtFormReduce, Arr: ExtArrB, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: UMINV as ZUMINVB; inst_gen.go + arm64sveenc.s"}, {Name: "ZUMINVH", Summary: "Unsigned minimum of the active halfword elements", Word: 0x044b2000, Form: ExtFormReduce, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: UMINV as ZUMINVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZUMINVS", Summary: "Unsigned minimum of the active word elements", Word: 0x048b2000, Form: ExtFormReduce, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: UMINV as ZUMINVS; inst_gen.go + arm64sveenc.s"}, {Name: "ZUMINVD", Summary: "Unsigned minimum of the active doubleword elements", Word: 0x04cb2000, Form: ExtFormReduce, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: UMINV as ZUMINVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZFADDVH", Summary: "Floating-point sum of the active halfword elements", Word: 0x65402000, Form: ExtFormReduce, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FADDV as ZFADDVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZFADDVS", Summary: "Floating-point sum of the active word elements", Word: 0x65802000, Form: ExtFormReduce, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FADDV as ZFADDVS; inst_gen.go + arm64sveenc.s"}, {Name: "ZFADDVD", Summary: "Floating-point sum of the active doubleword elements", Word: 0x65c02000, Form: ExtFormReduce, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FADDV as ZFADDVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMAXNMVH", Summary: "Floating-point maximum of the active halfword elements, quiet NaN", Word: 0x65442000, Form: ExtFormReduce, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FMAXNMV as ZFMAXNMVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMAXNMVS", Summary: "Floating-point maximum of the active word elements, quiet NaN", Word: 0x65842000, Form: ExtFormReduce, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FMAXNMV as ZFMAXNMVS; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMAXNMVD", Summary: "Floating-point maximum of the active doubleword elements, quiet NaN", Word: 0x65c42000, Form: ExtFormReduce, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FMAXNMV as ZFMAXNMVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMAXVH", Summary: "Floating-point maximum of the active halfword elements", Word: 0x65462000, Form: ExtFormReduce, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FMAXV as ZFMAXVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMAXVS", Summary: "Floating-point maximum of the active word elements", Word: 0x65862000, Form: ExtFormReduce, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FMAXV as ZFMAXVS; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMAXVD", Summary: "Floating-point maximum of the active doubleword elements", Word: 0x65c62000, Form: ExtFormReduce, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FMAXV as ZFMAXVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMINNMVH", Summary: "Floating-point minimum of the active halfword elements, quiet NaN", Word: 0x65452000, Form: ExtFormReduce, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FMINNMV as ZFMINNMVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMINNMVS", Summary: "Floating-point minimum of the active word elements, quiet NaN", Word: 0x65852000, Form: ExtFormReduce, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FMINNMV as ZFMINNMVS; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMINNMVD", Summary: "Floating-point minimum of the active doubleword elements, quiet NaN", Word: 0x65c52000, Form: ExtFormReduce, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FMINNMV as ZFMINNMVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMINVH", Summary: "Floating-point minimum of the active halfword elements", Word: 0x65472000, Form: ExtFormReduce, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FMINV as ZFMINVH; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMINVS", Summary: "Floating-point minimum of the active word elements", Word: 0x65872000, Form: ExtFormReduce, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FMINV as ZFMINVS; inst_gen.go + arm64sveenc.s"}, {Name: "ZFMINVD", Summary: "Floating-point minimum of the active doubleword elements", Word: 0x65c72000, Form: ExtFormReduce, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FMINV as ZFMINVD; inst_gen.go + arm64sveenc.s"}, {Name: "ZFADDAH", Summary: "Strict floating-point accumulation of the active halfword elements", Word: 0x65582000, Form: ExtFormReduceReadBack, Arr: ExtArrH, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FADDA as ZFADDAH; inst_gen.go + arm64sveenc.s"}, {Name: "ZFADDAS", Summary: "Strict floating-point accumulation of the active word elements", Word: 0x65982000, Form: ExtFormReduceReadBack, Arr: ExtArrS, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FADDA as ZFADDAS; inst_gen.go + arm64sveenc.s"}, {Name: "ZFADDAD", Summary: "Strict floating-point accumulation of the active doubleword elements", Word: 0x65d82000, Form: ExtFormReduceReadBack, Arr: ExtArrD, Feature: ExtFeatureSVE, Ref: "ARM DDI 0487J: FADDA as ZFADDAD; inst_gen.go + arm64sveenc.s"}, // --- the SVE gather loads and scatter stores -------------------------------- // // The core addressing modes of the gather/scatter family over the plain, // sign-extended and first-fault loads and the stores: the two-general- // register pair (Rn{<