annotate libmpeg2/vis.h @ 33023:ba432e34dc7e

Add message showing function. In some cases it is necessary to show messages to the GUI users as well or they will wonder why the GUI didn't show up.
author ib
date Fri, 25 Mar 2011 10:33:48 +0000
parents da2271c341ee
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
12932
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
1 /*
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
2 * vis.h
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
3 * Copyright (C) 2003 David S. Miller <davem@redhat.com>
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
4 *
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
5 * This file is part of mpeg2dec, a free MPEG-2 video stream decoder.
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
6 * See http://libmpeg2.sourceforge.net/ for updates.
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
7 *
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
8 * mpeg2dec is free software; you can redistribute it and/or modify
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
9 * it under the terms of the GNU General Public License as published by
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
10 * the Free Software Foundation; either version 2 of the License, or
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
11 * (at your option) any later version.
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
12 *
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
13 * mpeg2dec is distributed in the hope that it will be useful,
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
16 * GNU General Public License for more details.
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
17 *
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
18 * You should have received a copy of the GNU General Public License
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
19 * along with this program; if not, write to the Free Software
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
20 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
21 */
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
22
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
23 /* You may be asking why I hard-code the instruction opcodes and don't
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
24 * use the normal VIS assembler mnenomics for the VIS instructions.
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
25 *
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
26 * The reason is that Sun, in their infinite wisdom, decided that a binary
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
27 * using a VIS instruction will cause it to be marked (in the ELF headers)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
28 * as doing so, and this prevents the OS from loading such binaries if the
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
29 * current cpu doesn't have VIS. There is no way to easily override this
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
30 * behavior of the assembler that I am aware of.
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
31 *
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
32 * This totally defeats what libmpeg2 is trying to do which is allow a
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
33 * single binary to be created, and then detect the availability of VIS
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
34 * at runtime.
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
35 *
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
36 * I'm not saying that tainting the binary by default is bad, rather I'm
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
37 * saying that not providing a way to override this easily unnecessarily
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
38 * ties people's hands.
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
39 *
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
40 * Thus, we do the opcode encoding by hand and output 32-bit words in
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
41 * the assembler to keep the binary from becoming tainted.
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
42 */
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
43
27572
da2271c341ee Update internal libmpeg2 copy to version 0.5.1.
diego
parents: 12932
diff changeset
44 #ifndef LIBMPEG2_VIS_H
da2271c341ee Update internal libmpeg2 copy to version 0.5.1.
diego
parents: 12932
diff changeset
45 #define LIBMPEG2_VIS_H
da2271c341ee Update internal libmpeg2 copy to version 0.5.1.
diego
parents: 12932
diff changeset
46
12932
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
47 #define vis_opc_base ((0x1 << 31) | (0x36 << 19))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
48 #define vis_opf(X) ((X) << 5)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
49 #define vis_sreg(X) (X)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
50 #define vis_dreg(X) (((X)&0x1f)|((X)>>5))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
51 #define vis_rs1_s(X) (vis_sreg(X) << 14)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
52 #define vis_rs1_d(X) (vis_dreg(X) << 14)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
53 #define vis_rs2_s(X) (vis_sreg(X) << 0)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
54 #define vis_rs2_d(X) (vis_dreg(X) << 0)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
55 #define vis_rd_s(X) (vis_sreg(X) << 25)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
56 #define vis_rd_d(X) (vis_dreg(X) << 25)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
57
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
58 #define vis_ss2s(opf,rs1,rs2,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
59 __asm__ __volatile__ (".word %0" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
60 : : "i" (vis_opc_base | vis_opf(opf) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
61 vis_rs1_s(rs1) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
62 vis_rs2_s(rs2) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
63 vis_rd_s(rd)))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
64
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
65 #define vis_dd2d(opf,rs1,rs2,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
66 __asm__ __volatile__ (".word %0" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
67 : : "i" (vis_opc_base | vis_opf(opf) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
68 vis_rs1_d(rs1) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
69 vis_rs2_d(rs2) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
70 vis_rd_d(rd)))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
71
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
72 #define vis_ss2d(opf,rs1,rs2,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
73 __asm__ __volatile__ (".word %0" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
74 : : "i" (vis_opc_base | vis_opf(opf) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
75 vis_rs1_s(rs1) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
76 vis_rs2_s(rs2) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
77 vis_rd_d(rd)))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
78
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
79 #define vis_sd2d(opf,rs1,rs2,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
80 __asm__ __volatile__ (".word %0" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
81 : : "i" (vis_opc_base | vis_opf(opf) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
82 vis_rs1_s(rs1) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
83 vis_rs2_d(rs2) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
84 vis_rd_d(rd)))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
85
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
86 #define vis_d2s(opf,rs2,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
87 __asm__ __volatile__ (".word %0" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
88 : : "i" (vis_opc_base | vis_opf(opf) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
89 vis_rs2_d(rs2) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
90 vis_rd_s(rd)))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
91
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
92 #define vis_s2d(opf,rs2,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
93 __asm__ __volatile__ (".word %0" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
94 : : "i" (vis_opc_base | vis_opf(opf) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
95 vis_rs2_s(rs2) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
96 vis_rd_d(rd)))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
97
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
98 #define vis_d12d(opf,rs1,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
99 __asm__ __volatile__ (".word %0" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
100 : : "i" (vis_opc_base | vis_opf(opf) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
101 vis_rs1_d(rs1) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
102 vis_rd_d(rd)))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
103
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
104 #define vis_d22d(opf,rs2,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
105 __asm__ __volatile__ (".word %0" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
106 : : "i" (vis_opc_base | vis_opf(opf) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
107 vis_rs2_d(rs2) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
108 vis_rd_d(rd)))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
109
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
110 #define vis_s12s(opf,rs1,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
111 __asm__ __volatile__ (".word %0" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
112 : : "i" (vis_opc_base | vis_opf(opf) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
113 vis_rs1_s(rs1) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
114 vis_rd_s(rd)))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
115
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
116 #define vis_s22s(opf,rs2,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
117 __asm__ __volatile__ (".word %0" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
118 : : "i" (vis_opc_base | vis_opf(opf) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
119 vis_rs2_s(rs2) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
120 vis_rd_s(rd)))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
121
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
122 #define vis_s(opf,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
123 __asm__ __volatile__ (".word %0" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
124 : : "i" (vis_opc_base | vis_opf(opf) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
125 vis_rd_s(rd)))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
126
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
127 #define vis_d(opf,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
128 __asm__ __volatile__ (".word %0" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
129 : : "i" (vis_opc_base | vis_opf(opf) | \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
130 vis_rd_d(rd)))
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
131
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
132 #define vis_r2m(op,rd,mem) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
133 __asm__ __volatile__ (#op "\t%%f" #rd ", [%0]" : : "r" (&(mem)) )
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
134
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
135 #define vis_r2m_2(op,rd,mem1,mem2) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
136 __asm__ __volatile__ (#op "\t%%f" #rd ", [%0 + %1]" : : "r" (mem1), "r" (mem2) )
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
137
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
138 #define vis_m2r(op,mem,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
139 __asm__ __volatile__ (#op "\t[%0], %%f" #rd : : "r" (&(mem)) )
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
140
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
141 #define vis_m2r_2(op,mem1,mem2,rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
142 __asm__ __volatile__ (#op "\t[%0 + %1], %%f" #rd : : "r" (mem1), "r" (mem2) )
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
143
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
144 static inline void vis_set_gsr(unsigned int _val)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
145 {
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
146 register unsigned int val asm("g1");
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
147
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
148 val = _val;
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
149 __asm__ __volatile__(".word 0xa7804000"
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
150 : : "r" (val));
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
151 }
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
152
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
153 #define VIS_GSR_ALIGNADDR_MASK 0x0000007
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
154 #define VIS_GSR_ALIGNADDR_SHIFT 0
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
155 #define VIS_GSR_SCALEFACT_MASK 0x0000078
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
156 #define VIS_GSR_SCALEFACT_SHIFT 3
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
157
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
158 #define vis_ld32(mem,rs1) vis_m2r(ld, mem, rs1)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
159 #define vis_ld32_2(mem1,mem2,rs1) vis_m2r_2(ld, mem1, mem2, rs1)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
160 #define vis_st32(rs1,mem) vis_r2m(st, rs1, mem)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
161 #define vis_st32_2(rs1,mem1,mem2) vis_r2m_2(st, rs1, mem1, mem2)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
162 #define vis_ld64(mem,rs1) vis_m2r(ldd, mem, rs1)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
163 #define vis_ld64_2(mem1,mem2,rs1) vis_m2r_2(ldd, mem1, mem2, rs1)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
164 #define vis_st64(rs1,mem) vis_r2m(std, rs1, mem)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
165 #define vis_st64_2(rs1,mem1,mem2) vis_r2m_2(std, rs1, mem1, mem2)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
166
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
167 #define vis_ldblk(mem, rd) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
168 do { register void *__mem asm("g1"); \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
169 __mem = &(mem); \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
170 __asm__ __volatile__(".word 0xc1985e00 | %1" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
171 : \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
172 : "r" (__mem), \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
173 "i" (vis_rd_d(rd)) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
174 : "memory"); \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
175 } while (0)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
176
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
177 #define vis_stblk(rd, mem) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
178 do { register void *__mem asm("g1"); \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
179 __mem = &(mem); \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
180 __asm__ __volatile__(".word 0xc1b85e00 | %1" \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
181 : \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
182 : "r" (__mem), \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
183 "i" (vis_rd_d(rd)) \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
184 : "memory"); \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
185 } while (0)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
186
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
187 #define vis_membar_storestore() \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
188 __asm__ __volatile__(".word 0x8143e008" : : : "memory")
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
189
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
190 #define vis_membar_sync() \
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
191 __asm__ __volatile__(".word 0x8143e040" : : : "memory")
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
192
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
193 /* 16 and 32 bit partitioned addition and subtraction. The normal
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
194 * versions perform 4 16-bit or 2 32-bit additions or subtractions.
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
195 * The 's' versions perform 2 16-bit or 2 32-bit additions or
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
196 * subtractions.
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
197 */
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
198
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
199 #define vis_padd16(rs1,rs2,rd) vis_dd2d(0x50, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
200 #define vis_padd16s(rs1,rs2,rd) vis_ss2s(0x51, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
201 #define vis_padd32(rs1,rs2,rd) vis_dd2d(0x52, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
202 #define vis_padd32s(rs1,rs2,rd) vis_ss2s(0x53, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
203 #define vis_psub16(rs1,rs2,rd) vis_dd2d(0x54, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
204 #define vis_psub16s(rs1,rs2,rd) vis_ss2s(0x55, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
205 #define vis_psub32(rs1,rs2,rd) vis_dd2d(0x56, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
206 #define vis_psub32s(rs1,rs2,rd) vis_ss2s(0x57, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
207
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
208 /* Pixel formatting instructions. */
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
209
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
210 #define vis_pack16(rs2,rd) vis_d2s( 0x3b, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
211 #define vis_pack32(rs1,rs2,rd) vis_dd2d(0x3a, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
212 #define vis_packfix(rs2,rd) vis_d2s( 0x3d, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
213 #define vis_expand(rs2,rd) vis_s2d( 0x4d, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
214 #define vis_pmerge(rs1,rs2,rd) vis_ss2d(0x4b, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
215
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
216 /* Partitioned multiply instructions. */
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
217
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
218 #define vis_mul8x16(rs1,rs2,rd) vis_sd2d(0x31, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
219 #define vis_mul8x16au(rs1,rs2,rd) vis_ss2d(0x33, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
220 #define vis_mul8x16al(rs1,rs2,rd) vis_ss2d(0x35, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
221 #define vis_mul8sux16(rs1,rs2,rd) vis_dd2d(0x36, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
222 #define vis_mul8ulx16(rs1,rs2,rd) vis_dd2d(0x37, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
223 #define vis_muld8sux16(rs1,rs2,rd) vis_ss2d(0x38, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
224 #define vis_muld8ulx16(rs1,rs2,rd) vis_ss2d(0x39, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
225
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
226 /* Alignment instructions. */
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
227
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
228 static inline void *vis_alignaddr(void *_ptr)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
229 {
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
230 register void *ptr asm("g1");
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
231
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
232 ptr = _ptr;
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
233
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
234 __asm__ __volatile__(".word %2"
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
235 : "=&r" (ptr)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
236 : "0" (ptr),
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
237 "i" (vis_opc_base | vis_opf(0x18) |
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
238 vis_rs1_s(1) |
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
239 vis_rs2_s(0) |
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
240 vis_rd_s(1)));
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
241
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
242 return ptr;
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
243 }
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
244
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
245 static inline void vis_alignaddr_g0(void *_ptr)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
246 {
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
247 register void *ptr asm("g1");
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
248
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
249 ptr = _ptr;
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
250
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
251 __asm__ __volatile__(".word %2"
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
252 : "=&r" (ptr)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
253 : "0" (ptr),
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
254 "i" (vis_opc_base | vis_opf(0x18) |
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
255 vis_rs1_s(1) |
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
256 vis_rs2_s(0) |
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
257 vis_rd_s(0)));
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
258 }
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
259
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
260 static inline void *vis_alignaddrl(void *_ptr)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
261 {
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
262 register void *ptr asm("g1");
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
263
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
264 ptr = _ptr;
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
265
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
266 __asm__ __volatile__(".word %2"
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
267 : "=&r" (ptr)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
268 : "0" (ptr),
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
269 "i" (vis_opc_base | vis_opf(0x19) |
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
270 vis_rs1_s(1) |
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
271 vis_rs2_s(0) |
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
272 vis_rd_s(1)));
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
273
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
274 return ptr;
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
275 }
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
276
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
277 static inline void vis_alignaddrl_g0(void *_ptr)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
278 {
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
279 register void *ptr asm("g1");
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
280
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
281 ptr = _ptr;
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
282
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
283 __asm__ __volatile__(".word %2"
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
284 : "=&r" (ptr)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
285 : "0" (ptr),
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
286 "i" (vis_opc_base | vis_opf(0x19) |
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
287 vis_rs1_s(1) |
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
288 vis_rs2_s(0) |
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
289 vis_rd_s(0)));
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
290 }
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
291
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
292 #define vis_faligndata(rs1,rs2,rd) vis_dd2d(0x48, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
293
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
294 /* Logical operate instructions. */
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
295
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
296 #define vis_fzero(rd) vis_d( 0x60, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
297 #define vis_fzeros(rd) vis_s( 0x61, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
298 #define vis_fone(rd) vis_d( 0x7e, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
299 #define vis_fones(rd) vis_s( 0x7f, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
300 #define vis_src1(rs1,rd) vis_d12d(0x74, rs1, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
301 #define vis_src1s(rs1,rd) vis_s12s(0x75, rs1, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
302 #define vis_src2(rs2,rd) vis_d22d(0x78, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
303 #define vis_src2s(rs2,rd) vis_s22s(0x79, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
304 #define vis_not1(rs1,rd) vis_d12d(0x6a, rs1, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
305 #define vis_not1s(rs1,rd) vis_s12s(0x6b, rs1, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
306 #define vis_not2(rs2,rd) vis_d22d(0x66, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
307 #define vis_not2s(rs2,rd) vis_s22s(0x67, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
308 #define vis_or(rs1,rs2,rd) vis_dd2d(0x7c, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
309 #define vis_ors(rs1,rs2,rd) vis_ss2s(0x7d, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
310 #define vis_nor(rs1,rs2,rd) vis_dd2d(0x62, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
311 #define vis_nors(rs1,rs2,rd) vis_ss2s(0x63, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
312 #define vis_and(rs1,rs2,rd) vis_dd2d(0x70, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
313 #define vis_ands(rs1,rs2,rd) vis_ss2s(0x71, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
314 #define vis_nand(rs1,rs2,rd) vis_dd2d(0x6e, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
315 #define vis_nands(rs1,rs2,rd) vis_ss2s(0x6f, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
316 #define vis_xor(rs1,rs2,rd) vis_dd2d(0x6c, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
317 #define vis_xors(rs1,rs2,rd) vis_ss2s(0x6d, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
318 #define vis_xnor(rs1,rs2,rd) vis_dd2d(0x72, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
319 #define vis_xnors(rs1,rs2,rd) vis_ss2s(0x73, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
320 #define vis_ornot1(rs1,rs2,rd) vis_dd2d(0x7a, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
321 #define vis_ornot1s(rs1,rs2,rd) vis_ss2s(0x7b, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
322 #define vis_ornot2(rs1,rs2,rd) vis_dd2d(0x76, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
323 #define vis_ornot2s(rs1,rs2,rd) vis_ss2s(0x77, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
324 #define vis_andnot1(rs1,rs2,rd) vis_dd2d(0x68, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
325 #define vis_andnot1s(rs1,rs2,rd) vis_ss2s(0x69, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
326 #define vis_andnot2(rs1,rs2,rd) vis_dd2d(0x64, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
327 #define vis_andnot2s(rs1,rs2,rd) vis_ss2s(0x65, rs1, rs2, rd)
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
328
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
329 /* Pixel component distance. */
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
330
d0a8810e155c Importing libmpeg2 from mpeg2dec-0.4.0b
henry
parents:
diff changeset
331 #define vis_pdist(rs1,rs2,rd) vis_dd2d(0x3e, rs1, rs2, rd)
27572
da2271c341ee Update internal libmpeg2 copy to version 0.5.1.
diego
parents: 12932
diff changeset
332
da2271c341ee Update internal libmpeg2 copy to version 0.5.1.
diego
parents: 12932
diff changeset
333 #endif /* LIBMPEG2_VIS_H */