20.218 SUBHN, SUBHN2 (vector)

Subtract returning High Narrow.

Syntax

SUBHN{2} Vd.Tb, Vn.Ta, Vm.Ta

Where:

2
Is the second and upper half specifier. If present it causes the operation to be performed on the upper 64 bits of the registers holding the narrower elements. See <Q> in the Usage table.
Vd
Is the name of the SIMD and FP destination register.
Tb
Is an arrangement specifier, and can be one of the values shown in Usage.
Vn
Is the name of the first SIMD and FP source register.
Ta
Is an arrangement specifier, and can be one of the values shown in Usage.
Vm
Is the name of the second SIMD and FP source register.

Usage

Subtract returning High Narrow. This instruction subtracts each vector element in the second source SIMD and FP register from the corresponding vector element in the first source SIMD and FP register, places the most significant half of the result into a vector, and writes the vector to the lower or upper half of the destination SIMD and FP register. All the values in this instruction are signed integer values.

The results are truncated. For rounded results, see 20.139 RSUBHN, RSUBHN2 (vector).

The SUBHN instruction writes the vector to the lower half of the destination register and clears the upper half, while the SUBHN2 instruction writes the vector to the upper half of the destination register without affecting the other bits of the register.

Depending on the settings in the CPACR_EL1, CPTR_EL2, and CPTR_EL3 registers, and the current Security state and Exception level, an attempt to execute the instruction might be trapped.

The following table shows the valid specifier combinations:

Table 20-87 SUBHN, SUBHN2 (Vector) specifier combinations

<Q> Tb Ta
- 8B 8H
2 16B 8H
- 4H 4S
2 8H 4S
- 2S 2D
2 4S 2D
Non-ConfidentialPDF file icon PDF versionDUI0801J
Copyright © 2014–2017, 2019 Arm Limited or its affiliates. All rights reserved.