Changes between Version 22 and Version 23 of GcnInstrsVop2


Ignore:
Timestamp:
12/12/15 23:01:08 (8 years ago)
Author:
trac
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • GcnInstrsVop2

    v22 v23  
    549549Syntax VOP3B GCN 1.2: V_ADD_U32 VDST, SDST(2), SRC0, SRC1<br />
    550550Description: Add SRC0 to SRC1 and store result to VDST and store carry flag to
    551 SDST (or VCC) bit with number that equal to lane id. SDST is 64-bit.<br />
     551SDST (or VCC) bit with number that equal to lane id. SDST is 64-bit.
     552Bits for inactive threads in SDST are always zeroed.<br />
    552553Operation:<br />
    553554<code>UINT64 temp = (UINT64)SRC0 + (UINT64)SRC1
    554555VDST = temp
     556SDS = 0
    555557UINT64 mask = (1ULL&lt;&lt;LANEID)
    556558SDST = (SDST&amp;~mask) | ((temp &gt;&gt; 32) ? mask : 0)</code></p>
     
    562564Description: Add SRC0 to SRC1 with carry stored in SSRC2 bit with number that equal lane id,
    563565and store result to VDST and store carry flag to SDST (or VCC) bit with number
    564 that equal to lane id. SDST and SSRC2 are 64-bit.<br />
     566that equal to lane id. SDST and SSRC2 are 64-bit.
     567Bits for inactive threads in SDST are always zeroed.<br />
    565568Operation:<br />
    566569<code>UINT64 mask = (1ULL&lt;&lt;LANEID)
    567570UINT8 CC = ((SSRC2&amp;mask) ? 1 : 0)
    568571UINT64 temp = (UINT64)SRC0 + (UINT64)SRC1 + CC
     572SDST = 0
    569573VDST = temp
    570574SDST = (SDST&amp;~mask) | ((temp &gt;&gt; 32) ? mask : 0)</code></p>
     
    936940Syntax VOP3B GCN 1.2: V_SUB_U32 VDST, SDST(2), SRC0, SRC1<br />
    937941Description: Subtract SRC1 from SRC0 and store result to VDST and store borrow flag to
    938 SDST (or VCC) bit with number that equal to lane id. SDST is 64-bit.<br />
     942SDST (or VCC) bit with number that equal to lane id. SDST is 64-bit.
     943Bits for inactive threads in SDST are always zeroed.<br />
    939944Operation:<br />
    940945<code>UINT64 temp = (UINT64)SRC0 - (UINT64)SRC1
    941946VDST = temp
     947SDST = 0
    942948UINT64 mask = (1ULL&lt;&lt;LANEID)
    943949SDST = (SDST&amp;~mask) | ((temp&gt;&gt;32) ? mask : 0)</code></p>
     
    950956and store result to VDST and store carry flag to SDST (or VCC) bit with number
    951957that equal to lane id. Borrow is stored in SSRC2 bit with number of lane id.
    952 SDST and SSRC2 are 64-bit.<br />
     958SDST and SSRC2 are 64-bit. Bits for inactive threads in SDST are always zeroed.<br />
    953959Operation:<br />
    954960<code>UINT64 mask = (1ULL&lt;&lt;LANEID)
    955961UINT8 CC = ((SSRC2&amp;mask) ? 1 : 0)
    956962UINT64 temp = (UINT64)SRC0 - (UINT64)SRC1 - CC
     963SDST = 0
    957964VDST = temp
    958965SDST = (SDST&amp;~mask) | ((temp &gt;&gt; 32) ? mask : 0)</code></p>
     
    965972and store result to VDST and store carry flag to SDST (or VCC) bit with number
    966973that equal to lane id. Borrow is stored in SSRC2 bit with number of lane id.
    967 SDST and SSRC2 are 64-bit.<br />
     974SDST and SSRC2 are 64-bit. Bits for inactive threads in SDST are always zeroed.<br />
    968975Operation:<br />
    969976<code>UINT64 mask = (1ULL&lt;&lt;LANEID)
    970977UINT8 CC = ((SSRC2&amp;mask) ? 1 : 0)
    971978UINT64 temp = (UINT64)SRC1 - (UINT64)SRC0 - CC
     979SDST = 0
    972980VDST = temp
    973981SDST = (SDST&amp;~mask) | ((temp &gt;&gt; 32) ? mask : 0)</code></p>
     
    987995Syntax VOP3B GCN 1.2: V_SUBREV_U32 VDST, SDST(2), SRC0, SRC1<br />
    988996Description: Subtract SRC0 from SRC1 and store result to VDST and store borrow flag to
    989 SDST (or VCC) bit with number that equal to lane id. SDST is 64-bit.<br />
     997SDST (or VCC) bit with number that equal to lane id. SDST is 64-bit.
     998Bits for inactive threads in SDST are always zeroed.<br />
    990999Operation:<br />
    9911000<code>UINT64 temp = (UINT64)SRC1 - (UINT64)SRC0
    9921001VDST = temp
     1002SDST = 0
    9931003UINT64 mask = (1ULL&lt;&lt;LANEID)
    9941004SDST = (SDST&amp;~mask) | ((temp&gt;&gt;32) ? mask : 0)</code></p>