1/* 2 * Copyright © 2008 Intel Corporation 3 * 4 * Permission is hereby granted, free of charge, to any person obtaining a 5 * copy of this software and associated documentation files (the "Software"), 6 * to deal in the Software without restriction, including without limitation 7 * the rights to use, copy, modify, merge, publish, distribute, sublicense, 8 * and/or sell copies of the Software, and to permit persons to whom the 9 * Software is furnished to do so, subject to the following conditions: 10 * 11 * The above copyright notice and this permission notice (including the next 12 * paragraph) shall be included in all copies or substantial portions of the 13 * Software. 14 * 15 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 18 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 * SOFTWARE. 22 * 23 * Author: 24 * Zou Nan hai <nanhai.zou@intel.com> 25 * Zhang Hua jun <huajun.zhang@intel.com> 26 * Xing Dong sheng <dongsheng.xing@intel.com> 27 * 28 */ 29mov (1) g115.8<1>UD 0x01FUD {align1}; 30send (16) 0 g78.0<1>UW g115<8,8,1>UW read(surface,2,0,2) mlen 1 rlen 1 {align1}; 31add (1) g115.4<1>UD g115.4<1,1,1>UD 2UD {align1}; 32send (16) 0 g80.0<1>UW g115<8,8,1>UW read(surface,2,0,2) mlen 1 rlen 1 {align1}; 33add (1) g115.4<1>UD g115.4<1,1,1>UD 2UD {align1}; 34send (16) 0 g82.0<1>UW g115<8,8,1>UW read(surface,2,0,2) mlen 1 rlen 1 {align1}; 35add (1) g115.4<1>UD g115.4<1,1,1>UD 2UD {align1}; 36send (16) 0 g84.0<1>UW g115<8,8,1>UW read(surface,2,0,2) mlen 1 rlen 1 {align1}; 37add (1) g115.4<1>UD g115.4<1,1,1>UD 2UD {align1}; 38mov (1) g115.8<1>UD 0x07001FUD {align1}; 39send (16) 0 g86.0<1>UW g115<8,8,1>UW read(surface,2,0,2) mlen 1 rlen 8 {align1}; 40add (1) g115.4<1>UD g115.4<1,1,1>UD 8UD {align1}; 41mov (1) g115.8<1>UD 0x1FUD {align1}; 42send (16) 0 g94.0<1>UW g115<8,8,1>UW read(surface,2,0,2) mlen 1 rlen 1 {align1}; 43and (1) g2.24<1>UD g115.0<1,1,1>UD 3UD {align1}; 44mul (1) g2.24<1>UD g2.24<1,1,1>UD 25UD {align1}; 45jmpi g2.24<1,1,1>D; 46 47add (16) g96.0<1>UW g78.0<16,16,1>UB g80.0<16,16,1>UB {align1}; 48add (16) g97.0<1>UW g80.0<16,16,1>UB g82.0<16,16,1>UB {align1}; 49add (16) g98.0<1>UW g82.0<16,16,1>UB g84.0<16,16,1>UB {align1}; 50add (16) g99.0<1>UW g84.0<16,16,1>UB g86.0<16,16,1>UB {align1}; 51add (16) g100.0<1>UW g86.0<16,16,1>UB g88.0<16,16,1>UB {align1}; 52add (16) g101.0<1>UW g88.0<16,16,1>UB g90.0<16,16,1>UB {align1}; 53add (16) g102.0<1>UW g90.0<16,16,1>UB g92.0<16,16,1>UB {align1}; 54add (16) g103.0<1>UW g92.0<16,16,1>UB g94.0<16,16,1>UB {align1}; 55 56add (16) g96.0<1>UW g96.0<16,16,1>UW g78.1<16,16,1>UB {align1}; 57add (16) g97.0<1>UW g97.0<16,16,1>UW g80.1<16,16,1>UB {align1}; 58add (16) g98.0<1>UW g98.0<16,16,1>UW g82.1<16,16,1>UB {align1}; 59add (16) g99.0<1>UW g99.0<16,16,1>UW g84.1<16,16,1>UB {align1}; 60add (16) g100.0<1>UW g100.0<16,16,1>UW g86.1<16,16,1>UB {align1}; 61add (16) g101.0<1>UW g101.0<16,16,1>UW g88.1<16,16,1>UB {align1}; 62add (16) g102.0<1>UW g102.0<16,16,1>UW g90.1<16,16,1>UB {align1}; 63add (16) g103.0<1>UW g103.0<16,16,1>UW g92.1<16,16,1>UB {align1}; 64 65add (16) g96.0<1>UW g96.0<16,16,1>UW g80.1<16,16,1>UB {align1}; 66add (16) g97.0<1>UW g97.0<16,16,1>UW g82.1<16,16,1>UB {align1}; 67add (16) g98.0<1>UW g98.0<16,16,1>UW g84.1<16,16,1>UB {align1}; 68add (16) g99.0<1>UW g99.0<16,16,1>UW g86.1<16,16,1>UB {align1}; 69add (16) g100.0<1>UW g100.0<16,16,1>UW g88.1<16,16,1>UB {align1}; 70add (16) g101.0<1>UW g101.0<16,16,1>UW g90.1<16,16,1>UB {align1}; 71add (16) g102.0<1>UW g102.0<16,16,1>UW g92.1<16,16,1>UB {align1}; 72add (16) g103.0<1>UW g103.0<16,16,1>UW g94.1<16,16,1>UB {align1}; 73jmpi out; 74 75add (16) g96.0<1>UW g78.1<16,16,1>UB g80.1<16,16,1>UB {align1}; 76add (16) g97.0<1>UW g80.1<16,16,1>UB g82.1<16,16,1>UB {align1}; 77add (16) g98.0<1>UW g82.1<16,16,1>UB g84.1<16,16,1>UB {align1}; 78add (16) g99.0<1>UW g84.1<16,16,1>UB g86.1<16,16,1>UB {align1}; 79add (16) g100.0<1>UW g86.1<16,16,1>UB g88.1<16,16,1>UB {align1}; 80add (16) g101.0<1>UW g88.1<16,16,1>UB g90.1<16,16,1>UB {align1}; 81add (16) g102.0<1>UW g90.1<16,16,1>UB g92.1<16,16,1>UB {align1}; 82add (16) g103.0<1>UW g92.1<16,16,1>UB g94.1<16,16,1>UB {align1}; 83 84add (16) g96.0<1>UW g96.0<16,16,1>UW g78.2<16,16,1>UB {align1}; 85add (16) g97.0<1>UW g97.0<16,16,1>UW g80.2<16,16,1>UB {align1}; 86add (16) g98.0<1>UW g98.0<16,16,1>UW g82.2<16,16,1>UB {align1}; 87add (16) g99.0<1>UW g99.0<16,16,1>UW g84.2<16,16,1>UB {align1}; 88add (16) g100.0<1>UW g100.0<16,16,1>UW g86.2<16,16,1>UB {align1}; 89add (16) g101.0<1>UW g101.0<16,16,1>UW g88.2<16,16,1>UB {align1}; 90add (16) g102.0<1>UW g102.0<16,16,1>UW g90.2<16,16,1>UB {align1}; 91add (16) g103.0<1>UW g103.0<16,16,1>UW g92.2<16,16,1>UB {align1}; 92 93add (16) g96.0<1>UW g96.0<16,16,1>UW g80.2<16,16,1>UB {align1}; 94add (16) g97.0<1>UW g97.0<16,16,1>UW g82.2<16,16,1>UB {align1}; 95add (16) g98.0<1>UW g98.0<16,16,1>UW g84.2<16,16,1>UB {align1}; 96add (16) g99.0<1>UW g99.0<16,16,1>UW g86.2<16,16,1>UB {align1}; 97add (16) g100.0<1>UW g100.0<16,16,1>UW g88.2<16,16,1>UB {align1}; 98add (16) g101.0<1>UW g101.0<16,16,1>UW g90.2<16,16,1>UB {align1}; 99add (16) g102.0<1>UW g102.0<16,16,1>UW g92.2<16,16,1>UB {align1}; 100add (16) g103.0<1>UW g103.0<16,16,1>UW g94.2<16,16,1>UB {align1}; 101jmpi out; 102 103add (16) g96.0<1>UW g78.2<16,16,1>UB g80.2<16,16,1>UB {align1}; 104add (16) g97.0<1>UW g80.2<16,16,1>UB g82.2<16,16,1>UB {align1}; 105add (16) g98.0<1>UW g82.2<16,16,1>UB g84.2<16,16,1>UB {align1}; 106add (16) g99.0<1>UW g84.2<16,16,1>UB g86.2<16,16,1>UB {align1}; 107add (16) g100.0<1>UW g86.2<16,16,1>UB g88.2<16,16,1>UB {align1}; 108add (16) g101.0<1>UW g88.2<16,16,1>UB g90.2<16,16,1>UB {align1}; 109add (16) g102.0<1>UW g90.2<16,16,1>UB g92.2<16,16,1>UB {align1}; 110add (16) g103.0<1>UW g92.2<16,16,1>UB g94.2<16,16,1>UB {align1}; 111 112add (16) g96.0<1>UW g96.0<16,16,1>UW g78.3<16,16,1>UB {align1}; 113add (16) g97.0<1>UW g97.0<16,16,1>UW g80.3<16,16,1>UB {align1}; 114add (16) g98.0<1>UW g98.0<16,16,1>UW g82.3<16,16,1>UB {align1}; 115add (16) g99.0<1>UW g99.0<16,16,1>UW g84.3<16,16,1>UB {align1}; 116add (16) g100.0<1>UW g100.0<16,16,1>UW g86.3<16,16,1>UB {align1}; 117add (16) g101.0<1>UW g101.0<16,16,1>UW g88.3<16,16,1>UB {align1}; 118add (16) g102.0<1>UW g102.0<16,16,1>UW g90.3<16,16,1>UB {align1}; 119add (16) g103.0<1>UW g103.0<16,16,1>UW g92.3<16,16,1>UB {align1}; 120 121add (16) g96.0<1>UW g96.0<16,16,1>UW g80.3<16,16,1>UB {align1}; 122add (16) g97.0<1>UW g97.0<16,16,1>UW g82.3<16,16,1>UB {align1}; 123add (16) g98.0<1>UW g98.0<16,16,1>UW g84.3<16,16,1>UB {align1}; 124add (16) g99.0<1>UW g99.0<16,16,1>UW g86.3<16,16,1>UB {align1}; 125add (16) g100.0<1>UW g100.0<16,16,1>UW g88.3<16,16,1>UB {align1}; 126add (16) g101.0<1>UW g101.0<16,16,1>UW g90.3<16,16,1>UB {align1}; 127add (16) g102.0<1>UW g102.0<16,16,1>UW g92.3<16,16,1>UB {align1}; 128add (16) g103.0<1>UW g103.0<16,16,1>UW g94.3<16,16,1>UB {align1}; 129jmpi out; 130 131add (16) g96.0<1>UW g78.3<16,16,1>UB g80.3<16,16,1>UB {align1}; 132add (16) g97.0<1>UW g80.3<16,16,1>UB g82.3<16,16,1>UB {align1}; 133add (16) g98.0<1>UW g82.3<16,16,1>UB g84.3<16,16,1>UB {align1}; 134add (16) g99.0<1>UW g84.3<16,16,1>UB g86.3<16,16,1>UB {align1}; 135add (16) g100.0<1>UW g86.3<16,16,1>UB g88.3<16,16,1>UB {align1}; 136add (16) g101.0<1>UW g88.3<16,16,1>UB g90.3<16,16,1>UB {align1}; 137add (16) g102.0<1>UW g90.3<16,16,1>UB g92.3<16,16,1>UB {align1}; 138add (16) g103.0<1>UW g92.3<16,16,1>UB g94.3<16,16,1>UB {align1}; 139 140add (16) g96.0<1>UW g96.0<16,16,1>UW g78.4<16,16,1>UB {align1}; 141add (16) g97.0<1>UW g97.0<16,16,1>UW g80.4<16,16,1>UB {align1}; 142add (16) g98.0<1>UW g98.0<16,16,1>UW g82.4<16,16,1>UB {align1}; 143add (16) g99.0<1>UW g99.0<16,16,1>UW g84.4<16,16,1>UB {align1}; 144add (16) g100.0<1>UW g100.0<16,16,1>UW g86.4<16,16,1>UB {align1}; 145add (16) g101.0<1>UW g101.0<16,16,1>UW g88.4<16,16,1>UB {align1}; 146add (16) g102.0<1>UW g102.0<16,16,1>UW g90.4<16,16,1>UB {align1}; 147add (16) g103.0<1>UW g103.0<16,16,1>UW g92.4<16,16,1>UB {align1}; 148 149add (16) g96.0<1>UW g96.0<16,16,1>UW g80.4<16,16,1>UB {align1}; 150add (16) g97.0<1>UW g97.0<16,16,1>UW g82.4<16,16,1>UB {align1}; 151add (16) g98.0<1>UW g98.0<16,16,1>UW g84.4<16,16,1>UB {align1}; 152add (16) g99.0<1>UW g99.0<16,16,1>UW g86.4<16,16,1>UB {align1}; 153add (16) g100.0<1>UW g100.0<16,16,1>UW g88.4<16,16,1>UB {align1}; 154add (16) g101.0<1>UW g101.0<16,16,1>UW g90.4<16,16,1>UB {align1}; 155add (16) g102.0<1>UW g102.0<16,16,1>UW g92.4<16,16,1>UB {align1}; 156add (16) g103.0<1>UW g103.0<16,16,1>UW g94.4<16,16,1>UB {align1}; 157 158out: 159shr (16) g96.0<1>UW g96.0<16,16,1>UW 2UW {align1}; 160shr (16) g97.0<1>UW g97.0<16,16,1>UW 2UW {align1}; 161shr (16) g98.0<1>UW g98.0<16,16,1>UW 2UW {align1}; 162shr (16) g99.0<1>UW g99.0<16,16,1>UW 2UW {align1}; 163shr (16) g100.0<1>UW g100.0<16,16,1>UW 2UW {align1}; 164shr (16) g101.0<1>UW g101.0<16,16,1>UW 2UW {align1}; 165shr (16) g102.0<1>UW g102.0<16,16,1>UW 2UW {align1}; 166shr (16) g103.0<1>UW g103.0<16,16,1>UW 2UW {align1}; 167