发明名称 Vector string range compare
摘要 Processing of character data is facilitated. A Vector String Range Compare instruction is provided that compares each element of a vector with a range of values based on a set of controls to determine if there is a match. An index associated with the matched element or a mask representing the matched element is stored in a target vector register. Further, the same instruction, the Vector String Range Compare instruction, also searches a selected vector for null elements, also referred to as zero elements.
申请公布号 US9459864(B2) 申请公布日期 2016.10.04
申请号 US201213421560 申请日期 2012.03.15
申请人 INTERNATIONAL BUSINESS MACHINES CORPORATION 发明人 Bradbury Jonathan D.;Schwarz Eric M.;Slegel Timothy J.
分类号 G06F9/30 主分类号 G06F9/30
代理机构 Heslin Rothenberg Farley & Mesiti P.C. 代理人 Kinnaman, Jr., Esq. William A.;Hulihan, Esq. Matthew M.;Heslin Rothenberg Farley & Mesiti P.C.
主权项 1. A computer program product for executing a machine instruction in a central processing unit, the computer program product comprising: a non-transitory computer readable storage medium readable by a processing circuit and storing instructions for execution by the processing circuit for performing a method comprising: obtaining, by a processor, a machine instruction for execution, the machine instruction being defined for computer execution according to a computer architecture, the machine instruction comprising: at least one opcode field to provide an opcode, the opcode identifying a Vector String Range Compare operation;an extension field to be used in designating one or more registers;a first register field to designate a first register, the first register comprising a first operand;a second register field to designate a second register, the second register comprising a second operand;a third register field to designate a third register, the third register comprising a third operand;a fourth register field to designate a fourth register, the fourth register comprising a fourth operand; anda mask field, the mask field comprising one or more controls to be used during execution of the machine instruction; andexecuting the machine instruction, the execution comprising: identifying the first register based on a combination of the first register field and a first portion of the extension field, identifying the second register based on a combination of the second register field and a second portion of the extension field, identifying the third register based on a combination of the third register field and a third portion of the extension field, and identifying the fourth register based on a combination of the fourth register field and a fourth portion of the extension field;comparing each element of a plurality of elements of the second operand with each value of one or more values of the third operand using one or more controls programmatically provided by the fourth operand to determine whether there is a match as defined by the one or more values of the third operand and the one or more controls of the fourth operand, wherein the one or more values of the third operand form one or more pairs of values representing one or more ranges against which each element of the plurality of elements of the second operand is compared, and wherein the comparing provides one or more indicators for each element of the plurality of elements of the second operand, wherein each indicator of the one of more indicators for an element corresponds to a range of the one or more ranges and indicates whether the element is within the range; and providing a result in the first operand based on the comparing.
地址 Armonk NY US