Subversion Repositories Kolibri OS

Rev

Blame | Last modification | View Log | RSS feed

  1. /*
  2.  *  Copyright 2000-2011 Intel Corporation All Rights Reserved
  3.  *
  4.  * Permission is hereby granted, free of charge, to any person obtaining a
  5.  * copy of this software and associated documentation files (the
  6.  * "Software"), to deal in the Software without restriction, including
  7.  * without limitation the rights to use, copy, modify, merge, publish,
  8.  * distribute, sub license, and/or sell copies of the Software, and to
  9.  * permit persons to whom the Software is furnished to do so, subject to
  10.  * the following conditions:
  11.  *
  12.  * The above copyright notice and this permission notice (including the
  13.  * next paragraph) shall be included in all copies or substantial portions
  14.  * of the Software.
  15.  *
  16.  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
  17.  * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  18.  * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
  19.  * IN NO EVENT SHALL PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR
  20.  * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
  21.  * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
  22.  * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  23.  *
  24.  * This file was originally licensed under the following license
  25.  *
  26.  *  Licensed under the Apache License, Version 2.0 (the "License");
  27.  *  you may not use this file except in compliance with the License.
  28.  *  You may obtain a copy of the License at
  29.  *
  30.  *      http://www.apache.org/licenses/LICENSE-2.0
  31.  *
  32.  *  Unless required by applicable law or agreed to in writing, software
  33.  *  distributed under the License is distributed on an "AS IS" BASIS,
  34.  *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  35.  *  See the License for the specific language governing permissions and
  36.  *  limitations under the License.
  37.  */
  38. //  174    // Total instruction count
  39. //    1    // Total kernel count
  40.  
  41.  
  42.  
  43. // Module name: common.inc
  44. //
  45. // Common header file for all Video-Processing kernels
  46. //
  47.  
  48. .default_execution_size (16)
  49. .default_register_type  :ub
  50.  
  51. .reg_count_total        128
  52. .reg_count_payload      7
  53.  
  54. //========== Common constants ==========
  55.  
  56.  
  57. //========== Macros ==========
  58.  
  59.  
  60. //Fast Jump, For more details see "Set_Layer_N.asm"
  61.  
  62.  
  63. //========== Defines ====================
  64.  
  65. //========== Static Parameters (Common To All) ==========
  66. //r1
  67.  
  68.  
  69. //r2
  70.  
  71.                                     //  e.g.            byte0   byte1  byte2
  72.                                     // YUYV               0       1      3
  73.                                     // YVYU               0       3      1
  74.  
  75. //Color Pipe (IECP) parameters
  76.  
  77.  
  78. //ByteCopy
  79.  
  80.  
  81. //r4
  82.  
  83.                                     //  e.g.              byte0           byte1           byte2
  84.                                     // YUYV                 0               1               3
  85.                                     // YVYU                 0               3               1
  86.  
  87.  
  88. //========== Inline parameters (Common To All) ===========
  89.  
  90.  
  91. //============== Binding Index Table===========
  92. //Common between DNDI and DNUV
  93.  
  94.  
  95. //================= Common Message Descriptor =====
  96. // Message descriptor for thread spawning
  97. // Message Descriptors
  98. //                = 000 0001 (min message len 1 ) 0,0000 (resp len 0   -add later)
  99. //                  0000,0000,0000
  100. //                  0001(Spawn a root thread),0001 (Root thread spawn thread)
  101. //                = 0x02000011
  102. // Thread Spawner Message Descriptor
  103.  
  104.  
  105. // Message descriptor for atomic operation add
  106. // Message Descriptors
  107. //                = 000 0110 (min message len 6 ) 0,0000 (resp len 0   -add later)
  108. //                  1(header present)001,10(typed atomic operation)0(return enabled)0(slot group, low 8 bits),0111 (AOP_Add)
  109. //                  0000,0000 (Binding table index, added later)
  110. //                = 0x02000011
  111.  
  112. // Atomic Operation Add Message Descriptor
  113.  
  114.  
  115. // Message descriptor for dataport media write
  116.         // Message Descriptors
  117.                 //                = 000 0001 (min message len 1 - add later) 00000 (resp len 0)
  118.                 //                  1 (header present 1) 0 1010 (media block write) 000000
  119.                 //                  00000000 (binding table index - set later)
  120.                 //                = 0x020A8000
  121.  
  122.  
  123. // Message Length defines
  124.  
  125.  
  126. // Response Length defines
  127.  
  128.  
  129. // Block Width and Height Size defines
  130.  
  131.  
  132. // Extended Message Descriptors
  133.  
  134.  
  135. // Common message descriptors:
  136.  
  137.  
  138. //===================== Math Function Control ===================================
  139.  
  140.  
  141. //============ Message Registers ===============
  142.                              // buf4 starts from r28
  143.  
  144.  
  145. //#define mMSGHDR_EOT  r43    // Dummy Message Register for EOT
  146.  
  147.  
  148. .declare    mubMSGPAYLOAD  Base=r30 ElementSize=1 SrcRegion=<16;16,1> Type=ub
  149. .declare    muwMSGPAYLOAD  Base=r30 ElementSize=2 SrcRegion=<16;16,1> Type=uw
  150. .declare    mudMSGPAYLOAD  Base=r30 ElementSize=4 SrcRegion=<8;8,1> Type=ud
  151. .declare    mfMSGPAYLOAD   Base=r30 ElementSize=4 SrcRegion=<8;8,1> Type=f
  152.  
  153. //=================== End of thread instruction ===========================
  154.  
  155.  
  156. //=====================Pointers Used=====================================
  157.  
  158.  
  159. //=======================================================================
  160.  
  161.  
  162. //r11-r17
  163. // Define temp space for any usages
  164.  
  165.  
  166. // Common Buffers
  167.  
  168.  
  169. // temp space for rotation
  170.  
  171. .declare fROBUF           Base=r11.0            ElementSize=4           SrcRegion=<8;8,1>                 DstRegion=<1>         Type=f
  172.  
  173. .declare udROBUF                Base=r11.0              ElementSize=4           SrcRegion=<8;8,1>                 DstRegion=<1>         Type=ud
  174.  
  175. .declare uwROBUF                Base=r11.0              ElementSize=2           SrcRegion=<16;16,1>             DstRegion=<1>           Type=uw
  176.  
  177. .declare ubROBUF                Base=r11.0              ElementSize=1           SrcRegion=<16;16,1>             DstRegion=<1>           Type=ub
  178.  
  179. .declare ub4ROBUF       Base=r11.0              ElementSize=1           SrcRegion=<32;8,4>              DstRegion=<4>           Type=ub
  180.  
  181.  
  182. // End of common.inc
  183.  
  184.  
  185. // Module name: Save_AVS_PA.asm
  186. //
  187. // Save PA 422 frame data block of size 16x16
  188. //
  189. // To save 16x16 block (32x16 bytes of YUYV) we need 2 send instructions with of size 16x16 each.
  190. //  -------------------------------
  191. //  |    16x16    |    16x16      |
  192. //  |    YUYV     |    YUYV       |
  193. //  -------------------------------
  194. // these 2 sends are replaced by 8 32x2 sends to improve performance
  195.  
  196.  
  197.  
  198. // Module name: Save.inc
  199.  
  200.  
  201.  
  202.  
  203. // Description: Includes all definitions explicit to Fast Composite.
  204.  
  205.  
  206.  
  207.  
  208. // End of common.inc
  209.  
  210.  
  211. //========== GRF partition ==========
  212.      // r0 header            :   r0          (1 GRF)
  213.      // Static parameters    :   r1 - r6     (6 GRFS)
  214.      // Inline parameters    :   r7 - r8     (2 GRFs)
  215.      // MSGSRC               :   r27         (1 GRF)
  216. //===================================
  217.  
  218. //Interface:
  219. //========== Static Parameters (Explicit To Fast Composite) ==========
  220. //r1
  221. //CSC Set 0
  222.  
  223.  
  224. .declare udCSC_CURBE    Base=r1.0      ElementSize=4       Type=ud
  225.  
  226. //Constant alpha
  227.  
  228.  
  229. //r2
  230.  
  231.  
  232. // Gen7 AVS WA
  233.  
  234.  
  235. // WiDi Definitions
  236.  
  237.  
  238. //Colorfill
  239.  
  240.  
  241.                                       // 0: 0-degree, 1: 90, 2: 180, 3: 270-degree, clockwise.     
  242.  
  243. .declare ubCOLOR_PIXEL_VAL      Base=r2.20      ElementSize=1       SrcRegion=<0;1,0>       DstRegion=<1>       Type=ub
  244.  
  245. //r3
  246. //Normalised Ratio of Horizontal step size with main video for all layers
  247.  
  248.  
  249.     //Normalised Ratio of Horizontal step size with main video for all layers becomes
  250.     //Normalised Horizontal step size for all layers in VP_Setup.asm
  251.  
  252.  
  253. //r4
  254. //Normalised Vertical step size for all layers
  255.  
  256.  
  257. //r5
  258. //Normalised Vertical Frame Origin for all layers
  259.  
  260.  
  261. //r6
  262. //Normalised Horizontal Frame Origin for all layers
  263.  
  264.  
  265. //========== Inline Parameters (Explicit To Fast Composite) ==========
  266.  
  267.  
  268. //Main video Step X
  269.  
  270.  
  271. //====================== Binding table (Explicit To Fast Composite)=========================================
  272.  
  273.  
  274. //Used by Interlaced Scaling Kernels
  275.  
  276.  
  277. //========== Sampler State Table Index (Explicit To Fast Composite)==========
  278. //Sampler Index for AVS/IEF messages
  279.  
  280.  
  281. //Sampler Index for SIMD16 sampler messages
  282.  
  283.  
  284. //=============================================================================
  285.  
  286. .declare fBUFFER_0      Base=r64.0       ElementSize=4       SrcRegion=<8;8,1>       DstRegion=<1>       Type=f
  287. .declare fBUFFER_1      Base=r80.0       ElementSize=4       SrcRegion=<8;8,1>       DstRegion=<1>       Type=f
  288. .declare fBUFFER_2      Base=r96.0       ElementSize=4       SrcRegion=<8;8,1>       DstRegion=<1>       Type=f
  289. .declare fBUFFER_3      Base=r112.0       ElementSize=4       SrcRegion=<8;8,1>       DstRegion=<1>       Type=f
  290. .declare fBUFFER_4      Base=r28.0       ElementSize=4       SrcRegion=<8;8,1>       DstRegion=<1>       Type=f
  291. .declare fBUFFER_5      Base=r46.0       ElementSize=4       SrcRegion=<8;8,1>       DstRegion=<1>       Type=f
  292.  
  293. .declare udBUFFER_0     Base=r64.0       ElementSize=4       SrcRegion=<8;8,1>       DstRegion=<1>       Type=ud
  294. .declare udBUFFER_1     Base=r80.0       ElementSize=4       SrcRegion=<8;8,1>       DstRegion=<1>       Type=ud
  295. .declare udBUFFER_2     Base=r96.0       ElementSize=4       SrcRegion=<8;8,1>       DstRegion=<1>       Type=ud
  296. .declare udBUFFER_3     Base=r112.0       ElementSize=4       SrcRegion=<8;8,1>       DstRegion=<1>       Type=ud
  297. .declare udBUFFER_4     Base=r28.0       ElementSize=4       SrcRegion=<8;8,1>       DstRegion=<1>       Type=ud
  298. .declare udBUFFER_5     Base=r46.0       ElementSize=4       SrcRegion=<8;8,1>       DstRegion=<1>       Type=ud
  299.  
  300. .declare uwBUFFER_0     Base=r64.0       ElementSize=2       SrcRegion=<16;16,1>     DstRegion=<1>       Type=uw
  301. .declare uwBUFFER_1     Base=r80.0       ElementSize=2       SrcRegion=<16;16,1>     DstRegion=<1>       Type=uw
  302. .declare uwBUFFER_2     Base=r96.0       ElementSize=2       SrcRegion=<16;16,1>     DstRegion=<1>       Type=uw
  303. .declare uwBUFFER_3     Base=r112.0       ElementSize=2       SrcRegion=<16;16,1>     DstRegion=<1>       Type=uw
  304. .declare uwBUFFER_4     Base=r28.0       ElementSize=2       SrcRegion=<16;16,1>     DstRegion=<1>       Type=uw
  305. .declare uwBUFFER_5     Base=r46.0       ElementSize=2       SrcRegion=<16;16,1>     DstRegion=<1>       Type=uw
  306.  
  307. .declare ubBUFFER_0     Base=r64.0       ElementSize=1       SrcRegion=<16;16,1>     DstRegion=<1>       Type=ub
  308. .declare ubBUFFER_1     Base=r80.0       ElementSize=1       SrcRegion=<16;16,1>     DstRegion=<1>       Type=ub
  309. .declare ubBUFFER_2     Base=r96.0       ElementSize=1       SrcRegion=<16;16,1>     DstRegion=<1>       Type=ub
  310. .declare ubBUFFER_3     Base=r112.0       ElementSize=1       SrcRegion=<16;16,1>     DstRegion=<1>       Type=ub
  311. .declare ubBUFFER_4     Base=r28.0       ElementSize=1       SrcRegion=<16;16,1>     DstRegion=<1>       Type=ub
  312. .declare ubBUFFER_5     Base=r46.0       ElementSize=1       SrcRegion=<16;16,1>     DstRegion=<1>       Type=ub
  313.  
  314. .declare ub4BUFFER_0    Base=r64.0       ElementSize=1       SrcRegion=<32;8,4>      DstRegion=<4>       Type=ub
  315. .declare ub4BUFFER_1    Base=r80.0       ElementSize=1       SrcRegion=<32;8,4>      DstRegion=<4>       Type=ub
  316. .declare ub4BUFFER_2    Base=r96.0       ElementSize=1       SrcRegion=<32;8,4>      DstRegion=<4>       Type=ub
  317. .declare ub4BUFFER_3    Base=r112.0       ElementSize=1       SrcRegion=<32;8,4>      DstRegion=<4>       Type=ub
  318. .declare ub4BUFFER_4    Base=r28.0       ElementSize=1       SrcRegion=<32;8,4>      DstRegion=<4>       Type=ub
  319. .declare ub4BUFFER_5    Base=r46.0       ElementSize=1       SrcRegion=<32;8,4>      DstRegion=<4>       Type=ub
  320.  
  321. //Pointer to mask reg
  322.  
  323.  
  324. //r18
  325.  
  326.  
  327. //Always keep Cannel Pointers and Offsets in same GRF, so that we can use
  328. // NODDCLR, NODDCHK flags. -rT
  329.  
  330.  
  331. .declare udCSC_COEFF_0  Base=r18.0    ElementSize=4 Type=ud       // 1 GRF
  332.  
  333. //r19
  334.  
  335.  
  336. .declare udCSC_COEFF_1  Base=r19.0    ElementSize=4 Type=ud       // 1 GRF
  337.  
  338.  
  339. //r20
  340.  
  341. .declare uwALPHA_MASK_REG_TEMP  Base=r20.0    ElementSize=2 SrcRegion=<16;16,1> Type=uw        // 1 GRF
  342.  
  343. //r21
  344.  
  345. .declare uwALPHA_MASK_REG       Base=r21.0         ElementSize=2 SrcRegion=<16;16,1> Type=uw        // 1 GRF
  346.  
  347. //r22
  348.  
  349.  
  350. //Always keep Cannel Pointers and Offsets in same GRF, so that we can use
  351. // NODDCLR, NODDCHK flags. -rT
  352.  
  353.  
  354. //Keep fORIGIN_X_NLAS, fY_OFFSET_2ND_BLOCK, fSTEP_X_NLAS, pMSGDSC_COPY, ubCONST_ALPHA_COPY as
  355. //sub registers of same GRF to enable using NODDCLR NODDCHK. -rT
  356.  
  357. //r23
  358.  
  359.  
  360. //Lumakey
  361.  
  362.  
  363. //r24
  364.  
  365.  
  366. //r25
  367.  
  368.  
  369. //r26
  370.  
  371.  
  372. //defines to generate LABELS during compile time.
  373.  
  374.  
  375. //Msg payload buffers; upto 4 full-size messages can be written
  376.  
  377.  
  378. .declare    mudMSGPAYLOAD0  Base=r29.0 ElementSize=4 SrcRegion=<8;8,1> Type=ud
  379. .declare    mudMSGPAYLOAD1  Base=r38.0 ElementSize=4 SrcRegion=<8;8,1> Type=ud
  380. .declare    mudMSGPAYLOAD2  Base=r47.0 ElementSize=4 SrcRegion=<8;8,1> Type=ud
  381. .declare    mudMSGPAYLOAD3  Base=r56.0 ElementSize=4 SrcRegion=<8;8,1> Type=ud
  382.  
  383. .declare    muwMSGPAYLOAD0  Base=r29.0 ElementSize=2 SrcRegion=<16;16,1> Type=uw
  384. .declare    muwMSGPAYLOAD1  Base=r38.0 ElementSize=2 SrcRegion=<16;16,1> Type=uw
  385. .declare    muwMSGPAYLOAD2  Base=r47.0 ElementSize=2 SrcRegion=<16;16,1> Type=uw
  386. .declare    muwMSGPAYLOAD3  Base=r56.0 ElementSize=2 SrcRegion=<16;16,1> Type=uw
  387.  
  388. .declare    mubMSGPAYLOAD0  Base=r29.0 ElementSize=1 SrcRegion=<16;16,1> Type=ub
  389. .declare    mubMSGPAYLOAD1  Base=r38.0 ElementSize=1 SrcRegion=<16;16,1> Type=ub
  390. .declare    mubMSGPAYLOAD2  Base=r47.0 ElementSize=1 SrcRegion=<16;16,1> Type=ub
  391. .declare    mubMSGPAYLOAD3  Base=r56.0 ElementSize=1 SrcRegion=<16;16,1> Type=ub
  392. .declare    mubMSGPAYLOAD4  Base=r32.0 ElementSize=1 SrcRegion=<16;16,1> Type=ub
  393. .declare    mubMSGPAYLOAD5  Base=r41.0 ElementSize=1 SrcRegion=<16;16,1> Type=ub
  394. .declare    mubMSGPAYLOAD6  Base=r50.0 ElementSize=1 SrcRegion=<16;16,1> Type=ub
  395. .declare    mubMSGPAYLOAD7  Base=r59.0 ElementSize=1 SrcRegion=<16;16,1> Type=ub
  396.  
  397.  
  398.         // the r17 register (nTEMP0) is originally defined from "Common.inc"
  399.         // instead of re-defining a nTEMP0 here, we use "SAVE_RGB" suffix for its naming
  400.  
  401.         .declare uwTemp0 Base=r17.0 ElementSize=2 Type=uw
  402.  
  403.  
  404. //_SAVE_INC_
  405.  
  406.  
  407.         //wBUFF_CHNL_PTR points to buffer 0.
  408.         //Add appropriate offsets to get pointers for all buffers (1,2,3).
  409.         //Offset is zero for buffer 0.
  410.         add   (4)   a0.0:uw   r22.0<4;4,1>:w          0:uw
  411.  
  412.         //Set DEST pointers according to output packing i.e. YUYV, YVYU, UYVY, VYUY
  413.         add     (4)             a0.4<1>:w                       r2.28<4;4,1>:ub    928:uw
  414.  
  415.     shl (1) r27.0<1>:d      r9.0<0;1,0>:w            1:w                         { NoDDClr }            // H. block origin need to be 2 times
  416.     mov (1) r27.1<1>:d      r9.1<0;1,0>:w                                        { NoDDClr, NoDDChk }   // Block origin (1st quadrant)
  417.     mov (1) r27.2<1>:ud     0x1001F:ud           { NoDDChk }            // Block width and height (32x2)
  418.  
  419. // Rounding
  420.         // left
  421.         add.sat (4)     r[a0.0, 0]<2>:uw                r[a0.0,  0]<8;4,2>:uw           0x0080:uw                      
  422.         add.sat (4)     r[a0.0,32]<2>:uw                r[a0.0, 32]<8;4,2>:uw           0x0080:uw                      
  423.         add.sat (4)     r[a0.0,64]<2>:uw                r[a0.0, 64]<8;4,2>:uw           0x0080:uw                      
  424.         add.sat (4)     r[a0.0,96]<2>:uw                r[a0.0, 96]<8;4,2>:uw           0x0080:uw                      
  425.  
  426.         add.sat (8)     r[a0.1, 0]<1>:uw                r[a0.1,  0]<8;8,1>:uw           0x0080:uw                      
  427.         add.sat (8)     r[a0.1,32]<1>:uw                r[a0.1, 32]<8;8,1>:uw           0x0080:uw                      
  428.         add.sat (8)     r[a0.1,64]<1>:uw                r[a0.1, 64]<8;8,1>:uw           0x0080:uw                      
  429.         add.sat (8)     r[a0.1,96]<1>:uw                r[a0.1, 96]<8;8,1>:uw           0x0080:uw                      
  430.  
  431.         add.sat (4)     r[a0.2, 0]<2>:uw                r[a0.2,  0]<8;4,2>:uw           0x0080:uw                      
  432.         add.sat (4)     r[a0.2,32]<2>:uw                r[a0.2, 32]<8;4,2>:uw           0x0080:uw                      
  433.         add.sat (4)     r[a0.2,64]<2>:uw                r[a0.2, 64]<8;4,2>:uw           0x0080:uw                      
  434.         add.sat (4)     r[a0.2,96]<2>:uw                r[a0.2, 96]<8;4,2>:uw           0x0080:uw                      
  435.  
  436.         // right
  437.         add.sat (4)     r[a0.0,16]<2>:uw                        r[a0.0, 16]<8;4,2>:uw                   0x0080:uw                      
  438.         add.sat (4)     r[a0.0,48]<2>:uw                r[a0.0, 48]<8;4,2>:uw           0x0080:uw                      
  439.         add.sat (4)     r[a0.0,80]<2>:uw                r[a0.0, 80]<8;4,2>:uw           0x0080:uw                      
  440.         add.sat (4)     r[a0.0,112]<2>:uw               r[a0.0, 112]<8;4,2>:uw          0x0080:uw                      
  441.  
  442.         add.sat (8)     r[a0.1, 16]<1>:uw                       r[a0.1, 16]<8;8,1>:uw                   0x0080:uw                      
  443.         add.sat (8)     r[a0.1,48]<1>:uw                r[a0.1, 48]<8;8,1>:uw           0x0080:uw                      
  444.         add.sat (8)     r[a0.1,80]<1>:uw                r[a0.1, 80]<8;8,1>:uw           0x0080:uw                      
  445.         add.sat (8)     r[a0.1,112]<1>:uw               r[a0.1, 112]<8;8,1>:uw          0x0080:uw                      
  446.  
  447.         add.sat (4)     r[a0.2, 16]<2>:uw                       r[a0.2,  16]<8;4,2>:uw          0x0080:uw                      
  448.         add.sat (4)     r[a0.2,48]<2>:uw                r[a0.2, 48]<8;4,2>:uw           0x0080:uw                      
  449.         add.sat (4)     r[a0.2,80]<2>:uw                r[a0.2, 80]<8;4,2>:uw           0x0080:uw                      
  450.         add.sat (4)     r[a0.2,112]<2>:uw               r[a0.2, 112]<8;4,2>:uw          0x0080:uw                      
  451.  
  452.     add (4)    a0.0:uw    r22.0<4;4,1>:w    512:uw
  453.         // left
  454.         add.sat (4)     r[a0.0, 0]<2>:uw                r[a0.0,  0]<8;4,2>:uw           0x0080:uw                      
  455.         add.sat (4)     r[a0.0,32]<2>:uw                r[a0.0, 32]<8;4,2>:uw           0x0080:uw                      
  456.         add.sat (4)     r[a0.0,64]<2>:uw                r[a0.0, 64]<8;4,2>:uw           0x0080:uw                      
  457.         add.sat (4)     r[a0.0,96]<2>:uw                r[a0.0, 96]<8;4,2>:uw           0x0080:uw                      
  458.  
  459.         add.sat (8)     r[a0.1, 0]<1>:uw                r[a0.1,  0]<8;8,1>:uw           0x0080:uw                      
  460.         add.sat (8)     r[a0.1,32]<1>:uw                r[a0.1, 32]<8;8,1>:uw           0x0080:uw                      
  461.         add.sat (8)     r[a0.1,64]<1>:uw                r[a0.1, 64]<8;8,1>:uw           0x0080:uw                      
  462.         add.sat (8)     r[a0.1,96]<1>:uw                r[a0.1, 96]<8;8,1>:uw           0x0080:uw                      
  463.  
  464.         add.sat (4)     r[a0.2, 0]<2>:uw                r[a0.2,  0]<8;4,2>:uw           0x0080:uw                      
  465.         add.sat (4)     r[a0.2,32]<2>:uw                r[a0.2, 32]<8;4,2>:uw           0x0080:uw                      
  466.         add.sat (4)     r[a0.2,64]<2>:uw                r[a0.2, 64]<8;4,2>:uw           0x0080:uw                      
  467.         add.sat (4)     r[a0.2,96]<2>:uw                r[a0.2, 96]<8;4,2>:uw           0x0080:uw                      
  468.  
  469.         // right
  470.         add.sat (4)     r[a0.0,16]<2>:uw                        r[a0.0, 16]<8;4,2>:uw                   0x0080:uw                      
  471.         add.sat (4)     r[a0.0,48]<2>:uw                r[a0.0, 48]<8;4,2>:uw           0x0080:uw                      
  472.         add.sat (4)     r[a0.0,80]<2>:uw                r[a0.0, 80]<8;4,2>:uw           0x0080:uw                      
  473.         add.sat (4)     r[a0.0,112]<2>:uw               r[a0.0, 112]<8;4,2>:uw          0x0080:uw                      
  474.  
  475.         add.sat (8)     r[a0.1, 16]<1>:uw                       r[a0.1, 16]<8;8,1>:uw                   0x0080:uw                      
  476.         add.sat (8)     r[a0.1,48]<1>:uw                r[a0.1, 48]<8;8,1>:uw           0x0080:uw                      
  477.         add.sat (8)     r[a0.1,80]<1>:uw                r[a0.1, 80]<8;8,1>:uw           0x0080:uw                      
  478.         add.sat (8)     r[a0.1,112]<1>:uw               r[a0.1, 112]<8;8,1>:uw          0x0080:uw                      
  479.  
  480.         add.sat (4)     r[a0.2, 16]<2>:uw                       r[a0.2,  16]<8;4,2>:uw          0x0080:uw                      
  481.         add.sat (4)     r[a0.2,48]<2>:uw                r[a0.2, 48]<8;4,2>:uw           0x0080:uw                      
  482.         add.sat (4)     r[a0.2,80]<2>:uw                r[a0.2, 80]<8;4,2>:uw           0x0080:uw                      
  483.         add.sat (4)     r[a0.2,112]<2>:uw               r[a0.2, 112]<8;4,2>:uw          0x0080:uw                      
  484.  
  485.     add (4)    a0.0:uw    r22.0<4;4,1>:w    1024:uw
  486.         // left
  487.         add.sat (4)     r[a0.0, 0]<2>:uw                r[a0.0,  0]<8;4,2>:uw           0x0080:uw                      
  488.         add.sat (4)     r[a0.0,32]<2>:uw                r[a0.0, 32]<8;4,2>:uw           0x0080:uw                      
  489.         add.sat (4)     r[a0.0,64]<2>:uw                r[a0.0, 64]<8;4,2>:uw           0x0080:uw                      
  490.         add.sat (4)     r[a0.0,96]<2>:uw                r[a0.0, 96]<8;4,2>:uw           0x0080:uw                      
  491.  
  492.         add.sat (8)     r[a0.1, 0]<1>:uw                r[a0.1,  0]<8;8,1>:uw           0x0080:uw                      
  493.         add.sat (8)     r[a0.1,32]<1>:uw                r[a0.1, 32]<8;8,1>:uw           0x0080:uw                      
  494.         add.sat (8)     r[a0.1,64]<1>:uw                r[a0.1, 64]<8;8,1>:uw           0x0080:uw                      
  495.         add.sat (8)     r[a0.1,96]<1>:uw                r[a0.1, 96]<8;8,1>:uw           0x0080:uw                      
  496.  
  497.         add.sat (4)     r[a0.2, 0]<2>:uw                r[a0.2,  0]<8;4,2>:uw           0x0080:uw                      
  498.         add.sat (4)     r[a0.2,32]<2>:uw                r[a0.2, 32]<8;4,2>:uw           0x0080:uw                      
  499.         add.sat (4)     r[a0.2,64]<2>:uw                r[a0.2, 64]<8;4,2>:uw           0x0080:uw                      
  500.         add.sat (4)     r[a0.2,96]<2>:uw                r[a0.2, 96]<8;4,2>:uw           0x0080:uw                      
  501.  
  502.         // right
  503.         add.sat (4)     r[a0.0,16]<2>:uw                        r[a0.0, 16]<8;4,2>:uw                   0x0080:uw                      
  504.         add.sat (4)     r[a0.0,48]<2>:uw                r[a0.0, 48]<8;4,2>:uw           0x0080:uw                      
  505.         add.sat (4)     r[a0.0,80]<2>:uw                r[a0.0, 80]<8;4,2>:uw           0x0080:uw                      
  506.         add.sat (4)     r[a0.0,112]<2>:uw               r[a0.0, 112]<8;4,2>:uw          0x0080:uw                      
  507.  
  508.         add.sat (8)     r[a0.1, 16]<1>:uw                       r[a0.1, 16]<8;8,1>:uw                   0x0080:uw                      
  509.         add.sat (8)     r[a0.1,48]<1>:uw                r[a0.1, 48]<8;8,1>:uw           0x0080:uw                      
  510.         add.sat (8)     r[a0.1,80]<1>:uw                r[a0.1, 80]<8;8,1>:uw           0x0080:uw                      
  511.         add.sat (8)     r[a0.1,112]<1>:uw               r[a0.1, 112]<8;8,1>:uw          0x0080:uw                      
  512.  
  513.         add.sat (4)     r[a0.2, 16]<2>:uw                       r[a0.2,  16]<8;4,2>:uw          0x0080:uw                      
  514.         add.sat (4)     r[a0.2,48]<2>:uw                r[a0.2, 48]<8;4,2>:uw           0x0080:uw                      
  515.         add.sat (4)     r[a0.2,80]<2>:uw                r[a0.2, 80]<8;4,2>:uw           0x0080:uw                      
  516.         add.sat (4)     r[a0.2,112]<2>:uw               r[a0.2, 112]<8;4,2>:uw          0x0080:uw                      
  517.  
  518.     add (4)    a0.0:uw    r22.0<4;4,1>:w    1536:uw
  519.         // left
  520.         add.sat (4)     r[a0.0, 0]<2>:uw                r[a0.0,  0]<8;4,2>:uw           0x0080:uw                      
  521.         add.sat (4)     r[a0.0,32]<2>:uw                r[a0.0, 32]<8;4,2>:uw           0x0080:uw                      
  522.         add.sat (4)     r[a0.0,64]<2>:uw                r[a0.0, 64]<8;4,2>:uw           0x0080:uw                      
  523.         add.sat (4)     r[a0.0,96]<2>:uw                r[a0.0, 96]<8;4,2>:uw           0x0080:uw                      
  524.  
  525.         add.sat (8)     r[a0.1, 0]<1>:uw                r[a0.1,  0]<8;8,1>:uw           0x0080:uw                      
  526.         add.sat (8)     r[a0.1,32]<1>:uw                r[a0.1, 32]<8;8,1>:uw           0x0080:uw                      
  527.         add.sat (8)     r[a0.1,64]<1>:uw                r[a0.1, 64]<8;8,1>:uw           0x0080:uw                      
  528.         add.sat (8)     r[a0.1,96]<1>:uw                r[a0.1, 96]<8;8,1>:uw           0x0080:uw                      
  529.  
  530.         add.sat (4)     r[a0.2, 0]<2>:uw                r[a0.2,  0]<8;4,2>:uw           0x0080:uw                      
  531.         add.sat (4)     r[a0.2,32]<2>:uw                r[a0.2, 32]<8;4,2>:uw           0x0080:uw                      
  532.         add.sat (4)     r[a0.2,64]<2>:uw                r[a0.2, 64]<8;4,2>:uw           0x0080:uw                      
  533.         add.sat (4)     r[a0.2,96]<2>:uw                r[a0.2, 96]<8;4,2>:uw           0x0080:uw                      
  534.  
  535.         // right
  536.         add.sat (4)     r[a0.0,16]<2>:uw                        r[a0.0, 16]<8;4,2>:uw                   0x0080:uw                      
  537.         add.sat (4)     r[a0.0,48]<2>:uw                r[a0.0, 48]<8;4,2>:uw           0x0080:uw                      
  538.         add.sat (4)     r[a0.0,80]<2>:uw                r[a0.0, 80]<8;4,2>:uw           0x0080:uw                      
  539.         add.sat (4)     r[a0.0,112]<2>:uw               r[a0.0, 112]<8;4,2>:uw          0x0080:uw                      
  540.  
  541.         add.sat (8)     r[a0.1, 16]<1>:uw                       r[a0.1, 16]<8;8,1>:uw                   0x0080:uw                      
  542.         add.sat (8)     r[a0.1,48]<1>:uw                r[a0.1, 48]<8;8,1>:uw           0x0080:uw                      
  543.         add.sat (8)     r[a0.1,80]<1>:uw                r[a0.1, 80]<8;8,1>:uw           0x0080:uw                      
  544.         add.sat (8)     r[a0.1,112]<1>:uw               r[a0.1, 112]<8;8,1>:uw          0x0080:uw                      
  545.  
  546.         add.sat (4)     r[a0.2, 16]<2>:uw                       r[a0.2,  16]<8;4,2>:uw          0x0080:uw                      
  547.         add.sat (4)     r[a0.2,48]<2>:uw                r[a0.2, 48]<8;4,2>:uw           0x0080:uw                      
  548.         add.sat (4)     r[a0.2,80]<2>:uw                r[a0.2, 80]<8;4,2>:uw           0x0080:uw                      
  549.         add.sat (4)     r[a0.2,112]<2>:uw               r[a0.2, 112]<8;4,2>:uw          0x0080:uw                      
  550.  
  551.     add (4)    a0.0:uw    r22.0<4;4,1>:w    2048:uw
  552.         // restore pointer
  553.         add   (4)   a0.0:uw   r22.0<4;4,1>:w          0:uw
  554.  
  555.         mov (8) r28<1>:ud               r27<8;8,1>:ud
  556.         mov (8) r37<1>:ud               r27<8;8,1>:ud
  557.         add (1) r37.1<1>:d     r27.1<0;1,0>:d       2:d   // Point to 2nd part
  558.  
  559.  
  560.         mov  (8)    r[a0.6,  0]<4>:ub    r[a0.0,   1]<32;8,4>:ub         { NoDDClr }
  561.     mov  (8)    r[a0.6, 32]<4>:ub    r[a0.0,33]<32;8,4>:ub         { NoDDClr }    
  562.     mov (16)    r[a0.4,  0]<2>:ub    r[a0.1,   1]<32;16,2>:ub        { NoDDClr, NoDDChk }
  563.     mov (16)    r[a0.4, 32]<2>:ub    r[a0.1,33]<32;16,2>:ub        { NoDDClr, NoDDChk }
  564.     mov  (8)    r[a0.5,  0]<4>:ub    r[a0.2,   1]<32;8,4>:ub         { NoDDChk }
  565.     mov  (8)    r[a0.5, 32]<4>:ub    r[a0.2,33]<32;8,4>:ub         { NoDDChk }
  566.  
  567.     mov  (8)    r[a0.6, 288]<4>:ub    r[a0.0,65]<32;8,4>:ub         { NoDDClr }
  568.     mov  (8)    r[a0.6, 320]<4>:ub    r[a0.0,97]<32;8,4>:ub         { NoDDClr }
  569.     mov (16)    r[a0.4,288]<2>:ub    r[a0.1,65]<32;16,2>:ub        { NoDDClr, NoDDChk }
  570.     mov (16)    r[a0.4,320]<2>:ub    r[a0.1,97]<32;16,2>:ub        { NoDDClr, NoDDChk }
  571.     mov  (8)    r[a0.5,288]<4>:ub    r[a0.2,65]<32;8,4>:ub         { NoDDChk }
  572.     mov  (8)    r[a0.5,320]<4>:ub    r[a0.2,97]<32;8,4>:ub         { NoDDChk }
  573.  
  574.     send (1)    null<1>:d    r28        0x5                     0x60A8018:ud
  575.         send (1)    null<1>:d    r37    0x5                     0x60A8018:ud
  576.  
  577.     // restore pointer
  578.         add   (4)   a0.0:uw   r22.0<4;4,1>:w          512:uw
  579.  
  580.         add (1) r28.1<1>:d     r27.1<0;1,0>:d       4:d   // Point to 2nd part
  581.         add (1) r37.1<1>:d     r27.1<0;1,0>:d       6:d   // Point to 2nd part
  582.  
  583.  
  584.         mov  (8)    r[a0.6,  0]<4>:ub    r[a0.0,   1]<32;8,4>:ub         { NoDDClr }
  585.     mov  (8)    r[a0.6, 32]<4>:ub    r[a0.0,33]<32;8,4>:ub         { NoDDClr }    
  586.     mov (16)    r[a0.4,  0]<2>:ub    r[a0.1,   1]<32;16,2>:ub        { NoDDClr, NoDDChk }
  587.     mov (16)    r[a0.4, 32]<2>:ub    r[a0.1,33]<32;16,2>:ub        { NoDDClr, NoDDChk }  
  588.     mov  (8)    r[a0.5,  0]<4>:ub    r[a0.2,   1]<32;8,4>:ub         { NoDDChk }
  589.     mov  (8)    r[a0.5, 32]<4>:ub    r[a0.2,33]<32;8,4>:ub         { NoDDChk }
  590.  
  591.     mov  (8)    r[a0.6, 288]<4>:ub    r[a0.0,65]<32;8,4>:ub         { NoDDClr }
  592.     mov  (8)    r[a0.6, 320]<4>:ub    r[a0.0,97]<32;8,4>:ub         { NoDDClr }
  593.     mov (16)    r[a0.4,288]<2>:ub    r[a0.1,65]<32;16,2>:ub        { NoDDClr, NoDDChk }
  594.     mov (16)    r[a0.4,320]<2>:ub    r[a0.1,97]<32;16,2>:ub        { NoDDClr, NoDDChk }
  595.     mov  (8)    r[a0.5,288]<4>:ub    r[a0.2,65]<32;8,4>:ub         { NoDDChk }
  596.     mov  (8)    r[a0.5,320]<4>:ub    r[a0.2,97]<32;8,4>:ub         { NoDDChk }
  597.  
  598.     send (1)    null<1>:d    r28        0x5                     0x60A8018:ud
  599.         send (1)    null<1>:d    r37    0x5                     0x60A8018:ud
  600.  
  601.     // restore pointer
  602.         add   (4)   a0.0:uw   r22.0<4;4,1>:w          1024:uw
  603.  
  604.         add (1) r28.1<1>:d     r27.1<0;1,0>:d       8:d   // Point to 2nd part
  605.         add (1) r37.1<1>:d     r27.1<0;1,0>:d       10:d   // Point to 2nd part
  606.  
  607.  
  608.         mov  (8)    r[a0.6,  0]<4>:ub    r[a0.0,   1]<32;8,4>:ub         { NoDDClr }
  609.     mov  (8)    r[a0.6, 32]<4>:ub    r[a0.0,33]<32;8,4>:ub         { NoDDClr }    
  610.     mov (16)    r[a0.4,  0]<2>:ub    r[a0.1,   1]<32;16,2>:ub        { NoDDClr, NoDDChk }
  611.     mov (16)    r[a0.4, 32]<2>:ub    r[a0.1,33]<32;16,2>:ub        { NoDDClr, NoDDChk }
  612.     mov  (8)    r[a0.5,  0]<4>:ub    r[a0.2,   1]<32;8,4>:ub         { NoDDChk }
  613.     mov  (8)    r[a0.5, 32]<4>:ub    r[a0.2,33]<32;8,4>:ub         { NoDDChk }
  614.  
  615.     mov  (8)    r[a0.6, 288]<4>:ub    r[a0.0,65]<32;8,4>:ub         { NoDDClr }
  616.     mov  (8)    r[a0.6, 320]<4>:ub    r[a0.0,97]<32;8,4>:ub         { NoDDClr }
  617.     mov (16)    r[a0.4,288]<2>:ub    r[a0.1,65]<32;16,2>:ub        { NoDDClr, NoDDChk }
  618.     mov (16)    r[a0.4,320]<2>:ub    r[a0.1,97]<32;16,2>:ub        { NoDDClr, NoDDChk }
  619.     mov  (8)    r[a0.5,288]<4>:ub    r[a0.2,65]<32;8,4>:ub         { NoDDChk }
  620.     mov  (8)    r[a0.5,320]<4>:ub    r[a0.2,97]<32;8,4>:ub         { NoDDChk }
  621.  
  622.     send (1)    null<1>:d    r28        0x5                     0x60A8018:ud
  623.         send (1)    null<1>:d    r37    0x5                     0x60A8018:ud
  624.  
  625.    // restore pointer
  626.         add   (4)   a0.0:uw   r22.0<4;4,1>:w          1536:uw
  627.  
  628.         add (1) r28.1<1>:d     r27.1<0;1,0>:d       12:d   // Point to 2nd part
  629.         add (1) r37.1<1>:d     r27.1<0;1,0>:d       14:d   // Point to 2nd part
  630.  
  631.         mov  (8)    r[a0.6,  0]<4>:ub    r[a0.0,   1]<32;8,4>:ub         { NoDDClr }
  632.     mov  (8)    r[a0.6, 32]<4>:ub    r[a0.0,33]<32;8,4>:ub         { NoDDClr }    
  633.     mov (16)    r[a0.4,  0]<2>:ub    r[a0.1,   1]<32;16,2>:ub        { NoDDClr, NoDDChk }
  634.     mov (16)    r[a0.4, 32]<2>:ub    r[a0.1,33]<32;16,2>:ub        { NoDDClr, NoDDChk }
  635.     mov  (8)    r[a0.5,  0]<4>:ub    r[a0.2,   1]<32;8,4>:ub         { NoDDChk }
  636.     mov  (8)    r[a0.5, 32]<4>:ub    r[a0.2,33]<32;8,4>:ub         { NoDDChk }
  637.  
  638.     mov  (8)    r[a0.6, 288]<4>:ub    r[a0.0,65]<32;8,4>:ub         { NoDDClr }
  639.     mov  (8)    r[a0.6, 320]<4>:ub    r[a0.0,97]<32;8,4>:ub         { NoDDClr }
  640.     mov (16)    r[a0.4,288]<2>:ub    r[a0.1,65]<32;16,2>:ub        { NoDDClr, NoDDChk }
  641.     mov (16)    r[a0.4,320]<2>:ub    r[a0.1,97]<32;16,2>:ub        { NoDDClr, NoDDChk }
  642.     mov  (8)    r[a0.5,288]<4>:ub    r[a0.2,65]<32;8,4>:ub         { NoDDChk }
  643.     mov  (8)    r[a0.5,320]<4>:ub    r[a0.2,97]<32;8,4>:ub         { NoDDChk }
  644.  
  645.     send (1)    null<1>:d    r28        0x5                     0x60A8018:ud
  646.         send (1)    null<1>:d    r37    0x5                     0x60A8018:ud
  647.  
  648.