US 12,277,420 B2
Masked-vector-comparison instruction
Jacob Eapen, Cambridge (GB); Matthias Lothar Boettcher, Cambridge (GB); Balaji Venu, Cambridge (GB); and François Christopher Jacques Botman, Cambridge (GB)
Assigned to Arm Limited, Cambridge (GB)
Appl. No. 18/247,595
Filed by ARM LIMITED, Cambridge (GB)
PCT Filed Aug. 17, 2021, PCT No. PCT/GB2021/052130
§ 371(c)(1), (2) Date Mar. 31, 2023,
PCT Pub. No. WO2022/074355, PCT Pub. Date Apr. 14, 2022.
Claims priority of application No. 2015816 (GB), filed on Oct. 6, 2020.
Prior Publication US 2024/0028337 A1, Jan. 25, 2024
Int. Cl. G06F 9/30 (2018.01)
CPC G06F 9/30038 (2023.08) [G06F 9/30018 (2013.01); G06F 9/30021 (2013.01); G06F 9/30036 (2013.01)] 20 Claims
OG exemplary drawing
 
1. An apparatus comprising:
instruction decoder hardware configured to decode program instructions; and
processing circuitry configured to perform data processing in response to the program instructions decoded by the instruction decoder hardware; in which:
in response to decoding of a masked-vector-comparison instruction specifying a source vector operand comprising a plurality of source data elements, a mask value, and a comparison target operand, the instruction decoder hardware is configured to control the processing circuitry to:
for each active source data element of the source vector operand, determine whether the active source data element satisfies a comparison condition, based on a masked comparison between one or more compared bits of the active source data element and one or more compared bits of the comparison target operand, the mask value specifying a pattern of compared bits and non-compared bits within the comparison target operand and the active source data element, wherein for at least one encoding of the mask value, the mask value is configured to indicate that the pattern comprises, for a given active source data element, at least one compared bit and at least one non-compared bit; and
generate a result value indicative of which of the source data elements of the source vector operand, if any, is an active source data element satisfying the comparison condition.