test_cases:
  -
    input:
      bytes: [ 0x00, 0xc0, 0xc0, 0xa4 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sve" ]
    expected:
      insns:
        -
          asm_text: "ld3h { z0.h - z2.h }, p0/z, [x0, x0, lsl #1]"

  -
    input:
      bytes: [ 0x25, 0xce, 0xd0, 0xa4 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sve" ]
    expected:
      insns:
        -
          asm_text: "ld3h { z5.h - z7.h }, p3/z, [x17, x16, lsl #1]"

  -
    input:
      bytes: [ 0x00, 0xe0, 0xc0, 0xa4 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sve" ]
    expected:
      insns:
        -
          asm_text: "ld3h { z0.h - z2.h }, p0/z, [x0]"

  -
    input:
      bytes: [ 0xb7, 0xed, 0xc8, 0xa4 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sve" ]
    expected:
      insns:
        -
          asm_text: "ld3h { z23.h - z25.h }, p3/z, [x13, #-24, mul vl]"

  -
    input:
      bytes: [ 0x55, 0xf5, 0xc5, 0xa4 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sve" ]
    expected:
      insns:
        -
          asm_text: "ld3h { z21.h - z23.h }, p5/z, [x10, #15, mul vl]"

  -
    input:
      bytes: [ 0x5e, 0xf5, 0xc5, 0xa4 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sve" ]
    expected:
      insns:
        -
          asm_text: "ld3h { z30.h, z31.h, z0.h }, p5/z, [x10, #15, mul vl]"

  -
    input:
      bytes: [ 0x00, 0xc0, 0xc0, 0xa4 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sme" ]
    expected:
      insns:
        -
          asm_text: "ld3h { z0.h - z2.h }, p0/z, [x0, x0, lsl #1]"

  -
    input:
      bytes: [ 0x25, 0xce, 0xd0, 0xa4 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sme" ]
    expected:
      insns:
        -
          asm_text: "ld3h { z5.h - z7.h }, p3/z, [x17, x16, lsl #1]"

  -
    input:
      bytes: [ 0x00, 0xe0, 0xc0, 0xa4 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sme" ]
    expected:
      insns:
        -
          asm_text: "ld3h { z0.h - z2.h }, p0/z, [x0]"

  -
    input:
      bytes: [ 0xb7, 0xed, 0xc8, 0xa4 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sme" ]
    expected:
      insns:
        -
          asm_text: "ld3h { z23.h - z25.h }, p3/z, [x13, #-24, mul vl]"

  -
    input:
      bytes: [ 0x55, 0xf5, 0xc5, 0xa4 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sme" ]
    expected:
      insns:
        -
          asm_text: "ld3h { z21.h - z23.h }, p5/z, [x10, #15, mul vl]"

  -
    input:
      bytes: [ 0x5e, 0xf5, 0xc5, 0xa4 ]
      arch: "CS_ARCH_AARCH64"
      options: [ "CS_OPT_ONLY_OFFSET_BRANCH", "aarch64", "sme" ]
    expected:
      insns:
        -
          asm_text: "ld3h { z30.h, z31.h, z0.h }, p5/z, [x10, #15, mul vl]"
