test_cases:
  -
    input:
      bytes: [ 0x20, 0x70, 0x22, 0x04 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sve2" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z0.b, z1.b, z2.b"

  -
    input:
      bytes: [ 0x20, 0x70, 0x62, 0x04 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sve2" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z0.h, z1.h, z2.h"

  -
    input:
      bytes: [ 0xdd, 0x73, 0xbf, 0x04 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sve2" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z29.s, z30.s, z31.s"

  -
    input:
      bytes: [ 0xff, 0x73, 0xff, 0x04 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sve2" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z31.d, z31.d, z31.d"

  -
    input:
      bytes: [ 0x20, 0xf0, 0x7f, 0x44 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sve2" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z0.h, z1.h, z7.h[7]"

  -
    input:
      bytes: [ 0x20, 0xf0, 0xbf, 0x44 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sve2" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z0.s, z1.s, z7.s[3]"

  -
    input:
      bytes: [ 0x20, 0xf0, 0xff, 0x44 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sve2" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z0.d, z1.d, z15.d[1]"

  -
    input:
      bytes: [ 0x20, 0x70, 0x22, 0x04 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sme" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z0.b, z1.b, z2.b"

  -
    input:
      bytes: [ 0x20, 0x70, 0x62, 0x04 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sme" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z0.h, z1.h, z2.h"

  -
    input:
      bytes: [ 0xdd, 0x73, 0xbf, 0x04 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sme" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z29.s, z30.s, z31.s"

  -
    input:
      bytes: [ 0xff, 0x73, 0xff, 0x04 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sme" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z31.d, z31.d, z31.d"

  -
    input:
      bytes: [ 0x20, 0xf0, 0x7f, 0x44 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sme" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z0.h, z1.h, z7.h[7]"

  -
    input:
      bytes: [ 0x20, 0xf0, 0xbf, 0x44 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sme" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z0.s, z1.s, z7.s[3]"

  -
    input:
      bytes: [ 0x20, 0xf0, 0xff, 0x44 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sme" ]
    expected:
      insns:
        -
          asm_text: "sqdmulh z0.d, z1.d, z15.d[1]"
