Changes between Version 8 and Version 9 of GcnInstrsVop2


Ignore:
Timestamp:
11/22/15 16:00:15 (8 years ago)
Author:
trac
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • GcnInstrsVop2

    v8 v9  
    490490Syntax VOP3b GCN 1.2: V_ADD_U32 VDST, SDST(2), SRC0, SRC1<br />
    491491Description: Add SRC0 to SRC1 and store result to VDST and store carry flag to
    492 SDST bit with number that equal to lane id. SDST is 64-bit.<br />
     492SDST (or VCC) bit with number that equal to lane id. SDST is 64-bit.<br />
    493493Operation:<br />
    494494<code>UINT64 temp = (UINT64)SRC0 + (UINT64)SRC1
    495495VDST = temp
    496496UINT64 mask = (1ULL&lt;&lt;LANEID)
     497SDST = (SDST&amp;~mask) | ((temp &gt;&gt; 32) ? mask : 0)</code></p>
     498<h4>V_ADDC_U32</h4>
     499<p>Opcode VOP2: 40 (0x28) for GCN 1.0/1.1; 28 (0x1c) for GCN 1.2<br />
     500Opcode VOP3b: 296 (0x128) for GCN 1.0/1.1; 284 (0x11c) for GCN 1.2<br />
     501Syntax VOP2 GCN 1.0/1.1: V_ADDC_U32 VDST, VCC, SRC0, SRC1, VCC<br />
     502Syntax VOP3b GCN 1.2: V_ADDC_U32 VDST, SDST(2), SRC0, SRC1, SSRC2(2)<br />
     503Description: Add SRC0 to SRC1 with carry stored in SSRC2 bit with number that equal lane id,
     504and store result to VDST and store carry flag to SDST (or VCC) bit with number
     505that equal to lane id. SDST and SSRC2 are 64-bit.<br />
     506Operation:<br />
     507<code>UINT64 mask = (1ULL&lt;&lt;LANEID)
     508UINT8 CC = ((SSRC2&amp;mask) ? 1 : 0)
     509UINT64 temp = (UINT64)SRC0 + (UINT64)SRC1 + CC
     510VDST = temp
    497511SDST = (SDST&amp;~mask) | ((temp &gt;&gt; 32) ? mask : 0)</code></p>
    498512<h4>V_AND_B32</h4>
     
    785799Syntax VOP3b GCN 1.2: V_SUB_U32 VDST, SDST(2), SRC0, SRC1<br />
    786800Description: Subtract SRC1 from SRC0 and store result to VDST and store borrow flag to
    787 SDST bit with number that equal to lane id. SDST is 64-bit.<br />
     801SDST (or VCC) bit with number that equal to lane id. SDST is 64-bit.<br />
    788802Operation:<br />
    789803<code>UINT64 temp = (UINT64)SRC0 - (UINT64)SRC1
     
    791805UINT64 mask = (1ULL&lt;&lt;LANEID)
    792806SDST = (SDST&amp;~mask) | ((temp&gt;&gt;32) ? mask : 0)</code></p>
     807<h4>V_SUBB_U32</h4>
     808<p>Opcode VOP2: 41 (0x29) for GCN 1.0/1.1; 29 (0x1d) for GCN 1.2<br />
     809Opcode VOP3b: 297 (0x129) for GCN 1.0/1.1; 285 (0x11d) for GCN 1.2<br />
     810Syntax VOP2 GCN 1.0/1.1: V_SUBB_U32 VDST, VCC, SRC0, SRC1, VCC<br />
     811Syntax VOP3b GCN 1.2: V_SUBB_U32 VDST, SDST(2), SRC0, SRC1, SSRC2(2)<br />
     812Description: Subtract SRC1 with borrow from SRC0,
     813and store result to VDST and store carry flag to SDST (or VCC) bit with number
     814that equal to lane id. Borrow is stored in SSRC2 bit with number of lane id.
     815SDST and SSRC2 are 64-bit.<br />
     816Operation:<br />
     817<code>UINT64 mask = (1ULL&lt;&lt;LANEID)
     818UINT8 CC = ((SSRC2&amp;mask) ? 1 : 0)
     819UINT64 temp = (UINT64)SRC0 - (UINT64)SRC1 - CC
     820VDST = temp
     821SDST = (SDST&amp;~mask) | ((temp &gt;&gt; 32) ? mask : 0)</code></p>
    793822<h4>V_SUBREV_F32</h4>
    794823<p>Opcode VOP2: 5 (0x5) for GCN 1.0/1.1; 2 (0x3) for GCN 1.2<br />
     
    798827Operation:<br />
    799828<code>VDST = (FLOAT)SRC1 - (FLOAT)SRC0</code></p>
     829<h4>V_SUBBREV_U32</h4>
     830<p>Opcode VOP2: 42 (0x2a) for GCN 1.0/1.1; 30 (0x1e) for GCN 1.2<br />
     831Opcode VOP3b: 298 (0x12a) for GCN 1.0/1.1; 286 (0x11e) for GCN 1.2<br />
     832Syntax VOP2 GCN 1.0/1.1: V_SUBBREV_U32 VDST, VCC, SRC0, SRC1, VCC<br />
     833Syntax VOP3b GCN 1.2: V_SUBBREV_U32 VDST, SDST(2), SRC0, SRC1, SSRC2(2)<br />
     834Description: Subtract SRC0 with borrow from SRC1,
     835and store result to VDST and store carry flag to SDST (or VCC) bit with number
     836that equal to lane id. Borrow is stored in SSRC2 bit with number of lane id.
     837SDST and SSRC2 are 64-bit.<br />
     838Operation:<br />
     839<code>UINT64 mask = (1ULL&lt;&lt;LANEID)
     840UINT8 CC = ((SSRC2&amp;mask) ? 1 : 0)
     841UINT64 temp = (UINT64)SRC1 - (UINT64)SRC0 - CC
     842VDST = temp
     843SDST = (SDST&amp;~mask) | ((temp &gt;&gt; 32) ? mask : 0)</code></p>
    800844<h4>V_SUBREV_I32, V_SUBREV_U32</h4>
    801845<p>Opcode VOP2: 39 (0x27) for GCN 1.0/1.1; 27 (0x1b) for GCN 1.2<br />
     
    806850Syntax VOP3b GCN 1.2: V_SUBREV_U32 VDST, SDST(2), SRC0, SRC1<br />
    807851Description: Subtract SRC0 from SRC1 and store result to VDST and store borrow flag to
    808 SDST bit with number that equal to lane id. SDST is 64-bit.<br />
     852SDST (or VCC) bit with number that equal to lane id. SDST is 64-bit.<br />
    809853Operation:<br />
    810854<code>UINT64 temp = (UINT64)SRC1 - (UINT64)SRC0