Mercurial > hg > CbC > CbC_gcc
annotate gcc/config/ia64/vect.md @ 67:f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
author | nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Tue, 22 Mar 2011 17:18:12 +0900 |
parents | 77e2b8dfacca |
children | 04ced10e8804 |
rev | line source |
---|---|
0 | 1 ;; IA-64 machine description for vector operations. |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
2 ;; Copyright (C) 2004, 2005, 2007, 2010 Free Software Foundation, Inc. |
0 | 3 ;; |
4 ;; This file is part of GCC. | |
5 ;; | |
6 ;; GCC is free software; you can redistribute it and/or modify | |
7 ;; it under the terms of the GNU General Public License as published by | |
8 ;; the Free Software Foundation; either version 3, or (at your option) | |
9 ;; any later version. | |
10 ;; | |
11 ;; GCC is distributed in the hope that it will be useful, | |
12 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of | |
13 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
14 ;; GNU General Public License for more details. | |
15 ;; | |
16 ;; You should have received a copy of the GNU General Public License | |
17 ;; along with GCC; see the file COPYING3. If not see | |
18 ;; <http://www.gnu.org/licenses/>. | |
19 | |
20 | |
21 ;; Integer vector operations | |
22 | |
23 (define_mode_iterator VECINT [V8QI V4HI V2SI]) | |
24 (define_mode_iterator VECINT12 [V8QI V4HI]) | |
25 (define_mode_iterator VECINT24 [V4HI V2SI]) | |
26 (define_mode_attr vecsize [(V8QI "1") (V4HI "2") (V2SI "4")]) | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
27 (define_mode_attr vecwider [(V8QI "V4HI") (V4HI "V2SI")]) |
0 | 28 |
29 (define_expand "mov<mode>" | |
30 [(set (match_operand:VECINT 0 "general_operand" "") | |
31 (match_operand:VECINT 1 "general_operand" ""))] | |
32 "" | |
33 { | |
34 rtx op1 = ia64_expand_move (operands[0], operands[1]); | |
35 if (!op1) | |
36 DONE; | |
37 operands[1] = op1; | |
38 }) | |
39 | |
40 (define_insn "*mov<mode>_internal" | |
41 [(set (match_operand:VECINT 0 "destination_operand" | |
42 "=r,r,r,r,m ,*f ,*f,Q ,r ,*f") | |
43 (match_operand:VECINT 1 "move_operand" | |
44 "rU,W,i,m,rU,U*f,Q ,*f,*f,r "))] | |
45 "ia64_move_ok (operands[0], operands[1])" | |
46 "@ | |
47 mov %0 = %r1 | |
48 addl %0 = %v1, r0 | |
49 movl %0 = %v1 | |
50 ld8%O1 %0 = %1%P1 | |
51 st8%Q0 %0 = %r1%P0 | |
52 mov %0 = %F1 | |
53 ldf8 %0 = %1%P1 | |
54 stf8 %0 = %1%P0 | |
55 getf.sig %0 = %1 | |
56 setf.sig %0 = %1" | |
57 [(set_attr "itanium_class" "ialu,ialu,long_i,ld,st,fmisc,fld,stf,frfr,tofr")]) | |
58 | |
59 (define_insn "one_cmpl<mode>2" | |
60 [(set (match_operand:VECINT 0 "gr_register_operand" "=r") | |
61 (not:VECINT (match_operand:VECINT 1 "gr_register_operand" "r")))] | |
62 "" | |
63 "andcm %0 = -1, %1" | |
64 [(set_attr "itanium_class" "ilog")]) | |
65 | |
66 (define_insn "and<mode>3" | |
67 [(set (match_operand:VECINT 0 "grfr_register_operand" "=r,*f") | |
68 (and:VECINT | |
69 (match_operand:VECINT 1 "grfr_register_operand" "r,*f") | |
70 (match_operand:VECINT 2 "grfr_reg_or_8bit_operand" "r,*f")))] | |
71 "" | |
72 "@ | |
73 and %0 = %2, %1 | |
74 fand %0 = %2, %1" | |
75 [(set_attr "itanium_class" "ilog,fmisc")]) | |
76 | |
77 (define_insn "*andnot<mode>" | |
78 [(set (match_operand:VECINT 0 "grfr_register_operand" "=r,*f") | |
79 (and:VECINT | |
80 (not:VECINT (match_operand:VECINT 1 "grfr_register_operand" "r,*f")) | |
81 (match_operand:VECINT 2 "grfr_reg_or_8bit_operand" "r,*f")))] | |
82 "" | |
83 "@ | |
84 andcm %0 = %2, %1 | |
85 fandcm %0 = %2, %1" | |
86 [(set_attr "itanium_class" "ilog,fmisc")]) | |
87 | |
88 (define_insn "ior<mode>3" | |
89 [(set (match_operand:VECINT 0 "grfr_register_operand" "=r,*f") | |
90 (ior:VECINT | |
91 (match_operand:VECINT 1 "grfr_register_operand" "r,*f") | |
92 (match_operand:VECINT 2 "grfr_reg_or_8bit_operand" "r,*f")))] | |
93 "" | |
94 "@ | |
95 or %0 = %2, %1 | |
96 for %0 = %2, %1" | |
97 [(set_attr "itanium_class" "ilog,fmisc")]) | |
98 | |
99 (define_insn "xor<mode>3" | |
100 [(set (match_operand:VECINT 0 "grfr_register_operand" "=r,*f") | |
101 (xor:VECINT | |
102 (match_operand:VECINT 1 "grfr_register_operand" "r,*f") | |
103 (match_operand:VECINT 2 "grfr_reg_or_8bit_operand" "r,*f")))] | |
104 "" | |
105 "@ | |
106 xor %0 = %2, %1 | |
107 fxor %0 = %2, %1" | |
108 [(set_attr "itanium_class" "ilog,fmisc")]) | |
109 | |
110 (define_insn "neg<mode>2" | |
111 [(set (match_operand:VECINT 0 "gr_register_operand" "=r") | |
112 (neg:VECINT (match_operand:VECINT 1 "gr_register_operand" "r")))] | |
113 "" | |
114 "psub<vecsize> %0 = r0, %1" | |
115 [(set_attr "itanium_class" "mmalua")]) | |
116 | |
117 (define_insn "add<mode>3" | |
118 [(set (match_operand:VECINT 0 "gr_register_operand" "=r") | |
119 (plus:VECINT (match_operand:VECINT 1 "gr_register_operand" "r") | |
120 (match_operand:VECINT 2 "gr_register_operand" "r")))] | |
121 "" | |
122 "padd<vecsize> %0 = %1, %2" | |
123 [(set_attr "itanium_class" "mmalua")]) | |
124 | |
125 (define_insn "*ssadd<mode>3" | |
126 [(set (match_operand:VECINT12 0 "gr_register_operand" "=r") | |
127 (ss_plus:VECINT12 | |
128 (match_operand:VECINT12 1 "gr_register_operand" "r") | |
129 (match_operand:VECINT12 2 "gr_register_operand" "r")))] | |
130 "" | |
131 "padd<vecsize>.sss %0 = %1, %2" | |
132 [(set_attr "itanium_class" "mmalua")]) | |
133 | |
134 (define_insn "*usadd<mode>3" | |
135 [(set (match_operand:VECINT12 0 "gr_register_operand" "=r") | |
136 (us_plus:VECINT12 | |
137 (match_operand:VECINT12 1 "gr_register_operand" "r") | |
138 (match_operand:VECINT12 2 "gr_register_operand" "r")))] | |
139 "" | |
140 "padd<vecsize>.uuu %0 = %1, %2" | |
141 [(set_attr "itanium_class" "mmalua")]) | |
142 | |
143 (define_insn "sub<mode>3" | |
144 [(set (match_operand:VECINT 0 "gr_register_operand" "=r") | |
145 (minus:VECINT (match_operand:VECINT 1 "gr_register_operand" "r") | |
146 (match_operand:VECINT 2 "gr_register_operand" "r")))] | |
147 "" | |
148 "psub<vecsize> %0 = %1, %2" | |
149 [(set_attr "itanium_class" "mmalua")]) | |
150 | |
151 (define_insn "*sssub<mode>3" | |
152 [(set (match_operand:VECINT12 0 "gr_register_operand" "=r") | |
153 (ss_minus:VECINT12 | |
154 (match_operand:VECINT12 1 "gr_register_operand" "r") | |
155 (match_operand:VECINT12 2 "gr_register_operand" "r")))] | |
156 "" | |
157 "psub<vecsize>.sss %0 = %1, %2" | |
158 [(set_attr "itanium_class" "mmalua")]) | |
159 | |
160 (define_insn "*ussub<mode>3" | |
161 [(set (match_operand:VECINT12 0 "gr_register_operand" "=r") | |
162 (us_minus:VECINT12 | |
163 (match_operand:VECINT12 1 "gr_register_operand" "r") | |
164 (match_operand:VECINT12 2 "gr_register_operand" "r")))] | |
165 "" | |
166 "psub<vecsize>.uuu %0 = %1, %2" | |
167 [(set_attr "itanium_class" "mmalua")]) | |
168 | |
169 (define_expand "mulv8qi3" | |
170 [(set (match_operand:V8QI 0 "gr_register_operand" "") | |
171 (mult:V8QI (match_operand:V8QI 1 "gr_register_operand" "r") | |
172 (match_operand:V8QI 2 "gr_register_operand" "r")))] | |
173 "" | |
174 { | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
175 rtx l = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
176 rtx h = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
177 emit_insn (gen_vec_widen_umult_lo_v8qi (l, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
178 emit_insn (gen_vec_widen_umult_hi_v8qi (h, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
179 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
180 emit_insn (gen_vec_pack_trunc_v4hi (operands[0], h, l)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
181 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
182 emit_insn (gen_vec_pack_trunc_v4hi (operands[0], l, h)); |
0 | 183 DONE; |
184 }) | |
185 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
186 (define_expand "vec_widen_umult_lo_v8qi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
187 [(match_operand:V4HI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
188 (match_operand:V8QI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
189 (match_operand:V8QI 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
190 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
191 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
192 rtx op1 = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
193 rtx op2 = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
194 emit_insn (gen_vec_unpacku_lo_v8qi (op1, operands[1])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
195 emit_insn (gen_vec_unpacku_lo_v8qi (op2, operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
196 emit_insn (gen_mulv4hi3 (operands[0], op1, op2)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
197 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
198 }); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
199 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
200 (define_expand "vec_widen_umult_hi_v8qi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
201 [(match_operand:V4HI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
202 (match_operand:V8QI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
203 (match_operand:V8QI 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
204 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
205 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
206 rtx op1 = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
207 rtx op2 = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
208 emit_insn (gen_vec_unpacku_hi_v8qi (op1, operands[1])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
209 emit_insn (gen_vec_unpacku_hi_v8qi (op2, operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
210 emit_insn (gen_mulv4hi3 (operands[0], op1, op2)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
211 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
212 }); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
213 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
214 (define_expand "vec_widen_smult_lo_v8qi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
215 [(match_operand:V4HI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
216 (match_operand:V8QI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
217 (match_operand:V8QI 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
218 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
219 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
220 rtx op1 = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
221 rtx op2 = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
222 emit_insn (gen_vec_unpacks_lo_v8qi (op1, operands[1])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
223 emit_insn (gen_vec_unpacks_lo_v8qi (op2, operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
224 emit_insn (gen_mulv4hi3 (operands[0], op1, op2)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
225 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
226 }); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
227 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
228 (define_expand "vec_widen_smult_hi_v8qi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
229 [(match_operand:V4HI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
230 (match_operand:V8QI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
231 (match_operand:V8QI 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
232 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
233 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
234 rtx op1 = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
235 rtx op2 = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
236 emit_insn (gen_vec_unpacks_hi_v8qi (op1, operands[1])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
237 emit_insn (gen_vec_unpacks_hi_v8qi (op2, operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
238 emit_insn (gen_mulv4hi3 (operands[0], op1, op2)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
239 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
240 }); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
241 |
0 | 242 (define_insn "mulv4hi3" |
243 [(set (match_operand:V4HI 0 "gr_register_operand" "=r") | |
244 (mult:V4HI (match_operand:V4HI 1 "gr_register_operand" "r") | |
245 (match_operand:V4HI 2 "gr_register_operand" "r")))] | |
246 "" | |
247 "pmpyshr2 %0 = %1, %2, 0" | |
248 [(set_attr "itanium_class" "mmmul")]) | |
249 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
250 (define_insn "pmpyshr2" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
251 [(set (match_operand:V4HI 0 "gr_register_operand" "=r") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
252 (truncate:V4HI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
253 (ashiftrt:V4SI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
254 (mult:V4SI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
255 (sign_extend:V4SI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
256 (match_operand:V4HI 1 "gr_register_operand" "r")) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
257 (sign_extend:V4SI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
258 (match_operand:V4HI 2 "gr_register_operand" "r"))) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
259 (match_operand:SI 3 "pmpyshr_operand" "n"))))] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
260 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
261 "pmpyshr2 %0 = %1, %2, %3" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
262 [(set_attr "itanium_class" "mmmul")]) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
263 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
264 (define_insn "pmpyshr2_u" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
265 [(set (match_operand:V4HI 0 "gr_register_operand" "=r") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
266 (truncate:V4HI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
267 (lshiftrt:V4SI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
268 (mult:V4SI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
269 (zero_extend:V4SI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
270 (match_operand:V4HI 1 "gr_register_operand" "r")) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
271 (zero_extend:V4SI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
272 (match_operand:V4HI 2 "gr_register_operand" "r"))) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
273 (match_operand:SI 3 "pmpyshr_operand" "n"))))] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
274 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
275 "pmpyshr2.u %0 = %1, %2, %3" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
276 [(set_attr "itanium_class" "mmmul")]) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
277 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
278 (define_insn "pmpy2_even" |
0 | 279 [(set (match_operand:V2SI 0 "gr_register_operand" "=r") |
280 (mult:V2SI | |
281 (vec_select:V2SI | |
282 (sign_extend:V4SI | |
283 (match_operand:V4HI 1 "gr_register_operand" "r")) | |
284 (parallel [(const_int 0) (const_int 2)])) | |
285 (vec_select:V2SI | |
286 (sign_extend:V4SI | |
287 (match_operand:V4HI 2 "gr_register_operand" "r")) | |
288 (parallel [(const_int 0) (const_int 2)]))))] | |
289 "" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
290 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
291 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
292 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
293 return "%,pmpy2.l %0 = %1, %2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
294 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
295 return "%,pmpy2.r %0 = %1, %2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
296 } |
0 | 297 [(set_attr "itanium_class" "mmshf")]) |
298 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
299 (define_insn "pmpy2_odd" |
0 | 300 [(set (match_operand:V2SI 0 "gr_register_operand" "=r") |
301 (mult:V2SI | |
302 (vec_select:V2SI | |
303 (sign_extend:V4SI | |
304 (match_operand:V4HI 1 "gr_register_operand" "r")) | |
305 (parallel [(const_int 1) (const_int 3)])) | |
306 (vec_select:V2SI | |
307 (sign_extend:V4SI | |
308 (match_operand:V4HI 2 "gr_register_operand" "r")) | |
309 (parallel [(const_int 1) (const_int 3)]))))] | |
310 "" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
311 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
312 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
313 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
314 return "%,pmpy2.r %0 = %1, %2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
315 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
316 return "%,pmpy2.l %0 = %1, %2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
317 } |
0 | 318 [(set_attr "itanium_class" "mmshf")]) |
319 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
320 (define_expand "vec_widen_smult_lo_v4hi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
321 [(match_operand:V2SI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
322 (match_operand:V4HI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
323 (match_operand:V4HI 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
324 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
325 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
326 rtx l = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
327 rtx h = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
328 emit_insn (gen_mulv4hi3 (l, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
329 emit_insn (gen_pmpyshr2 (h, operands[1], operands[2], GEN_INT (16))); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
330 ia64_unpack_assemble (operands[0], l, h, false); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
331 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
332 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
333 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
334 (define_expand "vec_widen_smult_hi_v4hi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
335 [(match_operand:V2SI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
336 (match_operand:V4HI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
337 (match_operand:V4HI 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
338 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
339 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
340 rtx l = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
341 rtx h = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
342 emit_insn (gen_mulv4hi3 (l, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
343 emit_insn (gen_pmpyshr2 (h, operands[1], operands[2], GEN_INT (16))); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
344 ia64_unpack_assemble (operands[0], l, h, true); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
345 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
346 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
347 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
348 (define_expand "vec_widen_umult_lo_v4hi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
349 [(match_operand:V2SI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
350 (match_operand:V4HI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
351 (match_operand:V4HI 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
352 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
353 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
354 rtx l = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
355 rtx h = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
356 emit_insn (gen_mulv4hi3 (l, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
357 emit_insn (gen_pmpyshr2_u (h, operands[1], operands[2], GEN_INT (16))); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
358 ia64_unpack_assemble (operands[0], l, h, false); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
359 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
360 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
361 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
362 (define_expand "vec_widen_umult_hi_v4hi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
363 [(match_operand:V2SI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
364 (match_operand:V4HI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
365 (match_operand:V4HI 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
366 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
367 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
368 rtx l = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
369 rtx h = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
370 emit_insn (gen_mulv4hi3 (l, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
371 emit_insn (gen_pmpyshr2_u (h, operands[1], operands[2], GEN_INT (16))); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
372 ia64_unpack_assemble (operands[0], l, h, true); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
373 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
374 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
375 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
376 (define_expand "mulv2si3" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
377 [(set (match_operand:V2SI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
378 (mult:V2SI (match_operand:V2SI 1 "gr_register_operand" "r") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
379 (match_operand:V2SI 2 "gr_register_operand" "r")))] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
380 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
381 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
382 rtx t0, t1, t2, t3, t4, t5, t6, t7, x; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
383 rtx op1h = gen_lowpart (V4HImode, operands[1]); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
384 rtx op2h = gen_lowpart (V4HImode, operands[2]); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
385 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
386 t0 = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
387 t1 = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
388 t2 = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
389 t3 = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
390 t4 = gen_reg_rtx (V2SImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
391 t5 = gen_reg_rtx (V2SImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
392 t6 = gen_reg_rtx (V2SImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
393 t7 = gen_reg_rtx (V2SImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
394 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
395 /* Consider the HImode components of op1 = DCBA, op2 = ZYXW. |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
396 Consider .l and .h suffixes below the low and high 16 bits |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
397 of the full 32-bit product. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
398 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
399 /* T0 = CDBA. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
400 x = gen_rtx_PARALLEL (VOIDmode, gen_rtvec (4, const1_rtx, const0_rtx, |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
401 GEN_INT (3), const2_rtx)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
402 x = gen_rtx_VEC_SELECT (V4HImode, op1h, x); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
403 emit_insn (gen_rtx_SET (VOIDmode, t0, x)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
404 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
405 /* T1 = DZ.l, CY.l, BX.l, AW.l. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
406 emit_insn (gen_mulv4hi3 (t1, op1h, op2h)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
407 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
408 /* T2 = DZ.h, CY.h, BX.h, AW.h. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
409 emit_insn (gen_pmpyshr2_u (t2, op1h, op2h, GEN_INT (16))); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
410 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
411 /* T3 = CZ.l, DY.l, AX.l, BW.l. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
412 emit_insn (gen_mulv4hi3 (t3, t0, op2h)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
413 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
414 /* T4 = CY.h, CY.l, AW.h, AW.l = CY, AW. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
415 x = gen_lowpart (V4HImode, t4); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
416 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
417 x = gen_mix2_odd (x, t2, t1); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
418 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
419 x = gen_mix2_even (x, t1, t2); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
420 emit_insn (x); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
421 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
422 /* T5 = CZ.l, 0, AX.l, 0 = CZ << 16, AX << 16. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
423 x = gen_lowpart (V4HImode, t5); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
424 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
425 x = gen_mix2_even (x, t3, CONST0_RTX (V4HImode)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
426 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
427 x = gen_mix2_odd (x, CONST0_RTX (V4HImode), t3); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
428 emit_insn (x); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
429 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
430 /* T6 = DY.l, 0, BW.l, 0 = DY << 16, BW << 16. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
431 x = gen_lowpart (V4HImode, t6); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
432 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
433 x = gen_mix2_odd (x, t3, CONST0_RTX (V4HImode)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
434 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
435 x = gen_mix2_even (x, CONST0_RTX (V4HImode), t3); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
436 emit_insn (x); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
437 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
438 emit_insn (gen_addv2si3 (t7, t4, t5)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
439 emit_insn (gen_addv2si3 (operands[0], t6, t7)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
440 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
441 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
442 |
0 | 443 (define_expand "umax<mode>3" |
444 [(set (match_operand:VECINT 0 "gr_register_operand" "") | |
445 (umax:VECINT (match_operand:VECINT 1 "gr_register_operand" "") | |
446 (match_operand:VECINT 2 "gr_register_operand" "")))] | |
447 "" | |
448 { | |
449 if (ia64_expand_vecint_minmax (UMAX, <MODE>mode, operands)) | |
450 DONE; | |
451 }) | |
452 | |
453 (define_expand "smax<mode>3" | |
454 [(set (match_operand:VECINT 0 "gr_register_operand" "") | |
455 (smax:VECINT (match_operand:VECINT 1 "gr_reg_or_0_operand" "") | |
456 (match_operand:VECINT 2 "gr_reg_or_0_operand" "")))] | |
457 "" | |
458 { | |
459 if (ia64_expand_vecint_minmax (SMAX, <MODE>mode, operands)) | |
460 DONE; | |
461 }) | |
462 | |
463 (define_expand "umin<mode>3" | |
464 [(set (match_operand:VECINT 0 "gr_register_operand" "") | |
465 (umin:VECINT (match_operand:VECINT 1 "gr_register_operand" "") | |
466 (match_operand:VECINT 2 "gr_register_operand" "")))] | |
467 "" | |
468 { | |
469 if (ia64_expand_vecint_minmax (UMIN, <MODE>mode, operands)) | |
470 DONE; | |
471 }) | |
472 | |
473 (define_expand "smin<mode>3" | |
474 [(set (match_operand:VECINT 0 "gr_register_operand" "") | |
475 (smin:VECINT (match_operand:VECINT 1 "gr_reg_or_0_operand" "") | |
476 (match_operand:VECINT 2 "gr_reg_or_0_operand" "")))] | |
477 "" | |
478 { | |
479 if (ia64_expand_vecint_minmax (SMIN, <MODE>mode, operands)) | |
480 DONE; | |
481 }) | |
482 | |
483 (define_insn "*umaxv8qi3" | |
484 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") | |
485 (umax:V8QI (match_operand:V8QI 1 "gr_register_operand" "r") | |
486 (match_operand:V8QI 2 "gr_register_operand" "r")))] | |
487 "" | |
488 "pmax1.u %0 = %1, %2" | |
489 [(set_attr "itanium_class" "mmshf")]) | |
490 | |
491 (define_insn "*smaxv4hi3" | |
492 [(set (match_operand:V4HI 0 "gr_register_operand" "=r") | |
493 (smax:V4HI (match_operand:V4HI 1 "gr_reg_or_0_operand" "rU") | |
494 (match_operand:V4HI 2 "gr_reg_or_0_operand" "rU")))] | |
495 "" | |
496 "pmax2 %0 = %r1, %r2" | |
497 [(set_attr "itanium_class" "mmshf")]) | |
498 | |
499 (define_insn "*uminv8qi3" | |
500 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") | |
501 (umin:V8QI (match_operand:V8QI 1 "gr_register_operand" "r") | |
502 (match_operand:V8QI 2 "gr_register_operand" "r")))] | |
503 "" | |
504 "pmin1.u %0 = %1, %2" | |
505 [(set_attr "itanium_class" "mmshf")]) | |
506 | |
507 (define_insn "*sminv4hi3" | |
508 [(set (match_operand:V4HI 0 "gr_register_operand" "=r") | |
509 (smin:V4HI (match_operand:V4HI 1 "gr_reg_or_0_operand" "rU") | |
510 (match_operand:V4HI 2 "gr_reg_or_0_operand" "rU")))] | |
511 "" | |
512 "pmin2 %0 = %r1, %r2" | |
513 [(set_attr "itanium_class" "mmshf")]) | |
514 | |
515 (define_insn "ashl<mode>3" | |
516 [(set (match_operand:VECINT24 0 "gr_register_operand" "=r") | |
517 (ashift:VECINT24 | |
518 (match_operand:VECINT24 1 "gr_register_operand" "r") | |
519 (match_operand:DI 2 "gr_reg_or_5bit_operand" "rn")))] | |
520 "" | |
521 "pshl<vecsize> %0 = %1, %2" | |
522 [(set_attr "itanium_class" "mmshf")]) | |
523 | |
524 (define_insn "ashr<mode>3" | |
525 [(set (match_operand:VECINT24 0 "gr_register_operand" "=r") | |
526 (ashiftrt:VECINT24 | |
527 (match_operand:VECINT24 1 "gr_register_operand" "r") | |
528 (match_operand:DI 2 "gr_reg_or_5bit_operand" "rn")))] | |
529 "" | |
530 "pshr<vecsize> %0 = %1, %2" | |
531 [(set_attr "itanium_class" "mmshf")]) | |
532 | |
533 (define_insn "lshr<mode>3" | |
534 [(set (match_operand:VECINT24 0 "gr_register_operand" "=r") | |
535 (lshiftrt:VECINT24 | |
536 (match_operand:VECINT24 1 "gr_register_operand" "r") | |
537 (match_operand:DI 2 "gr_reg_or_5bit_operand" "rn")))] | |
538 "" | |
539 "pshr<vecsize>.u %0 = %1, %2" | |
540 [(set_attr "itanium_class" "mmshf")]) | |
541 | |
542 (define_expand "vec_shl_<mode>" | |
543 [(set (match_operand:VECINT 0 "gr_register_operand" "") | |
544 (ashift:DI (match_operand:VECINT 1 "gr_register_operand" "") | |
545 (match_operand:DI 2 "gr_reg_or_6bit_operand" "")))] | |
546 "" | |
547 { | |
548 operands[0] = gen_lowpart (DImode, operands[0]); | |
549 operands[1] = gen_lowpart (DImode, operands[1]); | |
550 }) | |
551 | |
552 (define_expand "vec_shr_<mode>" | |
553 [(set (match_operand:VECINT 0 "gr_register_operand" "") | |
554 (lshiftrt:DI (match_operand:VECINT 1 "gr_register_operand" "") | |
555 (match_operand:DI 2 "gr_reg_or_6bit_operand" "")))] | |
556 "" | |
557 { | |
558 operands[0] = gen_lowpart (DImode, operands[0]); | |
559 operands[1] = gen_lowpart (DImode, operands[1]); | |
560 }) | |
561 | |
562 (define_expand "widen_usumv8qi3" | |
563 [(match_operand:V4HI 0 "gr_register_operand" "") | |
564 (match_operand:V8QI 1 "gr_register_operand" "") | |
565 (match_operand:V4HI 2 "gr_register_operand" "")] | |
566 "" | |
567 { | |
568 ia64_expand_widen_sum (operands, true); | |
569 DONE; | |
570 }) | |
571 | |
572 (define_expand "widen_usumv4hi3" | |
573 [(match_operand:V2SI 0 "gr_register_operand" "") | |
574 (match_operand:V4HI 1 "gr_register_operand" "") | |
575 (match_operand:V2SI 2 "gr_register_operand" "")] | |
576 "" | |
577 { | |
578 ia64_expand_widen_sum (operands, true); | |
579 DONE; | |
580 }) | |
581 | |
582 (define_expand "widen_ssumv8qi3" | |
583 [(match_operand:V4HI 0 "gr_register_operand" "") | |
584 (match_operand:V8QI 1 "gr_register_operand" "") | |
585 (match_operand:V4HI 2 "gr_register_operand" "")] | |
586 "" | |
587 { | |
588 ia64_expand_widen_sum (operands, false); | |
589 DONE; | |
590 }) | |
591 | |
592 (define_expand "widen_ssumv4hi3" | |
593 [(match_operand:V2SI 0 "gr_register_operand" "") | |
594 (match_operand:V4HI 1 "gr_register_operand" "") | |
595 (match_operand:V2SI 2 "gr_register_operand" "")] | |
596 "" | |
597 { | |
598 ia64_expand_widen_sum (operands, false); | |
599 DONE; | |
600 }) | |
601 | |
602 (define_expand "udot_prodv8qi" | |
603 [(match_operand:V2SI 0 "gr_register_operand" "") | |
604 (match_operand:V8QI 1 "gr_register_operand" "") | |
605 (match_operand:V8QI 2 "gr_register_operand" "") | |
606 (match_operand:V2SI 3 "gr_register_operand" "")] | |
607 "" | |
608 { | |
609 ia64_expand_dot_prod_v8qi (operands, true); | |
610 DONE; | |
611 }) | |
612 | |
613 (define_expand "sdot_prodv8qi" | |
614 [(match_operand:V2SI 0 "gr_register_operand" "") | |
615 (match_operand:V8QI 1 "gr_register_operand" "") | |
616 (match_operand:V8QI 2 "gr_register_operand" "") | |
617 (match_operand:V2SI 3 "gr_register_operand" "")] | |
618 "" | |
619 { | |
620 ia64_expand_dot_prod_v8qi (operands, false); | |
621 DONE; | |
622 }) | |
623 | |
624 (define_expand "sdot_prodv4hi" | |
625 [(match_operand:V2SI 0 "gr_register_operand" "") | |
626 (match_operand:V4HI 1 "gr_register_operand" "") | |
627 (match_operand:V4HI 2 "gr_register_operand" "") | |
628 (match_operand:V2SI 3 "gr_register_operand" "")] | |
629 "" | |
630 { | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
631 rtx e, o, t; |
0 | 632 |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
633 e = gen_reg_rtx (V2SImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
634 o = gen_reg_rtx (V2SImode); |
0 | 635 t = gen_reg_rtx (V2SImode); |
636 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
637 emit_insn (gen_pmpy2_even (e, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
638 emit_insn (gen_pmpy2_odd (o, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
639 emit_insn (gen_addv2si3 (t, e, operands[3])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
640 emit_insn (gen_addv2si3 (operands[0], t, o)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
641 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
642 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
643 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
644 (define_expand "udot_prodv4hi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
645 [(match_operand:V2SI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
646 (match_operand:V4HI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
647 (match_operand:V4HI 2 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
648 (match_operand:V2SI 3 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
649 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
650 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
651 rtx l, h, t; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
652 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
653 l = gen_reg_rtx (V2SImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
654 h = gen_reg_rtx (V2SImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
655 t = gen_reg_rtx (V2SImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
656 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
657 emit_insn (gen_vec_widen_umult_lo_v4hi (l, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
658 emit_insn (gen_vec_widen_umult_hi_v4hi (h, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
659 emit_insn (gen_addv2si3 (t, l, operands[3])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
660 emit_insn (gen_addv2si3 (operands[0], t, h)); |
0 | 661 DONE; |
662 }) | |
663 | |
664 (define_expand "vcond<mode>" | |
665 [(set (match_operand:VECINT 0 "gr_register_operand" "") | |
666 (if_then_else:VECINT | |
667 (match_operator 3 "" | |
668 [(match_operand:VECINT 4 "gr_reg_or_0_operand" "") | |
669 (match_operand:VECINT 5 "gr_reg_or_0_operand" "")]) | |
670 (match_operand:VECINT 1 "gr_reg_or_0_operand" "") | |
671 (match_operand:VECINT 2 "gr_reg_or_0_operand" "")))] | |
672 "" | |
673 { | |
674 ia64_expand_vecint_cmov (operands); | |
675 DONE; | |
676 }) | |
677 | |
678 (define_expand "vcondu<mode>" | |
679 [(set (match_operand:VECINT 0 "gr_register_operand" "") | |
680 (if_then_else:VECINT | |
681 (match_operator 3 "" | |
682 [(match_operand:VECINT 4 "gr_reg_or_0_operand" "") | |
683 (match_operand:VECINT 5 "gr_reg_or_0_operand" "")]) | |
684 (match_operand:VECINT 1 "gr_reg_or_0_operand" "") | |
685 (match_operand:VECINT 2 "gr_reg_or_0_operand" "")))] | |
686 "" | |
687 { | |
688 ia64_expand_vecint_cmov (operands); | |
689 DONE; | |
690 }) | |
691 | |
692 (define_insn "*cmpeq_<mode>" | |
693 [(set (match_operand:VECINT 0 "gr_register_operand" "=r") | |
694 (eq:VECINT (match_operand:VECINT 1 "gr_reg_or_0_operand" "rU") | |
695 (match_operand:VECINT 2 "gr_reg_or_0_operand" "rU")))] | |
696 "" | |
697 "pcmp<vecsize>.eq %0 = %r1, %r2" | |
698 [(set_attr "itanium_class" "mmalua")]) | |
699 | |
700 (define_insn "*cmpgt_<mode>" | |
701 [(set (match_operand:VECINT 0 "gr_register_operand" "=r") | |
702 (gt:VECINT (match_operand:VECINT 1 "gr_reg_or_0_operand" "rU") | |
703 (match_operand:VECINT 2 "gr_reg_or_0_operand" "rU")))] | |
704 "" | |
705 "pcmp<vecsize>.gt %0 = %r1, %r2" | |
706 [(set_attr "itanium_class" "mmalua")]) | |
707 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
708 (define_insn "vec_pack_ssat_v4hi" |
0 | 709 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") |
710 (vec_concat:V8QI | |
711 (ss_truncate:V4QI | |
712 (match_operand:V4HI 1 "gr_reg_or_0_operand" "rU")) | |
713 (ss_truncate:V4QI | |
714 (match_operand:V4HI 2 "gr_reg_or_0_operand" "rU"))))] | |
715 "" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
716 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
717 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
718 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
719 return "%,pack2.sss %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
720 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
721 return "%,pack2.sss %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
722 } |
0 | 723 [(set_attr "itanium_class" "mmshf")]) |
724 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
725 (define_insn "vec_pack_usat_v4hi" |
0 | 726 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") |
727 (vec_concat:V8QI | |
728 (us_truncate:V4QI | |
729 (match_operand:V4HI 1 "gr_reg_or_0_operand" "rU")) | |
730 (us_truncate:V4QI | |
731 (match_operand:V4HI 2 "gr_reg_or_0_operand" "rU"))))] | |
732 "" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
733 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
734 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
735 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
736 return "%,pack2.uss %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
737 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
738 return "%,pack2.uss %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
739 } |
0 | 740 [(set_attr "itanium_class" "mmshf")]) |
741 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
742 (define_insn "vec_pack_ssat_v2si" |
0 | 743 [(set (match_operand:V4HI 0 "gr_register_operand" "=r") |
744 (vec_concat:V4HI | |
745 (ss_truncate:V2HI | |
746 (match_operand:V2SI 1 "gr_reg_or_0_operand" "rU")) | |
747 (ss_truncate:V2HI | |
748 (match_operand:V2SI 2 "gr_reg_or_0_operand" "rU"))))] | |
749 "" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
750 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
751 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
752 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
753 return "%,pack4.sss %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
754 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
755 return "%,pack4.sss %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
756 } |
0 | 757 [(set_attr "itanium_class" "mmshf")]) |
758 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
759 (define_insn "vec_interleave_lowv8qi" |
0 | 760 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") |
761 (vec_select:V8QI | |
762 (vec_concat:V16QI | |
763 (match_operand:V8QI 1 "gr_reg_or_0_operand" "rU") | |
764 (match_operand:V8QI 2 "gr_reg_or_0_operand" "rU")) | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
765 (parallel [(const_int 0) (const_int 8) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
766 (const_int 1) (const_int 9) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
767 (const_int 2) (const_int 10) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
768 (const_int 3) (const_int 11)])))] |
0 | 769 "" |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
770 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
771 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
772 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
773 return "%,unpack1.l %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
774 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
775 return "%,unpack1.l %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
776 } |
0 | 777 [(set_attr "itanium_class" "mmshf")]) |
778 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
779 (define_insn "vec_interleave_highv8qi" |
0 | 780 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") |
781 (vec_select:V8QI | |
782 (vec_concat:V16QI | |
783 (match_operand:V8QI 1 "gr_reg_or_0_operand" "rU") | |
784 (match_operand:V8QI 2 "gr_reg_or_0_operand" "rU")) | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
785 (parallel [(const_int 4) (const_int 12) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
786 (const_int 5) (const_int 13) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
787 (const_int 6) (const_int 14) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
788 (const_int 7) (const_int 15)])))] |
0 | 789 "" |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
790 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
791 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
792 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
793 return "%,unpack1.h %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
794 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
795 return "%,unpack1.h %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
796 } |
0 | 797 [(set_attr "itanium_class" "mmshf")]) |
798 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
799 (define_insn "mix1_even" |
0 | 800 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") |
801 (vec_select:V8QI | |
802 (vec_concat:V16QI | |
803 (match_operand:V8QI 1 "gr_reg_or_0_operand" "rU") | |
804 (match_operand:V8QI 2 "gr_reg_or_0_operand" "rU")) | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
805 (parallel [(const_int 0) (const_int 8) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
806 (const_int 2) (const_int 10) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
807 (const_int 4) (const_int 12) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
808 (const_int 6) (const_int 14)])))] |
0 | 809 "" |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
810 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
811 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
812 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
813 return "%,mix1.l %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
814 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
815 return "%,mix1.r %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
816 } |
0 | 817 [(set_attr "itanium_class" "mmshf")]) |
818 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
819 (define_insn "mix1_odd" |
0 | 820 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") |
821 (vec_select:V8QI | |
822 (vec_concat:V16QI | |
823 (match_operand:V8QI 1 "gr_reg_or_0_operand" "rU") | |
824 (match_operand:V8QI 2 "gr_reg_or_0_operand" "rU")) | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
825 (parallel [(const_int 1) (const_int 9) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
826 (const_int 3) (const_int 11) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
827 (const_int 5) (const_int 13) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
828 (const_int 7) (const_int 15)])))] |
0 | 829 "" |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
830 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
831 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
832 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
833 return "%,mix1.r %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
834 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
835 return "%,mix1.l %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
836 } |
0 | 837 [(set_attr "itanium_class" "mmshf")]) |
838 | |
839 (define_insn "*mux1_rev" | |
840 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") | |
841 (vec_select:V8QI | |
842 (match_operand:V8QI 1 "gr_register_operand" "r") | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
843 (parallel [(const_int 7) (const_int 6) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
844 (const_int 5) (const_int 4) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
845 (const_int 3) (const_int 2) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
846 (const_int 1) (const_int 0)])))] |
0 | 847 "" |
848 "mux1 %0 = %1, @rev" | |
849 [(set_attr "itanium_class" "mmshf")]) | |
850 | |
851 (define_insn "*mux1_mix" | |
852 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") | |
853 (vec_select:V8QI | |
854 (match_operand:V8QI 1 "gr_register_operand" "r") | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
855 (parallel [(const_int 0) (const_int 4) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
856 (const_int 2) (const_int 6) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
857 (const_int 1) (const_int 5) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
858 (const_int 3) (const_int 7)])))] |
0 | 859 "" |
860 "mux1 %0 = %1, @mix" | |
861 [(set_attr "itanium_class" "mmshf")]) | |
862 | |
863 (define_insn "*mux1_shuf" | |
864 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") | |
865 (vec_select:V8QI | |
866 (match_operand:V8QI 1 "gr_register_operand" "r") | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
867 (parallel [(const_int 0) (const_int 4) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
868 (const_int 1) (const_int 5) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
869 (const_int 2) (const_int 6) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
870 (const_int 3) (const_int 7)])))] |
0 | 871 "" |
872 "mux1 %0 = %1, @shuf" | |
873 [(set_attr "itanium_class" "mmshf")]) | |
874 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
875 (define_insn "mux1_alt" |
0 | 876 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") |
877 (vec_select:V8QI | |
878 (match_operand:V8QI 1 "gr_register_operand" "r") | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
879 (parallel [(const_int 0) (const_int 2) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
880 (const_int 4) (const_int 6) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
881 (const_int 1) (const_int 3) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
882 (const_int 5) (const_int 7)])))] |
0 | 883 "" |
884 "mux1 %0 = %1, @alt" | |
885 [(set_attr "itanium_class" "mmshf")]) | |
886 | |
887 (define_insn "*mux1_brcst_v8qi" | |
888 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") | |
889 (vec_select:V8QI | |
890 (match_operand:V8QI 1 "gr_register_operand" "r") | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
891 (parallel [(match_operand 2 "mux1_brcst_element" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
892 (match_dup 2) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
893 (match_dup 2) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
894 (match_dup 2) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
895 (match_dup 2) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
896 (match_dup 2) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
897 (match_dup 2) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
898 (match_dup 2)])))] |
0 | 899 "" |
900 "mux1 %0 = %1, @brcst" | |
901 [(set_attr "itanium_class" "mmshf")]) | |
902 | |
903 (define_insn "*mux1_brcst_qi" | |
904 [(set (match_operand:V8QI 0 "gr_register_operand" "=r") | |
905 (vec_duplicate:V8QI | |
906 (match_operand:QI 1 "gr_register_operand" "r")))] | |
907 "" | |
908 "mux1 %0 = %1, @brcst" | |
909 [(set_attr "itanium_class" "mmshf")]) | |
910 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
911 (define_expand "vec_extract_evenv8qi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
912 [(match_operand:V8QI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
913 (match_operand:V8QI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
914 (match_operand:V8QI 2 "gr_register_operand" "")] |
0 | 915 "" |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
916 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
917 rtx temp = gen_reg_rtx (V8QImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
918 emit_insn (gen_mix1_even (temp, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
919 emit_insn (gen_mux1_alt (operands[0], temp)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
920 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
921 }) |
0 | 922 |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
923 (define_expand "vec_extract_oddv8qi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
924 [(match_operand:V8QI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
925 (match_operand:V8QI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
926 (match_operand:V8QI 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
927 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
928 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
929 rtx temp = gen_reg_rtx (V8QImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
930 emit_insn (gen_mix1_odd (temp, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
931 emit_insn (gen_mux1_alt (operands[0], temp)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
932 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
933 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
934 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
935 (define_insn "vec_interleave_lowv4hi" |
0 | 936 [(set (match_operand:V4HI 0 "gr_register_operand" "=r") |
937 (vec_select:V4HI | |
938 (vec_concat:V8HI | |
939 (match_operand:V4HI 1 "gr_reg_or_0_operand" "rU") | |
940 (match_operand:V4HI 2 "gr_reg_or_0_operand" "rU")) | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
941 (parallel [(const_int 0) (const_int 4) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
942 (const_int 1) (const_int 5)])))] |
0 | 943 "" |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
944 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
945 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
946 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
947 return "%,unpack2.l %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
948 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
949 return "%,unpack2.l %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
950 } |
0 | 951 [(set_attr "itanium_class" "mmshf")]) |
952 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
953 (define_insn "vec_interleave_highv4hi" |
0 | 954 [(set (match_operand:V4HI 0 "gr_register_operand" "=r") |
955 (vec_select:V4HI | |
956 (vec_concat:V8HI | |
957 (match_operand:V4HI 1 "gr_reg_or_0_operand" "rU") | |
958 (match_operand:V4HI 2 "gr_reg_or_0_operand" "rU")) | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
959 (parallel [(const_int 2) (const_int 6) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
960 (const_int 3) (const_int 7)])))] |
0 | 961 "" |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
962 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
963 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
964 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
965 return "%,unpack2.h %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
966 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
967 return "%,unpack2.h %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
968 } |
0 | 969 [(set_attr "itanium_class" "mmshf")]) |
970 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
971 (define_insn "mix2_even" |
0 | 972 [(set (match_operand:V4HI 0 "gr_register_operand" "=r") |
973 (vec_select:V4HI | |
974 (vec_concat:V8HI | |
975 (match_operand:V4HI 1 "gr_reg_or_0_operand" "rU") | |
976 (match_operand:V4HI 2 "gr_reg_or_0_operand" "rU")) | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
977 (parallel [(const_int 0) (const_int 4) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
978 (const_int 2) (const_int 6)])))] |
0 | 979 "" |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
980 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
981 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
982 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
983 return "%,mix2.l %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
984 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
985 return "%,mix2.r %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
986 } |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
987 [(set_attr "itanium_class" "mmshf")]) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
988 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
989 (define_insn "mix2_odd" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
990 [(set (match_operand:V4HI 0 "gr_register_operand" "=r") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
991 (vec_select:V4HI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
992 (vec_concat:V8HI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
993 (match_operand:V4HI 1 "gr_reg_or_0_operand" "rU") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
994 (match_operand:V4HI 2 "gr_reg_or_0_operand" "rU")) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
995 (parallel [(const_int 1) (const_int 5) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
996 (const_int 3) (const_int 7)])))] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
997 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
998 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
999 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1000 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1001 return "%,mix2.r %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1002 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1003 return "%,mix2.l %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1004 } |
0 | 1005 [(set_attr "itanium_class" "mmshf")]) |
1006 | |
1007 (define_insn "*mux2" | |
1008 [(set (match_operand:V4HI 0 "gr_register_operand" "=r") | |
1009 (vec_select:V4HI | |
1010 (match_operand:V4HI 1 "gr_register_operand" "r") | |
1011 (parallel [(match_operand 2 "const_int_2bit_operand" "") | |
1012 (match_operand 3 "const_int_2bit_operand" "") | |
1013 (match_operand 4 "const_int_2bit_operand" "") | |
1014 (match_operand 5 "const_int_2bit_operand" "")])))] | |
1015 "" | |
1016 { | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1017 int mask = 0; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1018 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1019 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1020 mask |= (3 - INTVAL (operands[2])) << 6; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1021 mask |= (3 - INTVAL (operands[3])) << 4; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1022 mask |= (3 - INTVAL (operands[4])) << 2; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1023 mask |= 3 - INTVAL (operands[5]); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1024 } |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1025 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1026 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1027 mask |= INTVAL (operands[2]); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1028 mask |= INTVAL (operands[3]) << 2; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1029 mask |= INTVAL (operands[4]) << 4; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1030 mask |= INTVAL (operands[5]) << 6; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1031 } |
0 | 1032 operands[2] = GEN_INT (mask); |
1033 return "%,mux2 %0 = %1, %2"; | |
1034 } | |
1035 [(set_attr "itanium_class" "mmshf")]) | |
1036 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1037 (define_expand "vec_extract_evenodd_helper" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1038 [(set (match_operand:V4HI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1039 (vec_select:V4HI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1040 (match_operand:V4HI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1041 (parallel [(const_int 0) (const_int 2) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1042 (const_int 1) (const_int 3)])))] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1043 "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1044 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1045 (define_expand "vec_extract_evenv4hi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1046 [(match_operand:V4HI 0 "gr_register_operand") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1047 (match_operand:V4HI 1 "gr_reg_or_0_operand") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1048 (match_operand:V4HI 2 "gr_reg_or_0_operand")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1049 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1050 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1051 rtx temp = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1052 emit_insn (gen_mix2_even (temp, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1053 emit_insn (gen_vec_extract_evenodd_helper (operands[0], temp)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1054 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1055 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1056 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1057 (define_expand "vec_extract_oddv4hi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1058 [(match_operand:V4HI 0 "gr_register_operand") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1059 (match_operand:V4HI 1 "gr_reg_or_0_operand") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1060 (match_operand:V4HI 2 "gr_reg_or_0_operand")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1061 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1062 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1063 rtx temp = gen_reg_rtx (V4HImode); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1064 emit_insn (gen_mix2_odd (temp, operands[1], operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1065 emit_insn (gen_vec_extract_evenodd_helper (operands[0], temp)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1066 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1067 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1068 |
0 | 1069 (define_insn "*mux2_brcst_hi" |
1070 [(set (match_operand:V4HI 0 "gr_register_operand" "=r") | |
1071 (vec_duplicate:V4HI | |
1072 (match_operand:HI 1 "gr_register_operand" "r")))] | |
1073 "" | |
1074 "mux2 %0 = %1, 0" | |
1075 [(set_attr "itanium_class" "mmshf")]) | |
1076 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1077 (define_insn "vec_interleave_lowv2si" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1078 [(set (match_operand:V2SI 0 "gr_register_operand" "=r") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1079 (vec_select:V2SI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1080 (vec_concat:V4SI |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1081 (match_operand:V2SI 1 "gr_reg_or_0_operand" "rU") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1082 (match_operand:V2SI 2 "gr_reg_or_0_operand" "rU")) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1083 (parallel [(const_int 0) (const_int 2)])))] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1084 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1085 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1086 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1087 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1088 return "%,unpack4.l %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1089 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1090 return "%,unpack4.l %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1091 } |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1092 [(set_attr "itanium_class" "mmshf")]) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1093 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1094 (define_insn "vec_interleave_highv2si" |
0 | 1095 [(set (match_operand:V2SI 0 "gr_register_operand" "=r") |
1096 (vec_select:V2SI | |
1097 (vec_concat:V4SI | |
1098 (match_operand:V2SI 1 "gr_reg_or_0_operand" "rU") | |
1099 (match_operand:V2SI 2 "gr_reg_or_0_operand" "rU")) | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1100 (parallel [(const_int 1) (const_int 3)])))] |
0 | 1101 "" |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1102 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1103 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1104 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1105 return "%,unpack4.h %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1106 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1107 return "%,unpack4.h %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1108 } |
0 | 1109 [(set_attr "itanium_class" "mmshf")]) |
1110 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1111 (define_expand "vec_extract_evenv2si" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1112 [(match_operand:V2SI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1113 (match_operand:V2SI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1114 (match_operand:V2SI 2 "gr_register_operand" "")] |
0 | 1115 "" |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1116 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1117 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1118 emit_insn (gen_vec_interleave_highv2si (operands[0], operands[1], |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1119 operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1120 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1121 emit_insn (gen_vec_interleave_lowv2si (operands[0], operands[1], |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1122 operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1123 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1124 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1125 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1126 (define_expand "vec_extract_oddv2si" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1127 [(match_operand:V2SI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1128 (match_operand:V2SI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1129 (match_operand:V2SI 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1130 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1131 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1132 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1133 emit_insn (gen_vec_interleave_lowv2si (operands[0], operands[1], |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1134 operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1135 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1136 emit_insn (gen_vec_interleave_highv2si (operands[0], operands[1], |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1137 operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1138 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1139 }) |
0 | 1140 |
1141 (define_expand "vec_initv2si" | |
1142 [(match_operand:V2SI 0 "gr_register_operand" "") | |
1143 (match_operand 1 "" "")] | |
1144 "" | |
1145 { | |
1146 rtx op1 = XVECEXP (operands[1], 0, 0); | |
1147 rtx op2 = XVECEXP (operands[1], 0, 1); | |
1148 rtx x; | |
1149 | |
1150 if (GET_CODE (op1) == CONST_INT && GET_CODE (op2) == CONST_INT) | |
1151 { | |
1152 x = gen_rtx_CONST_VECTOR (V2SImode, XVEC (operands[1], 0)); | |
1153 emit_move_insn (operands[0], x); | |
1154 DONE; | |
1155 } | |
1156 | |
1157 if (!gr_reg_or_0_operand (op1, SImode)) | |
1158 op1 = force_reg (SImode, op1); | |
1159 if (!gr_reg_or_0_operand (op2, SImode)) | |
1160 op2 = force_reg (SImode, op2); | |
1161 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1162 x = gen_rtx_VEC_CONCAT (V2SImode, op1, op2); |
0 | 1163 emit_insn (gen_rtx_SET (VOIDmode, operands[0], x)); |
1164 DONE; | |
1165 }) | |
1166 | |
1167 (define_insn "*vecinit_v2si" | |
1168 [(set (match_operand:V2SI 0 "gr_register_operand" "=r") | |
1169 (vec_concat:V2SI | |
1170 (match_operand:SI 1 "gr_reg_or_0_operand" "rO") | |
1171 (match_operand:SI 2 "gr_reg_or_0_operand" "rO")))] | |
1172 "" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1173 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1174 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1175 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1176 return "%,unpack4.l %0 = %r1, %r2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1177 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1178 return "%,unpack4.l %0 = %r2, %r1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1179 } |
0 | 1180 [(set_attr "itanium_class" "mmshf")]) |
1181 | |
1182 ;; Missing operations | |
1183 ;; padd.uus | |
1184 ;; pavg | |
1185 ;; pavgsub | |
1186 ;; psad | |
1187 ;; pshladd | |
1188 ;; pshradd | |
1189 ;; psub.uus | |
1190 | |
1191 ;; Floating point vector operations | |
1192 | |
1193 (define_expand "movv2sf" | |
1194 [(set (match_operand:V2SF 0 "general_operand" "") | |
1195 (match_operand:V2SF 1 "general_operand" ""))] | |
1196 "" | |
1197 { | |
1198 rtx op1 = ia64_expand_move (operands[0], operands[1]); | |
1199 if (!op1) | |
1200 DONE; | |
1201 operands[1] = op1; | |
1202 }) | |
1203 | |
1204 (define_insn "*movv2sf_internal" | |
1205 [(set (match_operand:V2SF 0 "destination_operand" | |
1206 "=f,f,f,Q,*r ,*r,*r,*r,m ,f ,*r") | |
1207 (match_operand:V2SF 1 "move_operand" | |
1208 "fU,Y,Q,f,U*r,W ,i ,m ,*r,*r,f "))] | |
1209 "ia64_move_ok (operands[0], operands[1])" | |
1210 { | |
1211 static const char * const alt[] = { | |
1212 "%,mov %0 = %F1", | |
1213 "%,fpack %0 = %F2, %F1", | |
1214 "%,ldf8 %0 = %1%P1", | |
1215 "%,stf8 %0 = %1%P0", | |
1216 "%,mov %0 = %r1", | |
1217 "%,addl %0 = %v1, r0", | |
1218 "%,movl %0 = %v1", | |
1219 "%,ld8%O1 %0 = %1%P1", | |
1220 "%,st8%Q0 %0 = %r1%P0", | |
1221 "%,setf.sig %0 = %1", | |
1222 "%,getf.sig %0 = %1" | |
1223 }; | |
1224 | |
1225 if (which_alternative == 1) | |
1226 { | |
55
77e2b8dfacca
update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents:
0
diff
changeset
|
1227 operands[2] = XVECEXP (operands[1], 0, TARGET_BIG_ENDIAN ? 0 : 1); |
77e2b8dfacca
update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents:
0
diff
changeset
|
1228 operands[1] = XVECEXP (operands[1], 0, TARGET_BIG_ENDIAN ? 1 : 0); |
0 | 1229 } |
1230 | |
1231 return alt[which_alternative]; | |
1232 } | |
1233 [(set_attr "itanium_class" "fmisc,fmisc,fld,stf,ialu,ialu,long_i,ld,st,tofr,frfr")]) | |
1234 | |
1235 (define_insn "absv2sf2" | |
1236 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") | |
1237 (abs:V2SF (match_operand:V2SF 1 "fr_register_operand" "f")))] | |
1238 "" | |
1239 "fpabs %0 = %1" | |
1240 [(set_attr "itanium_class" "fmisc")]) | |
1241 | |
1242 (define_insn "negv2sf2" | |
1243 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") | |
1244 (neg:V2SF (match_operand:V2SF 1 "fr_register_operand" "f")))] | |
1245 "" | |
1246 "fpneg %0 = %1" | |
1247 [(set_attr "itanium_class" "fmisc")]) | |
1248 | |
1249 (define_insn "*negabsv2sf2" | |
1250 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") | |
1251 (neg:V2SF | |
1252 (abs:V2SF (match_operand:V2SF 1 "fr_register_operand" "f"))))] | |
1253 "" | |
1254 "fpnegabs %0 = %1" | |
1255 [(set_attr "itanium_class" "fmisc")]) | |
1256 | |
1257 (define_expand "addv2sf3" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1258 [(set (match_operand:V2SF 0 "fr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1259 (fma:V2SF (match_operand:V2SF 1 "fr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1260 (match_dup 3) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1261 (match_operand:V2SF 2 "fr_register_operand" "")))] |
0 | 1262 "" |
1263 { | |
1264 rtvec v = gen_rtvec (2, CONST1_RTX (SFmode), CONST1_RTX (SFmode)); | |
1265 operands[3] = force_reg (V2SFmode, gen_rtx_CONST_VECTOR (V2SFmode, v)); | |
1266 }) | |
1267 | |
1268 (define_expand "subv2sf3" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1269 [(set (match_operand:V2SF 0 "fr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1270 (fma:V2SF |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1271 (match_operand:V2SF 1 "fr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1272 (match_dup 3) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1273 (neg:V2SF (match_operand:V2SF 2 "fr_register_operand" ""))))] |
0 | 1274 "" |
1275 { | |
1276 rtvec v = gen_rtvec (2, CONST1_RTX (SFmode), CONST1_RTX (SFmode)); | |
1277 operands[3] = force_reg (V2SFmode, gen_rtx_CONST_VECTOR (V2SFmode, v)); | |
1278 }) | |
1279 | |
1280 (define_insn "mulv2sf3" | |
1281 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") | |
1282 (mult:V2SF (match_operand:V2SF 1 "fr_register_operand" "f") | |
1283 (match_operand:V2SF 2 "fr_register_operand" "f")))] | |
1284 "" | |
1285 "fpmpy %0 = %1, %2" | |
1286 [(set_attr "itanium_class" "fmac")]) | |
1287 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1288 (define_insn "fmav2sf4" |
0 | 1289 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1290 (fma:V2SF |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1291 (match_operand:V2SF 1 "fr_register_operand" "f") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1292 (match_operand:V2SF 2 "fr_register_operand" "f") |
0 | 1293 (match_operand:V2SF 3 "fr_register_operand" "f")))] |
1294 "" | |
1295 "fpma %0 = %1, %2, %3" | |
1296 [(set_attr "itanium_class" "fmac")]) | |
1297 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1298 (define_insn "fmsv2sf4" |
0 | 1299 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1300 (fma:V2SF |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1301 (match_operand:V2SF 1 "fr_register_operand" "f") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1302 (match_operand:V2SF 2 "fr_register_operand" "f") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1303 (neg:V2SF (match_operand:V2SF 3 "fr_register_operand" "f"))))] |
0 | 1304 "" |
1305 "fpms %0 = %1, %2, %3" | |
1306 [(set_attr "itanium_class" "fmac")]) | |
1307 | |
1308 (define_insn "*fpnmpy" | |
1309 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") | |
1310 (neg:V2SF | |
1311 (mult:V2SF (match_operand:V2SF 1 "fr_register_operand" "f") | |
1312 (match_operand:V2SF 2 "fr_register_operand" "f"))))] | |
1313 "" | |
1314 "fpnmpy %0 = %1, %2" | |
1315 [(set_attr "itanium_class" "fmac")]) | |
1316 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1317 (define_insn "fnmav2sf4" |
0 | 1318 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1319 (fma:V2SF |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1320 (neg:V2SF (match_operand:V2SF 1 "fr_register_operand" "f")) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1321 (match_operand:V2SF 2 "fr_register_operand" "f") |
0 | 1322 (match_operand:V2SF 3 "fr_register_operand" "f")))] |
1323 "" | |
1324 "fpnma %0 = %1, %2, %3" | |
1325 [(set_attr "itanium_class" "fmac")]) | |
1326 | |
1327 (define_insn "smaxv2sf3" | |
1328 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") | |
1329 (smax:V2SF (match_operand:V2SF 1 "fr_register_operand" "f") | |
1330 (match_operand:V2SF 2 "fr_register_operand" "f")))] | |
1331 "" | |
1332 "fpmax %0 = %1, %2" | |
1333 [(set_attr "itanium_class" "fmisc")]) | |
1334 | |
1335 (define_insn "sminv2sf3" | |
1336 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") | |
1337 (smin:V2SF (match_operand:V2SF 1 "fr_register_operand" "f") | |
1338 (match_operand:V2SF 2 "fr_register_operand" "f")))] | |
1339 "" | |
1340 "fpmin %0 = %1, %2" | |
1341 [(set_attr "itanium_class" "fmisc")]) | |
1342 | |
1343 (define_expand "reduc_splus_v2sf" | |
1344 [(match_operand:V2SF 0 "fr_register_operand" "") | |
1345 (match_operand:V2SF 1 "fr_register_operand" "")] | |
1346 "" | |
1347 { | |
1348 rtx tmp = gen_reg_rtx (V2SFmode); | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1349 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1350 emit_insn (gen_fswap (tmp, CONST0_RTX (V2SFmode), operands[1])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1351 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1352 emit_insn (gen_fswap (tmp, operands[1], CONST0_RTX (V2SFmode))); |
0 | 1353 emit_insn (gen_addv2sf3 (operands[0], operands[1], tmp)); |
1354 DONE; | |
1355 }) | |
1356 | |
1357 (define_expand "reduc_smax_v2sf" | |
1358 [(match_operand:V2SF 0 "fr_register_operand" "") | |
1359 (match_operand:V2SF 1 "fr_register_operand" "")] | |
1360 "" | |
1361 { | |
1362 rtx tmp = gen_reg_rtx (V2SFmode); | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1363 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1364 emit_insn (gen_fswap (tmp, CONST0_RTX (V2SFmode), operands[1])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1365 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1366 emit_insn (gen_fswap (tmp, operands[1], CONST0_RTX (V2SFmode))); |
0 | 1367 emit_insn (gen_smaxv2sf3 (operands[0], operands[1], tmp)); |
1368 DONE; | |
1369 }) | |
1370 | |
1371 (define_expand "reduc_smin_v2sf" | |
1372 [(match_operand:V2SF 0 "fr_register_operand" "") | |
1373 (match_operand:V2SF 1 "fr_register_operand" "")] | |
1374 "" | |
1375 { | |
1376 rtx tmp = gen_reg_rtx (V2SFmode); | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1377 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1378 emit_insn (gen_fswap (tmp, CONST0_RTX (V2SFmode), operands[1])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1379 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1380 emit_insn (gen_fswap (tmp, operands[1], CONST0_RTX (V2SFmode))); |
0 | 1381 emit_insn (gen_sminv2sf3 (operands[0], operands[1], tmp)); |
1382 DONE; | |
1383 }) | |
1384 | |
1385 (define_expand "vcondv2sf" | |
1386 [(set (match_operand:V2SF 0 "fr_register_operand" "") | |
1387 (if_then_else:V2SF | |
1388 (match_operator 3 "" | |
1389 [(match_operand:V2SF 4 "fr_reg_or_0_operand" "") | |
1390 (match_operand:V2SF 5 "fr_reg_or_0_operand" "")]) | |
1391 (match_operand:V2SF 1 "fr_reg_or_0_operand" "") | |
1392 (match_operand:V2SF 2 "fr_reg_or_0_operand" "")))] | |
1393 "" | |
1394 { | |
1395 rtx x, cmp; | |
1396 | |
1397 cmp = gen_reg_rtx (V2SFmode); | |
1398 PUT_MODE (operands[3], V2SFmode); | |
1399 emit_insn (gen_rtx_SET (VOIDmode, cmp, operands[3])); | |
1400 | |
1401 x = gen_rtx_IF_THEN_ELSE (V2SFmode, cmp, operands[1], operands[2]); | |
1402 emit_insn (gen_rtx_SET (VOIDmode, operands[0], x)); | |
1403 DONE; | |
1404 }) | |
1405 | |
1406 (define_insn "*fpcmp" | |
1407 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") | |
1408 (match_operator:V2SF 3 "comparison_operator" | |
1409 [(match_operand:V2SF 1 "fr_reg_or_0_operand" "fU") | |
1410 (match_operand:V2SF 2 "fr_reg_or_0_operand" "fU")]))] | |
1411 "" | |
1412 "fpcmp.%D3 %0 = %F1, %F2" | |
1413 [(set_attr "itanium_class" "fmisc")]) | |
1414 | |
1415 (define_insn "*fselect" | |
1416 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") | |
1417 (if_then_else:V2SF | |
1418 (match_operand:V2SF 1 "fr_register_operand" "f") | |
1419 (match_operand:V2SF 2 "fr_reg_or_0_operand" "fU") | |
1420 (match_operand:V2SF 3 "fr_reg_or_0_operand" "fU")))] | |
1421 "" | |
1422 "fselect %0 = %F2, %F3, %1" | |
1423 [(set_attr "itanium_class" "fmisc")]) | |
1424 | |
1425 (define_expand "vec_initv2sf" | |
1426 [(match_operand:V2SF 0 "fr_register_operand" "") | |
1427 (match_operand 1 "" "")] | |
1428 "" | |
1429 { | |
1430 rtx op1 = XVECEXP (operands[1], 0, 0); | |
1431 rtx op2 = XVECEXP (operands[1], 0, 1); | |
1432 rtx x; | |
1433 | |
1434 if (GET_CODE (op1) == CONST_DOUBLE && GET_CODE (op2) == CONST_DOUBLE) | |
1435 { | |
1436 x = gen_rtx_CONST_VECTOR (V2SFmode, XVEC (operands[1], 0)); | |
1437 emit_move_insn (operands[0], x); | |
1438 DONE; | |
1439 } | |
1440 | |
1441 if (!fr_reg_or_fp01_operand (op1, SFmode)) | |
1442 op1 = force_reg (SFmode, op1); | |
1443 if (!fr_reg_or_fp01_operand (op2, SFmode)) | |
1444 op2 = force_reg (SFmode, op2); | |
1445 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1446 emit_insn (gen_fpack (operands[0], op1, op2)); |
0 | 1447 DONE; |
1448 }) | |
1449 | |
1450 (define_insn "fpack" | |
1451 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") | |
1452 (vec_concat:V2SF | |
1453 (match_operand:SF 1 "fr_reg_or_fp01_operand" "fG") | |
1454 (match_operand:SF 2 "fr_reg_or_fp01_operand" "fG")))] | |
1455 "" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1456 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1457 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1458 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1459 return "%,fpack %0 = %F1, %F2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1460 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1461 return "%,fpack %0 = %F2, %F1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1462 } |
0 | 1463 [(set_attr "itanium_class" "fmisc")]) |
1464 | |
1465 (define_insn "fswap" | |
1466 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") | |
1467 (vec_select:V2SF | |
1468 (vec_concat:V4SF | |
1469 (match_operand:V2SF 1 "fr_reg_or_0_operand" "fU") | |
1470 (match_operand:V2SF 2 "fr_reg_or_0_operand" "fU")) | |
1471 (parallel [(const_int 1) (const_int 2)])))] | |
1472 "" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1473 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1474 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1475 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1476 return "%,fswap %0 = %F2, %F1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1477 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1478 return "%,fswap %0 = %F1, %F2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1479 } |
0 | 1480 [(set_attr "itanium_class" "fmisc")]) |
1481 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1482 (define_insn "vec_interleave_highv2sf" |
0 | 1483 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") |
1484 (vec_select:V2SF | |
1485 (vec_concat:V4SF | |
1486 (match_operand:V2SF 1 "fr_reg_or_0_operand" "fU") | |
1487 (match_operand:V2SF 2 "fr_reg_or_0_operand" "fU")) | |
1488 (parallel [(const_int 1) (const_int 3)])))] | |
1489 "" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1490 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1491 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1492 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1493 return "%,fmix.l %0 = %F1, %F2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1494 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1495 return "%,fmix.l %0 = %F2, %F1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1496 } |
0 | 1497 [(set_attr "itanium_class" "fmisc")]) |
1498 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1499 (define_insn "vec_interleave_lowv2sf" |
0 | 1500 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") |
1501 (vec_select:V2SF | |
1502 (vec_concat:V4SF | |
1503 (match_operand:V2SF 1 "fr_reg_or_0_operand" "fU") | |
1504 (match_operand:V2SF 2 "fr_reg_or_0_operand" "fU")) | |
1505 (parallel [(const_int 0) (const_int 2)])))] | |
1506 "" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1507 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1508 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1509 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1510 return "%,fmix.r %0 = %F1, %F2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1511 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1512 return "%,fmix.r %0 = %F2, %F1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1513 } |
0 | 1514 [(set_attr "itanium_class" "fmisc")]) |
1515 | |
1516 (define_insn "fmix_lr" | |
1517 [(set (match_operand:V2SF 0 "fr_register_operand" "=f") | |
1518 (vec_select:V2SF | |
1519 (vec_concat:V4SF | |
1520 (match_operand:V2SF 1 "fr_reg_or_0_operand" "fU") | |
1521 (match_operand:V2SF 2 "fr_reg_or_0_operand" "fU")) | |
1522 (parallel [(const_int 0) (const_int 3)])))] | |
1523 "" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1524 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1525 /* Recall that vector elements are numbered in memory order. */ |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1526 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1527 return "%,fmix.lr %0 = %F1, %F2"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1528 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1529 return "%,fmix.lr %0 = %F2, %F1"; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1530 } |
0 | 1531 [(set_attr "itanium_class" "fmisc")]) |
1532 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1533 (define_expand "vec_extract_evenv2sf" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1534 [(match_operand:V2SF 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1535 (match_operand:V2SF 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1536 (match_operand:V2SF 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1537 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1538 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1539 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1540 emit_insn (gen_vec_interleave_highv2sf (operands[0], operands[1], |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1541 operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1542 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1543 emit_insn (gen_vec_interleave_lowv2sf (operands[0], operands[1], |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1544 operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1545 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1546 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1547 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1548 (define_expand "vec_extract_oddv2sf" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1549 [(match_operand:V2SF 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1550 (match_operand:V2SF 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1551 (match_operand:V2SF 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1552 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1553 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1554 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1555 emit_insn (gen_vec_interleave_lowv2sf (operands[0], operands[1], |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1556 operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1557 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1558 emit_insn (gen_vec_interleave_highv2sf (operands[0], operands[1], |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1559 operands[2])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1560 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1561 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1562 |
0 | 1563 (define_expand "vec_setv2sf" |
1564 [(match_operand:V2SF 0 "fr_register_operand" "") | |
1565 (match_operand:SF 1 "fr_register_operand" "") | |
1566 (match_operand 2 "const_int_operand" "")] | |
1567 "" | |
1568 { | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1569 rtx op0 = operands[0]; |
0 | 1570 rtx tmp = gen_reg_rtx (V2SFmode); |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1571 |
0 | 1572 emit_insn (gen_fpack (tmp, operands[1], CONST0_RTX (SFmode))); |
1573 | |
1574 switch (INTVAL (operands[2])) | |
1575 { | |
1576 case 0: | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1577 emit_insn (gen_fmix_lr (op0, tmp, op0)); |
0 | 1578 break; |
1579 case 1: | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1580 emit_insn (gen_vec_interleave_lowv2sf (op0, op0, tmp)); |
0 | 1581 break; |
1582 default: | |
1583 gcc_unreachable (); | |
1584 } | |
1585 DONE; | |
1586 }) | |
1587 | |
1588 (define_insn_and_split "*vec_extractv2sf_0_le" | |
1589 [(set (match_operand:SF 0 "nonimmediate_operand" "=r,f,m") | |
1590 (unspec:SF [(match_operand:V2SF 1 "nonimmediate_operand" "rfm,rm,r") | |
1591 (const_int 0)] | |
1592 UNSPEC_VECT_EXTR))] | |
1593 "!TARGET_BIG_ENDIAN" | |
1594 "#" | |
1595 "reload_completed" | |
1596 [(set (match_dup 0) (match_dup 1))] | |
1597 { | |
1598 if (REG_P (operands[1]) && FR_REGNO_P (REGNO (operands[1]))) | |
1599 operands[0] = gen_rtx_REG (V2SFmode, REGNO (operands[0])); | |
1600 else if (MEM_P (operands[1])) | |
1601 operands[1] = adjust_address (operands[1], SFmode, 0); | |
1602 else | |
1603 operands[1] = gen_rtx_REG (SFmode, REGNO (operands[1])); | |
1604 }) | |
1605 | |
1606 (define_insn_and_split "*vec_extractv2sf_0_be" | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1607 [(set (match_operand:SF 0 "register_operand" "=rf,r") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1608 (unspec:SF [(match_operand:V2SF 1 "nonimmediate_operand" "m,r") |
0 | 1609 (const_int 0)] |
1610 UNSPEC_VECT_EXTR))] | |
1611 "TARGET_BIG_ENDIAN" | |
1612 "#" | |
1613 "reload_completed" | |
1614 [(set (match_dup 0) (match_dup 1))] | |
1615 { | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1616 if (MEM_P (operands[1])) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1617 operands[1] = adjust_address (operands[1], SFmode, 0); |
0 | 1618 else |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1619 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1620 emit_insn (gen_lshrdi3 (operands[0], operands[1], GEN_INT (32))); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1621 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1622 } |
0 | 1623 }) |
1624 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1625 (define_insn_and_split "*vec_extractv2sf_1_le" |
0 | 1626 [(set (match_operand:SF 0 "register_operand" "=r") |
1627 (unspec:SF [(match_operand:V2SF 1 "register_operand" "r") | |
1628 (const_int 1)] | |
1629 UNSPEC_VECT_EXTR))] | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1630 "!TARGET_BIG_ENDIAN" |
0 | 1631 "#" |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1632 "&& reload_completed" |
0 | 1633 [(const_int 0)] |
1634 { | |
1635 operands[0] = gen_rtx_REG (DImode, REGNO (operands[0])); | |
1636 operands[1] = gen_rtx_REG (DImode, REGNO (operands[1])); | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1637 emit_insn (gen_lshrdi3 (operands[0], operands[1], GEN_INT (32))); |
0 | 1638 DONE; |
1639 }) | |
1640 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1641 (define_insn_and_split "*vec_extractv2sf_1_be" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1642 [(set (match_operand:SF 0 "register_operand" "=rf") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1643 (unspec:SF [(match_operand:V2SF 1 "register_operand" "r") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1644 (const_int 1)] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1645 UNSPEC_VECT_EXTR))] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1646 "TARGET_BIG_ENDIAN" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1647 "#" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1648 "&& reload_completed" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1649 [(set (match_dup 0) (match_dup 1))] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1650 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1651 operands[1] = gen_rtx_REG (SFmode, REGNO (operands[1])); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1652 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1653 |
0 | 1654 (define_expand "vec_extractv2sf" |
1655 [(set (match_operand:SF 0 "register_operand" "") | |
1656 (unspec:SF [(match_operand:V2SF 1 "register_operand" "") | |
1657 (match_operand:DI 2 "const_int_operand" "")] | |
1658 UNSPEC_VECT_EXTR))] | |
1659 "" | |
1660 "") | |
1661 | |
67
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1662 (define_expand "vec_unpacku_lo_<mode>" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1663 [(match_operand:<vecwider> 0 "register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1664 (match_operand:VECINT12 1 "register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1665 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1666 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1667 ia64_expand_unpack (operands, true, false); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1668 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1669 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1670 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1671 (define_expand "vec_unpacku_hi_<mode>" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1672 [(match_operand:<vecwider> 0 "register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1673 (match_operand:VECINT12 1 "register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1674 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1675 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1676 ia64_expand_unpack (operands, true, true); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1677 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1678 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1679 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1680 (define_expand "vec_unpacks_lo_<mode>" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1681 [(match_operand:<vecwider> 0 "register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1682 (match_operand:VECINT12 1 "register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1683 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1684 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1685 ia64_expand_unpack (operands, false, false); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1686 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1687 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1688 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1689 (define_expand "vec_unpacks_hi_<mode>" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1690 [(match_operand:<vecwider> 0 "register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1691 (match_operand:VECINT12 1 "register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1692 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1693 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1694 ia64_expand_unpack (operands, false, true); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1695 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1696 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1697 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1698 (define_expand "vec_pack_trunc_v4hi" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1699 [(match_operand:V8QI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1700 (match_operand:V4HI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1701 (match_operand:V4HI 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1702 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1703 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1704 rtx op1 = gen_lowpart (V8QImode, operands[1]); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1705 rtx op2 = gen_lowpart (V8QImode, operands[2]); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1706 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1707 emit_insn (gen_vec_extract_oddv8qi (operands[0], op1, op2)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1708 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1709 emit_insn (gen_vec_extract_evenv8qi (operands[0], op1, op2)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1710 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1711 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1712 |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1713 (define_expand "vec_pack_trunc_v2si" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1714 [(match_operand:V4HI 0 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1715 (match_operand:V2SI 1 "gr_register_operand" "") |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1716 (match_operand:V2SI 2 "gr_register_operand" "")] |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1717 "" |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1718 { |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1719 rtx op1 = gen_lowpart (V4HImode, operands[1]); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1720 rtx op2 = gen_lowpart (V4HImode, operands[2]); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1721 if (TARGET_BIG_ENDIAN) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1722 emit_insn (gen_vec_extract_oddv4hi (operands[0], op1, op2)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1723 else |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1724 emit_insn (gen_vec_extract_evenv4hi (operands[0], op1, op2)); |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1725 DONE; |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1726 }) |
f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
parents:
55
diff
changeset
|
1727 |
0 | 1728 ;; Missing operations |
1729 ;; fprcpa | |
1730 ;; fpsqrta |