2 ;; Copyright (C) 2002 Free Software Foundation, Inc.
3 ;; Contributed by Aldy Hernandez (aldy@quesejoda.com)
5 ;; This file is part of GNU CC.
7 ;; GNU CC is free software; you can redistribute it and/or modify
8 ;; it under the terms of the GNU General Public License as published by
9 ;; the Free Software Foundation; either version 2, or (at your option)
12 ;; GNU CC is distributed in the hope that it will be useful,
13 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
14 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 ;; GNU General Public License for more details.
17 ;; You should have received a copy of the GNU General Public License
18 ;; along with GNU CC; see the file COPYING. If not, write to
19 ;; the Free Software Foundation, 59 Temple Place - Suite 330,
20 ;; Boston, MA 02111-1307, USA.
22 ;; Generic LVX load instruction.
23 (define_insn "altivec_lvx_4si"
24 [(set (match_operand:V4SI 0 "altivec_register_operand" "=v")
25 (match_operand:V4SI 1 "memory_operand" "m"))]
28 [(set_attr "type" "vecload")])
30 (define_insn "altivec_lvx_8hi"
31 [(set (match_operand:V8HI 0 "altivec_register_operand" "=v")
32 (match_operand:V8HI 1 "memory_operand" "m"))]
35 [(set_attr "type" "vecload")])
37 (define_insn "altivec_lvx_16qi"
38 [(set (match_operand:V16QI 0 "altivec_register_operand" "=v")
39 (match_operand:V16QI 1 "memory_operand" "m"))]
42 [(set_attr "type" "vecload")])
44 (define_insn "altivec_lvx_4sf"
45 [(set (match_operand:V4SF 0 "altivec_register_operand" "=v")
46 (match_operand:V4SF 1 "memory_operand" "m"))]
49 [(set_attr "type" "vecload")])
51 ;; Generic STVX store instruction.
52 (define_insn "altivec_stvx_4si"
53 [(set (match_operand:V4SI 0 "memory_operand" "=m")
54 (match_operand:V4SI 1 "altivec_register_operand" "v"))]
57 [(set_attr "type" "vecstore")])
59 (define_insn "altivec_stvx_8hi"
60 [(set (match_operand:V8HI 0 "memory_operand" "=m")
61 (match_operand:V8HI 1 "altivec_register_operand" "v"))]
64 [(set_attr "type" "vecstore")])
66 (define_insn "altivec_stvx_16qi"
67 [(set (match_operand:V16QI 0 "memory_operand" "=m")
68 (match_operand:V16QI 1 "altivec_register_operand" "v"))]
71 [(set_attr "type" "vecstore")])
73 (define_insn "altivec_stvx_4sf"
74 [(set (match_operand:V4SF 0 "memory_operand" "=m")
75 (match_operand:V4SF 1 "altivec_register_operand" "v"))]
78 [(set_attr "type" "vecstore")])
80 ;; Vector move instructions.
81 (define_expand "movv4si"
82 [(set (match_operand:V4SI 0 "nonimmediate_operand" "")
83 (match_operand:V4SI 1 "any_operand" ""))]
85 "{ rs6000_emit_move (operands[0], operands[1], V4SImode); DONE; }")
87 (define_insn "*movv4si_internal"
88 [(set (match_operand:V4SI 0 "nonimmediate_operand" "=m,v,v,o,r,r")
89 (match_operand:V4SI 1 "input_operand" "v,m,v,r,o,r"))]
95 stw%U0 %1,%0\;stw %L1,%L0\;stw %Y1,%Y0\;stw %Z1,%Z0
96 lwz%U1 %0,%1\;lwz %L0,%L1\;lwz %Y0,%Y1\;lwz %Z0,%Z1
97 mr %0,%1\;mr %L0,%L1\;mr %Y0,%Y1\;mr %Z0,%Z1"
98 [(set_attr "type" "altivec")
99 (set_attr "length" "*,*,*,16,16,16")])
101 (define_expand "movv8hi"
102 [(set (match_operand:V8HI 0 "nonimmediate_operand" "")
103 (match_operand:V8HI 1 "any_operand" ""))]
105 "{ rs6000_emit_move (operands[0], operands[1], V8HImode); DONE; }")
107 (define_insn "*movv8hi_internal1"
108 [(set (match_operand:V8HI 0 "nonimmediate_operand" "=m,v,v,o,r,r")
109 (match_operand:V8HI 1 "input_operand" "v,m,v,r,o,r"))]
115 stw%U0 %1,%0\;stw %L1,%L0\;stw %Y1,%Y0\;stw %Z1,%Z0
116 lwz%U1 %0,%1\;lwz %L0,%L1\;lwz %Y0,%Y1\;lwz %Z0,%Z1
117 mr %0,%1\;mr %L0,%L1\;mr %Y0,%Y1\;mr %Z0,%Z1"
118 [(set_attr "type" "altivec")
119 (set_attr "length" "*,*,*,16,16,16")])
121 (define_expand "movv16qi"
122 [(set (match_operand:V16QI 0 "nonimmediate_operand" "")
123 (match_operand:V16QI 1 "any_operand" ""))]
125 "{ rs6000_emit_move (operands[0], operands[1], V16QImode); DONE; }")
127 (define_insn "*movv16qi_internal1"
128 [(set (match_operand:V16QI 0 "nonimmediate_operand" "=m,v,v,o,r,r")
129 (match_operand:V16QI 1 "input_operand" "v,m,v,r,o,r"))]
135 stw%U0 %1,%0\;stw %L1,%L0\;stw %Y1,%Y0\;stw %Z1,%Z0
136 lwz%U1 %0,%1\;lwz %L0,%L1\;lwz %Y0,%Y1\;lwz %Z0,%Z1
137 mr %0,%1\;mr %L0,%L1\;mr %Y0,%Y1\;mr %Z0,%Z1"
138 [(set_attr "type" "altivec")
139 (set_attr "length" "*,*,*,16,16,16")])
141 (define_expand "movv4sf"
142 [(set (match_operand:V4SF 0 "nonimmediate_operand" "")
143 (match_operand:V4SF 1 "any_operand" ""))]
145 "{ rs6000_emit_move (operands[0], operands[1], V4SFmode); DONE; }")
147 (define_insn "*movv4sf_internal1"
148 [(set (match_operand:V4SF 0 "nonimmediate_operand" "=m,v,v,o,r,r")
149 (match_operand:V4SF 1 "input_operand" "v,m,v,r,o,r"))]
155 stw%U0 %1,%0\;stw %L1,%L0\;stw %Y1,%Y0\;stw %Z1,%Z0
156 lwz%U1 %0,%1\;lwz %L0,%L1\;lwz %Y0,%Y1\;lwz %Z0,%Z1
157 mr %0,%1\;mr %L0,%L1\;mr %Y0,%Y1\;mr %Z0,%Z1"
158 [(set_attr "type" "altivec")
159 (set_attr "length" "*,*,*,16,16,16")])
161 (define_insn "get_vrsave_internal"
162 [(set (match_operand:SI 0 "register_operand" "=r")
163 (unspec:SI [(reg:SI 109)] 214))]
168 return \"mfspr %0,256\";
170 return \"mfvrsave %0\";
172 [(set_attr "type" "altivec")])
174 (define_insn "*set_vrsave_internal"
175 [(match_parallel 0 "vrsave_operation"
177 (unspec_volatile:SI [(match_operand:SI 1 "register_operand" "r")
178 (reg:SI 109)] 30))])]
183 return \"mtspr 256,%1\";
185 return \"mtvrsave %1\";
187 [(set_attr "type" "altivec")])
190 (define_insn "*movv4si_const0"
191 [(set (match_operand:V4SI 0 "altivec_register_operand" "=v")
192 (match_operand:V4SI 1 "zero_constant" ""))]
195 [(set_attr "type" "vecsimple")])
197 (define_insn "*movv4sf_const0"
198 [(set (match_operand:V4SF 0 "altivec_register_operand" "=v")
199 (match_operand:V4SF 1 "zero_constant" ""))]
203 [(set_attr "type" "vecsimple")])
205 (define_insn "*movv8hi_const0"
206 [(set (match_operand:V8HI 0 "altivec_register_operand" "=v")
207 (match_operand:V8HI 1 "zero_constant" ""))]
210 [(set_attr "type" "vecsimple")])
212 (define_insn "*movv16qi_const0"
213 [(set (match_operand:V16QI 0 "altivec_register_operand" "=v")
214 (match_operand:V16QI 1 "zero_constant" ""))]
217 [(set_attr "type" "vecsimple")])
219 ;; Simple binary operations.
221 (define_insn "addv16qi3"
222 [(set (match_operand:V16QI 0 "register_operand" "=v")
223 (plus:V16QI (match_operand:V16QI 1 "register_operand" "v")
224 (match_operand:V16QI 2 "register_operand" "v")))]
227 [(set_attr "type" "vecsimple")])
229 (define_insn "addv8hi3"
230 [(set (match_operand:V8HI 0 "register_operand" "=v")
231 (plus:V8HI (match_operand:V8HI 1 "register_operand" "v")
232 (match_operand:V8HI 2 "register_operand" "v")))]
235 [(set_attr "type" "vecsimple")])
237 (define_insn "addv4si3"
238 [(set (match_operand:V4SI 0 "register_operand" "=v")
239 (plus:V4SI (match_operand:V4SI 1 "register_operand" "v")
240 (match_operand:V4SI 2 "register_operand" "v")))]
243 [(set_attr "type" "vecsimple")])
245 (define_insn "addv4sf3"
246 [(set (match_operand:V4SF 0 "register_operand" "=v")
247 (plus:V4SF (match_operand:V4SF 1 "register_operand" "v")
248 (match_operand:V4SF 2 "register_operand" "v")))]
251 [(set_attr "type" "vecfloat")])
253 (define_insn "altivec_vaddcuw"
254 [(set (match_operand:V4SI 0 "register_operand" "=v")
255 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
256 (match_operand:V4SI 2 "register_operand" "v")] 35))]
259 [(set_attr "type" "vecsimple")])
261 (define_insn "altivec_vaddubs"
262 [(set (match_operand:V16QI 0 "register_operand" "=v")
263 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
264 (match_operand:V16QI 2 "register_operand" "v")] 36))
265 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
268 [(set_attr "type" "vecsimple")])
270 (define_insn "altivec_vaddsbs"
271 [(set (match_operand:V16QI 0 "register_operand" "=v")
272 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
273 (match_operand:V16QI 2 "register_operand" "v")] 37))
274 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
277 [(set_attr "type" "vecsimple")])
279 (define_insn "altivec_vadduhs"
280 [(set (match_operand:V8HI 0 "register_operand" "=v")
281 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
282 (match_operand:V8HI 2 "register_operand" "v")] 38))
283 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
286 [(set_attr "type" "vecsimple")])
288 (define_insn "altivec_vaddshs"
289 [(set (match_operand:V8HI 0 "register_operand" "=v")
290 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
291 (match_operand:V8HI 2 "register_operand" "v")] 39))
292 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
295 [(set_attr "type" "vecsimple")])
297 (define_insn "altivec_vadduws"
298 [(set (match_operand:V4SI 0 "register_operand" "=v")
299 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
300 (match_operand:V4SI 2 "register_operand" "v")] 40))
301 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
304 [(set_attr "type" "vecsimple")])
306 (define_insn "altivec_vaddsws"
307 [(set (match_operand:V4SI 0 "register_operand" "=v")
308 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
309 (match_operand:V4SI 2 "register_operand" "v")] 41))
310 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
313 [(set_attr "type" "vecsimple")])
315 (define_insn "andv4si3"
316 [(set (match_operand:V4SI 0 "register_operand" "=v")
317 (and:V4SI (match_operand:V4SI 1 "register_operand" "v")
318 (match_operand:V4SI 2 "register_operand" "v")))]
321 [(set_attr "type" "vecsimple")])
323 (define_insn "altivec_vandc"
324 [(set (match_operand:V4SI 0 "register_operand" "=v")
325 (and:V4SI (match_operand:V4SI 1 "register_operand" "v")
326 (not:V4SI (match_operand:V4SI 2 "register_operand" "v"))))]
329 [(set_attr "type" "vecsimple")])
331 (define_insn "altivec_vavgub"
332 [(set (match_operand:V16QI 0 "register_operand" "=v")
333 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
334 (match_operand:V16QI 2 "register_operand" "v")] 44))]
337 [(set_attr "type" "vecsimple")])
339 (define_insn "altivec_vavgsb"
340 [(set (match_operand:V16QI 0 "register_operand" "=v")
341 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
342 (match_operand:V16QI 2 "register_operand" "v")] 45))]
345 [(set_attr "type" "vecsimple")])
347 (define_insn "altivec_vavguh"
348 [(set (match_operand:V8HI 0 "register_operand" "=v")
349 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
350 (match_operand:V8HI 2 "register_operand" "v")] 46))]
353 [(set_attr "type" "vecsimple")])
355 (define_insn "altivec_vavgsh"
356 [(set (match_operand:V8HI 0 "register_operand" "=v")
357 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
358 (match_operand:V8HI 2 "register_operand" "v")] 47))]
361 [(set_attr "type" "vecsimple")])
363 (define_insn "altivec_vavguw"
364 [(set (match_operand:V4SI 0 "register_operand" "=v")
365 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
366 (match_operand:V4SI 2 "register_operand" "v")] 48))]
369 [(set_attr "type" "vecsimple")])
371 (define_insn "altivec_vavgsw"
372 [(set (match_operand:V4SI 0 "register_operand" "=v")
373 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
374 (match_operand:V4SI 2 "register_operand" "v")] 49))]
377 [(set_attr "type" "vecsimple")])
379 (define_insn "altivec_vcmpbfp"
380 [(set (match_operand:V4SI 0 "register_operand" "=v")
381 (unspec:V4SI [(match_operand:V4SF 1 "register_operand" "v")
382 (match_operand:V4SF 2 "register_operand" "v")] 50))]
385 [(set_attr "type" "veccmp")])
387 (define_insn "altivec_vcmpequb"
388 [(set (match_operand:V16QI 0 "register_operand" "=v")
389 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
390 (match_operand:V16QI 2 "register_operand" "v")] 51))]
393 [(set_attr "type" "vecsimple")])
395 (define_insn "altivec_vcmpequh"
396 [(set (match_operand:V8HI 0 "register_operand" "=v")
397 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
398 (match_operand:V8HI 2 "register_operand" "v")] 52))]
401 [(set_attr "type" "vecsimple")])
403 (define_insn "altivec_vcmpequw"
404 [(set (match_operand:V4SI 0 "register_operand" "=v")
405 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
406 (match_operand:V4SI 2 "register_operand" "v")] 53))]
409 [(set_attr "type" "vecsimple")])
411 (define_insn "altivec_vcmpeqfp"
412 [(set (match_operand:V4SI 0 "register_operand" "=v")
413 (unspec:V4SI [(match_operand:V4SF 1 "register_operand" "v")
414 (match_operand:V4SF 2 "register_operand" "v")] 54))]
417 [(set_attr "type" "veccmp")])
419 (define_insn "altivec_vcmpgefp"
420 [(set (match_operand:V4SI 0 "register_operand" "=v")
421 (unspec:V4SI [(match_operand:V4SF 1 "register_operand" "v")
422 (match_operand:V4SF 2 "register_operand" "v")] 55))]
425 [(set_attr "type" "veccmp")])
427 (define_insn "altivec_vcmpgtub"
428 [(set (match_operand:V16QI 0 "register_operand" "=v")
429 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
430 (match_operand:V16QI 2 "register_operand" "v")] 56))]
433 [(set_attr "type" "vecsimple")])
435 (define_insn "altivec_vcmpgtsb"
436 [(set (match_operand:V16QI 0 "register_operand" "=v")
437 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
438 (match_operand:V16QI 2 "register_operand" "v")] 57))]
441 [(set_attr "type" "vecsimple")])
443 (define_insn "altivec_vcmpgtuh"
444 [(set (match_operand:V8HI 0 "register_operand" "=v")
445 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
446 (match_operand:V8HI 2 "register_operand" "v")] 58))]
449 [(set_attr "type" "vecsimple")])
451 (define_insn "altivec_vcmpgtsh"
452 [(set (match_operand:V8HI 0 "register_operand" "=v")
453 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
454 (match_operand:V8HI 2 "register_operand" "v")] 59))]
457 [(set_attr "type" "vecsimple")])
459 (define_insn "altivec_vcmpgtuw"
460 [(set (match_operand:V4SI 0 "register_operand" "=v")
461 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
462 (match_operand:V4SI 2 "register_operand" "v")] 60))]
465 [(set_attr "type" "vecsimple")])
467 (define_insn "altivec_vcmpgtsw"
468 [(set (match_operand:V4SI 0 "register_operand" "=v")
469 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
470 (match_operand:V4SI 2 "register_operand" "v")] 61))]
473 [(set_attr "type" "vecsimple")])
475 (define_insn "altivec_vcmpgtfp"
476 [(set (match_operand:V4SI 0 "register_operand" "=v")
477 (unspec:V4SI [(match_operand:V4SF 1 "register_operand" "v")
478 (match_operand:V4SF 2 "register_operand" "v")] 62))]
481 [(set_attr "type" "veccmp")])
483 ;; Fused multiply add
484 (define_insn "altivec_vmaddfp"
485 [(set (match_operand:V4SF 0 "register_operand" "=v")
486 (plus:V4SF (mult:V4SF (match_operand:V4SF 1 "register_operand" "v")
487 (match_operand:V4SF 2 "register_operand" "v"))
488 (match_operand:V4SF 3 "register_operand" "v")))]
490 "vmaddfp %0,%1,%2,%3"
491 [(set_attr "type" "vecfloat")])
493 ;; The unspec here is a vec splat of 0. We do multiply as a fused
494 ;; multiply-add with an add of a 0 vector.
496 (define_expand "mulv4sf3"
497 [(set (match_dup 3) (unspec:V4SF [(const_int 0)] 142))
498 (set (match_operand:V4SF 0 "register_operand" "=v")
499 (plus:V4SF (mult:V4SF (match_operand:V4SF 1 "register_operand" "v")
500 (match_operand:V4SF 2 "register_operand" "v"))
502 "TARGET_ALTIVEC && TARGET_FUSED_MADD"
504 { operands[3] = gen_reg_rtx (V4SFmode); }")
506 ;; Fused multiply subtract
507 (define_insn "altivec_vnmsubfp"
508 [(set (match_operand:V4SF 0 "register_operand" "=v")
509 (minus:V4SF (mult:V4SF (match_operand:V4SF 1 "register_operand" "v")
510 (match_operand:V4SF 2 "register_operand" "v"))
511 (match_operand:V4SF 3 "register_operand" "v")))]
513 "vnmsubfp %0,%1,%2,%3"
514 [(set_attr "type" "vecfloat")])
517 (define_insn "altivec_vmsumubm"
518 [(set (match_operand:V4SI 0 "register_operand" "=v")
519 (unspec:V4SI [(match_operand:V16QI 1 "register_operand" "v")
520 (match_operand:V16QI 2 "register_operand" "v")
521 (match_operand:V4SI 3 "register_operand" "v")] 65))]
523 "vmsumubm %0, %1, %2, %3"
524 [(set_attr "type" "veccomplex")])
526 (define_insn "altivec_vmsummbm"
527 [(set (match_operand:V4SI 0 "register_operand" "=v")
528 (unspec:V4SI [(match_operand:V16QI 1 "register_operand" "v")
529 (match_operand:V16QI 2 "register_operand" "v")
530 (match_operand:V4SI 3 "register_operand" "v")] 66))]
532 "vmsumubm %0, %1, %2, %3"
533 [(set_attr "type" "veccomplex")])
535 (define_insn "altivec_vmsumuhm"
536 [(set (match_operand:V4SI 0 "register_operand" "=v")
537 (unspec:V4SI [(match_operand:V8HI 1 "register_operand" "v")
538 (match_operand:V8HI 2 "register_operand" "v")
539 (match_operand:V4SI 3 "register_operand" "v")] 67))]
541 "vmsumuhm %0, %1, %2, %3"
542 [(set_attr "type" "veccomplex")])
544 (define_insn "altivec_vmsumshm"
545 [(set (match_operand:V4SI 0 "register_operand" "=v")
546 (unspec:V4SI [(match_operand:V8HI 1 "register_operand" "v")
547 (match_operand:V8HI 2 "register_operand" "v")
548 (match_operand:V4SI 3 "register_operand" "v")] 68))]
550 "vmsumshm %0, %1, %2, %3"
551 [(set_attr "type" "veccomplex")])
553 (define_insn "altivec_vmsumuhs"
554 [(set (match_operand:V4SI 0 "register_operand" "=v")
555 (unspec:V4SI [(match_operand:V8HI 1 "register_operand" "v")
556 (match_operand:V8HI 2 "register_operand" "v")
557 (match_operand:V4SI 3 "register_operand" "v")] 69))
558 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
560 "vmsumuhs %0, %1, %2, %3"
561 [(set_attr "type" "veccomplex")])
563 (define_insn "altivec_vmsumshs"
564 [(set (match_operand:V4SI 0 "register_operand" "=v")
565 (unspec:V4SI [(match_operand:V8HI 1 "register_operand" "v")
566 (match_operand:V8HI 2 "register_operand" "v")
567 (match_operand:V4SI 3 "register_operand" "v")] 70))
568 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
570 "vmsumshs %0, %1, %2, %3"
571 [(set_attr "type" "veccomplex")])
573 (define_insn "umaxv16qi3"
574 [(set (match_operand:V16QI 0 "register_operand" "=v")
575 (umax:V16QI (match_operand:V16QI 1 "register_operand" "v")
576 (match_operand:V16QI 2 "register_operand" "v")))]
579 [(set_attr "type" "vecsimple")])
581 (define_insn "smaxv16qi3"
582 [(set (match_operand:V16QI 0 "register_operand" "=v")
583 (smax:V16QI (match_operand:V16QI 1 "register_operand" "v")
584 (match_operand:V16QI 2 "register_operand" "v")))]
587 [(set_attr "type" "vecsimple")])
589 (define_insn "umaxv8hi3"
590 [(set (match_operand:V8HI 0 "register_operand" "=v")
591 (umax:V8HI (match_operand:V8HI 1 "register_operand" "v")
592 (match_operand:V8HI 2 "register_operand" "v")))]
595 [(set_attr "type" "vecsimple")])
597 (define_insn "smaxv8hi3"
598 [(set (match_operand:V8HI 0 "register_operand" "=v")
599 (smax:V8HI (match_operand:V8HI 1 "register_operand" "v")
600 (match_operand:V8HI 2 "register_operand" "v")))]
603 [(set_attr "type" "vecsimple")])
605 (define_insn "umaxv4si3"
606 [(set (match_operand:V4SI 0 "register_operand" "=v")
607 (umax:V4SI (match_operand:V4SI 1 "register_operand" "v")
608 (match_operand:V4SI 2 "register_operand" "v")))]
611 [(set_attr "type" "vecsimple")])
613 (define_insn "smaxv4si3"
614 [(set (match_operand:V4SI 0 "register_operand" "=v")
615 (smax:V4SI (match_operand:V4SI 1 "register_operand" "v")
616 (match_operand:V4SI 2 "register_operand" "v")))]
619 [(set_attr "type" "vecsimple")])
621 (define_insn "smaxv4sf3"
622 [(set (match_operand:V4SF 0 "register_operand" "=v")
623 (smax:V4SF (match_operand:V4SF 1 "register_operand" "v")
624 (match_operand:V4SF 2 "register_operand" "v")))]
627 [(set_attr "type" "veccmp")])
629 (define_insn "altivec_vmhaddshs"
630 [(set (match_operand:V8HI 0 "register_operand" "=v")
631 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
632 (match_operand:V8HI 2 "register_operand" "v")
633 (match_operand:V8HI 3 "register_operand" "v")] 71))
634 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
636 "vmhaddshs %0, %1, %2, %3"
637 [(set_attr "type" "veccomplex")])
638 (define_insn "altivec_vmhraddshs"
639 [(set (match_operand:V8HI 0 "register_operand" "=v")
640 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
641 (match_operand:V8HI 2 "register_operand" "v")
642 (match_operand:V8HI 3 "register_operand" "v")] 72))
643 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
645 "vmhraddshs %0, %1, %2, %3"
646 [(set_attr "type" "veccomplex")])
647 (define_insn "altivec_vmladduhm"
648 [(set (match_operand:V8HI 0 "register_operand" "=v")
649 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
650 (match_operand:V8HI 2 "register_operand" "v")
651 (match_operand:V8HI 3 "register_operand" "v")] 73))]
653 "vmladduhm %0, %1, %2, %3"
654 [(set_attr "type" "veccomplex")])
656 (define_insn "altivec_vmrghb"
657 [(set (match_operand:V16QI 0 "register_operand" "=v")
658 (vec_merge:V16QI (vec_select:V16QI (match_operand:V16QI 1 "register_operand" "v")
659 (parallel [(const_int 8)
675 (match_operand:V16QI 2 "register_operand" "v")
679 [(set_attr "type" "vecperm")])
681 (define_insn "altivec_vmrghh"
682 [(set (match_operand:V8HI 0 "register_operand" "=v")
683 (vec_merge:V8HI (vec_select:V8HI (match_operand:V8HI 1 "register_operand" "v")
684 (parallel [(const_int 4)
692 (match_operand:V8HI 2 "register_operand" "v")
696 [(set_attr "type" "vecperm")])
698 (define_insn "altivec_vmrghw"
699 [(set (match_operand:V4SI 0 "register_operand" "=v")
700 (vec_merge:V4SI (vec_select:V4SI (match_operand:V4SI 1 "register_operand" "v")
701 (parallel [(const_int 2)
705 (match_operand:V4SI 2 "register_operand" "v")
709 [(set_attr "type" "vecperm")])
711 (define_insn "altivec_vmrglb"
712 [(set (match_operand:V16QI 0 "register_operand" "=v")
713 (vec_merge:V16QI (vec_select:V16QI (match_operand:V16QI 2 "register_operand" "v")
714 (parallel [(const_int 0)
730 (match_operand:V16QI 1 "register_operand" "v")
734 [(set_attr "type" "vecperm")])
736 (define_insn "altivec_vmrglh"
737 [(set (match_operand:V8HI 0 "register_operand" "=v")
738 (vec_merge:V8HI (vec_select:V8HI (match_operand:V8HI 2 "register_operand" "v")
739 (parallel [(const_int 0)
747 (match_operand:V8HI 1 "register_operand" "v")
751 [(set_attr "type" "vecperm")])
753 (define_insn "altivec_vmrglw"
754 [(set (match_operand:V4SI 0 "register_operand" "=v")
755 (vec_merge:V4SI (vec_select:V4SI (match_operand:V4SI 2 "register_operand" "v")
756 (parallel [(const_int 0)
760 (match_operand:V4SI 1 "register_operand" "v")
764 [(set_attr "type" "vecperm")])
766 (define_insn "uminv16qi3"
767 [(set (match_operand:V16QI 0 "register_operand" "=v")
768 (umin:V16QI (match_operand:V16QI 1 "register_operand" "v")
769 (match_operand:V16QI 2 "register_operand" "v")))]
772 [(set_attr "type" "vecsimple")])
774 (define_insn "sminv16qi3"
775 [(set (match_operand:V16QI 0 "register_operand" "=v")
776 (smin:V16QI (match_operand:V16QI 1 "register_operand" "v")
777 (match_operand:V16QI 2 "register_operand" "v")))]
780 [(set_attr "type" "vecsimple")])
782 (define_insn "uminv8hi3"
783 [(set (match_operand:V8HI 0 "register_operand" "=v")
784 (umin:V8HI (match_operand:V8HI 1 "register_operand" "v")
785 (match_operand:V8HI 2 "register_operand" "v")))]
788 [(set_attr "type" "vecsimple")])
790 (define_insn "sminv8hi3"
791 [(set (match_operand:V8HI 0 "register_operand" "=v")
792 (smin:V8HI (match_operand:V8HI 1 "register_operand" "v")
793 (match_operand:V8HI 2 "register_operand" "v")))]
796 [(set_attr "type" "vecsimple")])
798 (define_insn "uminv4si3"
799 [(set (match_operand:V4SI 0 "register_operand" "=v")
800 (umin:V4SI (match_operand:V4SI 1 "register_operand" "v")
801 (match_operand:V4SI 2 "register_operand" "v")))]
804 [(set_attr "type" "vecsimple")])
806 (define_insn "sminv4si3"
807 [(set (match_operand:V4SI 0 "register_operand" "=v")
808 (smin:V4SI (match_operand:V4SI 1 "register_operand" "v")
809 (match_operand:V4SI 2 "register_operand" "v")))]
812 [(set_attr "type" "vecsimple")])
814 (define_insn "sminv4sf3"
815 [(set (match_operand:V4SF 0 "register_operand" "=v")
816 (smin:V4SF (match_operand:V4SF 1 "register_operand" "v")
817 (match_operand:V4SF 2 "register_operand" "v")))]
820 [(set_attr "type" "veccmp")])
822 (define_insn "altivec_vmuleub"
823 [(set (match_operand:V8HI 0 "register_operand" "=v")
824 (unspec:V8HI [(match_operand:V16QI 1 "register_operand" "v")
825 (match_operand:V16QI 2 "register_operand" "v")] 83))]
828 [(set_attr "type" "veccomplex")])
830 (define_insn "altivec_vmulesb"
831 [(set (match_operand:V8HI 0 "register_operand" "=v")
832 (unspec:V8HI [(match_operand:V16QI 1 "register_operand" "v")
833 (match_operand:V16QI 2 "register_operand" "v")] 84))]
836 [(set_attr "type" "veccomplex")])
838 (define_insn "altivec_vmuleuh"
839 [(set (match_operand:V4SI 0 "register_operand" "=v")
840 (unspec:V4SI [(match_operand:V8HI 1 "register_operand" "v")
841 (match_operand:V8HI 2 "register_operand" "v")] 85))]
844 [(set_attr "type" "veccomplex")])
846 (define_insn "altivec_vmulesh"
847 [(set (match_operand:V4SI 0 "register_operand" "=v")
848 (unspec:V4SI [(match_operand:V8HI 1 "register_operand" "v")
849 (match_operand:V8HI 2 "register_operand" "v")] 86))]
852 [(set_attr "type" "veccomplex")])
854 (define_insn "altivec_vmuloub"
855 [(set (match_operand:V8HI 0 "register_operand" "=v")
856 (unspec:V8HI [(match_operand:V16QI 1 "register_operand" "v")
857 (match_operand:V16QI 2 "register_operand" "v")] 87))]
860 [(set_attr "type" "veccomplex")])
862 (define_insn "altivec_vmulosb"
863 [(set (match_operand:V8HI 0 "register_operand" "=v")
864 (unspec:V8HI [(match_operand:V16QI 1 "register_operand" "v")
865 (match_operand:V16QI 2 "register_operand" "v")] 88))]
868 [(set_attr "type" "veccomplex")])
870 (define_insn "altivec_vmulouh"
871 [(set (match_operand:V4SI 0 "register_operand" "=v")
872 (unspec:V4SI [(match_operand:V8HI 1 "register_operand" "v")
873 (match_operand:V8HI 2 "register_operand" "v")] 89))]
876 [(set_attr "type" "veccomplex")])
878 (define_insn "altivec_vmulosh"
879 [(set (match_operand:V4SI 0 "register_operand" "=v")
880 (unspec:V4SI [(match_operand:V8HI 1 "register_operand" "v")
881 (match_operand:V8HI 2 "register_operand" "v")] 90))]
884 [(set_attr "type" "veccomplex")])
886 (define_insn "altivec_vnor"
887 [(set (match_operand:V4SI 0 "register_operand" "=v")
888 (not:V4SI (ior:V4SI (match_operand:V4SI 1 "register_operand" "v")
889 (match_operand:V4SI 2 "register_operand" "v"))))]
892 [(set_attr "type" "vecsimple")])
894 (define_insn "iorv4si3"
895 [(set (match_operand:V4SI 0 "register_operand" "=v")
896 (ior:V4SI (match_operand:V4SI 1 "register_operand" "v")
897 (match_operand:V4SI 2 "register_operand" "v")))]
900 [(set_attr "type" "vecsimple")])
902 (define_insn "altivec_vpkuhum"
903 [(set (match_operand:V16QI 0 "register_operand" "=v")
904 (unspec:V16QI [(match_operand:V8HI 1 "register_operand" "v")
905 (match_operand:V8HI 2 "register_operand" "v")] 93))]
908 [(set_attr "type" "vecperm")])
910 (define_insn "altivec_vpkuwum"
911 [(set (match_operand:V8HI 0 "register_operand" "=v")
912 (unspec:V8HI [(match_operand:V4SI 1 "register_operand" "v")
913 (match_operand:V4SI 2 "register_operand" "v")] 94))]
916 [(set_attr "type" "vecperm")])
918 (define_insn "altivec_vpkpx"
919 [(set (match_operand:V8HI 0 "register_operand" "=v")
920 (unspec:V8HI [(match_operand:V4SI 1 "register_operand" "v")
921 (match_operand:V4SI 2 "register_operand" "v")] 95))]
924 [(set_attr "type" "vecperm")])
926 (define_insn "altivec_vpkuhss"
927 [(set (match_operand:V16QI 0 "register_operand" "=v")
928 (unspec:V16QI [(match_operand:V8HI 1 "register_operand" "v")
929 (match_operand:V8HI 2 "register_operand" "v")] 96))
930 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
933 [(set_attr "type" "vecperm")])
935 (define_insn "altivec_vpkshss"
936 [(set (match_operand:V16QI 0 "register_operand" "=v")
937 (unspec:V16QI [(match_operand:V8HI 1 "register_operand" "v")
938 (match_operand:V8HI 2 "register_operand" "v")] 97))
939 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
942 [(set_attr "type" "vecperm")])
944 (define_insn "altivec_vpkuwss"
945 [(set (match_operand:V8HI 0 "register_operand" "=v")
946 (unspec:V8HI [(match_operand:V4SI 1 "register_operand" "v")
947 (match_operand:V4SI 2 "register_operand" "v")] 98))
948 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
951 [(set_attr "type" "vecperm")])
953 (define_insn "altivec_vpkswss"
954 [(set (match_operand:V8HI 0 "register_operand" "=v")
955 (unspec:V8HI [(match_operand:V4SI 1 "register_operand" "v")
956 (match_operand:V4SI 2 "register_operand" "v")] 99))
957 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
960 [(set_attr "type" "vecperm")])
962 (define_insn "altivec_vpkuhus"
963 [(set (match_operand:V16QI 0 "register_operand" "=v")
964 (unspec:V16QI [(match_operand:V8HI 1 "register_operand" "v")
965 (match_operand:V8HI 2 "register_operand" "v")] 100))
966 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
969 [(set_attr "type" "vecperm")])
971 (define_insn "altivec_vpkshus"
972 [(set (match_operand:V16QI 0 "register_operand" "=v")
973 (unspec:V16QI [(match_operand:V8HI 1 "register_operand" "v")
974 (match_operand:V8HI 2 "register_operand" "v")] 101))
975 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
978 [(set_attr "type" "vecperm")])
980 (define_insn "altivec_vpkuwus"
981 [(set (match_operand:V8HI 0 "register_operand" "=v")
982 (unspec:V8HI [(match_operand:V4SI 1 "register_operand" "v")
983 (match_operand:V4SI 2 "register_operand" "v")] 102))
984 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
987 [(set_attr "type" "vecperm")])
989 (define_insn "altivec_vpkswus"
990 [(set (match_operand:V8HI 0 "register_operand" "=v")
991 (unspec:V8HI [(match_operand:V4SI 1 "register_operand" "v")
992 (match_operand:V4SI 2 "register_operand" "v")] 103))
993 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
996 [(set_attr "type" "vecperm")])
998 (define_insn "altivec_vrlb"
999 [(set (match_operand:V16QI 0 "register_operand" "=v")
1000 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
1001 (match_operand:V16QI 2 "register_operand" "v")] 104))]
1004 [(set_attr "type" "vecsimple")])
1006 (define_insn "altivec_vrlh"
1007 [(set (match_operand:V8HI 0 "register_operand" "=v")
1008 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
1009 (match_operand:V8HI 2 "register_operand" "v")] 105))]
1012 [(set_attr "type" "vecsimple")])
1014 (define_insn "altivec_vrlw"
1015 [(set (match_operand:V4SI 0 "register_operand" "=v")
1016 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1017 (match_operand:V4SI 2 "register_operand" "v")] 106))]
1020 [(set_attr "type" "vecsimple")])
1022 (define_insn "altivec_vslb"
1023 [(set (match_operand:V16QI 0 "register_operand" "=v")
1024 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
1025 (match_operand:V16QI 2 "register_operand" "v")] 107))]
1028 [(set_attr "type" "vecsimple")])
1030 (define_insn "altivec_vslh"
1031 [(set (match_operand:V8HI 0 "register_operand" "=v")
1032 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
1033 (match_operand:V8HI 2 "register_operand" "v")] 108))]
1036 [(set_attr "type" "vecsimple")])
1038 (define_insn "altivec_vslw"
1039 [(set (match_operand:V4SI 0 "register_operand" "=v")
1040 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1041 (match_operand:V4SI 2 "register_operand" "v")] 109))]
1044 [(set_attr "type" "vecsimple")])
1046 (define_insn "altivec_vsl"
1047 [(set (match_operand:V4SI 0 "register_operand" "=v")
1048 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1049 (match_operand:V4SI 2 "register_operand" "v")] 110))]
1052 [(set_attr "type" "vecperm")])
1054 (define_insn "altivec_vslo"
1055 [(set (match_operand:V4SI 0 "register_operand" "=v")
1056 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1057 (match_operand:V4SI 2 "register_operand" "v")] 111))]
1060 [(set_attr "type" "vecperm")])
1062 (define_insn "altivec_vsrb"
1063 [(set (match_operand:V16QI 0 "register_operand" "=v")
1064 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
1065 (match_operand:V16QI 2 "register_operand" "v")] 112))]
1068 [(set_attr "type" "vecsimple")])
1070 (define_insn "altivec_vsrh"
1071 [(set (match_operand:V8HI 0 "register_operand" "=v")
1072 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
1073 (match_operand:V8HI 2 "register_operand" "v")] 113))]
1076 [(set_attr "type" "vecsimple")])
1078 (define_insn "altivec_vsrw"
1079 [(set (match_operand:V4SI 0 "register_operand" "=v")
1080 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1081 (match_operand:V4SI 2 "register_operand" "v")] 114))]
1084 [(set_attr "type" "vecsimple")])
1086 (define_insn "altivec_vsrab"
1087 [(set (match_operand:V16QI 0 "register_operand" "=v")
1088 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
1089 (match_operand:V16QI 2 "register_operand" "v")] 115))]
1092 [(set_attr "type" "vecsimple")])
1094 (define_insn "altivec_vsrah"
1095 [(set (match_operand:V8HI 0 "register_operand" "=v")
1096 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
1097 (match_operand:V8HI 2 "register_operand" "v")] 116))]
1100 [(set_attr "type" "vecsimple")])
1102 (define_insn "altivec_vsraw"
1103 [(set (match_operand:V4SI 0 "register_operand" "=v")
1104 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1105 (match_operand:V4SI 2 "register_operand" "v")] 117))]
1108 [(set_attr "type" "vecsimple")])
1110 (define_insn "altivec_vsr"
1111 [(set (match_operand:V4SI 0 "register_operand" "=v")
1112 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1113 (match_operand:V4SI 2 "register_operand" "v")] 118))]
1116 [(set_attr "type" "vecperm")])
1118 (define_insn "altivec_vsro"
1119 [(set (match_operand:V4SI 0 "register_operand" "=v")
1120 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1121 (match_operand:V4SI 2 "register_operand" "v")] 119))]
1124 [(set_attr "type" "vecperm")])
1126 (define_insn "subv16qi3"
1127 [(set (match_operand:V16QI 0 "register_operand" "=v")
1128 (minus:V16QI (match_operand:V16QI 1 "register_operand" "v")
1129 (match_operand:V16QI 2 "register_operand" "v")))]
1132 [(set_attr "type" "vecsimple")])
1134 (define_insn "subv8hi3"
1135 [(set (match_operand:V8HI 0 "register_operand" "=v")
1136 (minus:V8HI (match_operand:V8HI 1 "register_operand" "v")
1137 (match_operand:V8HI 2 "register_operand" "v")))]
1140 [(set_attr "type" "vecsimple")])
1142 (define_insn "subv4si3"
1143 [(set (match_operand:V4SI 0 "register_operand" "=v")
1144 (minus:V4SI (match_operand:V4SI 1 "register_operand" "v")
1145 (match_operand:V4SI 2 "register_operand" "v")))]
1148 [(set_attr "type" "vecsimple")])
1150 (define_insn "subv4sf3"
1151 [(set (match_operand:V4SF 0 "register_operand" "=v")
1152 (minus:V4SF (match_operand:V4SF 1 "register_operand" "v")
1153 (match_operand:V4SF 2 "register_operand" "v")))]
1156 [(set_attr "type" "vecfloat")])
1158 (define_insn "altivec_vsubcuw"
1159 [(set (match_operand:V4SI 0 "register_operand" "=v")
1160 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1161 (match_operand:V4SI 2 "register_operand" "v")] 124))]
1164 [(set_attr "type" "vecsimple")])
1166 (define_insn "altivec_vsububs"
1167 [(set (match_operand:V16QI 0 "register_operand" "=v")
1168 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
1169 (match_operand:V16QI 2 "register_operand" "v")] 125))
1170 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
1173 [(set_attr "type" "vecsimple")])
1175 (define_insn "altivec_vsubsbs"
1176 [(set (match_operand:V16QI 0 "register_operand" "=v")
1177 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
1178 (match_operand:V16QI 2 "register_operand" "v")] 126))
1179 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
1182 [(set_attr "type" "vecsimple")])
1184 (define_insn "altivec_vsubuhs"
1185 [(set (match_operand:V8HI 0 "register_operand" "=v")
1186 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
1187 (match_operand:V8HI 2 "register_operand" "v")] 127))
1188 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
1191 [(set_attr "type" "vecsimple")])
1193 (define_insn "altivec_vsubshs"
1194 [(set (match_operand:V8HI 0 "register_operand" "=v")
1195 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
1196 (match_operand:V8HI 2 "register_operand" "v")] 128))
1197 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
1200 [(set_attr "type" "vecsimple")])
1202 (define_insn "altivec_vsubuws"
1203 [(set (match_operand:V4SI 0 "register_operand" "=v")
1204 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1205 (match_operand:V4SI 2 "register_operand" "v")] 129))
1206 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
1209 [(set_attr "type" "vecsimple")])
1211 (define_insn "altivec_vsubsws"
1212 [(set (match_operand:V4SI 0 "register_operand" "=v")
1213 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1214 (match_operand:V4SI 2 "register_operand" "v")] 130))
1215 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
1218 [(set_attr "type" "vecsimple")])
1220 (define_insn "altivec_vsum4ubs"
1221 [(set (match_operand:V4SI 0 "register_operand" "=v")
1222 (unspec:V4SI [(match_operand:V16QI 1 "register_operand" "v")
1223 (match_operand:V4SI 2 "register_operand" "v")] 131))
1224 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
1227 [(set_attr "type" "veccomplex")])
1229 (define_insn "altivec_vsum4sbs"
1230 [(set (match_operand:V4SI 0 "register_operand" "=v")
1231 (unspec:V4SI [(match_operand:V16QI 1 "register_operand" "v")
1232 (match_operand:V4SI 2 "register_operand" "v")] 132))
1233 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
1236 [(set_attr "type" "veccomplex")])
1238 (define_insn "altivec_vsum4shs"
1239 [(set (match_operand:V4SI 0 "register_operand" "=v")
1240 (unspec:V4SI [(match_operand:V8HI 1 "register_operand" "v")
1241 (match_operand:V4SI 2 "register_operand" "v")] 133))
1242 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
1245 [(set_attr "type" "veccomplex")])
1247 (define_insn "altivec_vsum2sws"
1248 [(set (match_operand:V4SI 0 "register_operand" "=v")
1249 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1250 (match_operand:V4SI 2 "register_operand" "v")] 134))
1251 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
1254 [(set_attr "type" "veccomplex")])
1256 (define_insn "altivec_vsumsws"
1257 [(set (match_operand:V4SI 0 "register_operand" "=v")
1258 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1259 (match_operand:V4SI 2 "register_operand" "v")] 135))
1260 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
1263 [(set_attr "type" "veccomplex")])
1265 (define_insn "xorv4si3"
1266 [(set (match_operand:V4SI 0 "register_operand" "=v")
1267 (xor:V4SI (match_operand:V4SI 1 "register_operand" "v")
1268 (match_operand:V4SI 2 "register_operand" "v")))]
1271 [(set_attr "type" "vecsimple")])
1273 (define_insn "altivec_vspltb"
1274 [(set (match_operand:V16QI 0 "register_operand" "=v")
1275 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
1276 (match_operand:QI 2 "immediate_operand" "i")] 136))]
1279 [(set_attr "type" "vecperm")])
1281 (define_insn "altivec_vsplth"
1282 [(set (match_operand:V8HI 0 "register_operand" "=v")
1283 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
1284 (match_operand:QI 2 "immediate_operand" "i")] 137))]
1287 [(set_attr "type" "vecperm")])
1289 (define_insn "altivec_vspltw"
1290 [(set (match_operand:V4SI 0 "register_operand" "=v")
1291 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1292 (match_operand:QI 2 "immediate_operand" "i")] 138))]
1295 [(set_attr "type" "vecperm")])
1297 (define_insn "altivec_vspltisb"
1298 [(set (match_operand:V16QI 0 "register_operand" "=v")
1299 (unspec:V16QI [(match_operand:QI 1 "immediate_operand" "i")] 139))]
1302 [(set_attr "type" "vecsimple")])
1305 (define_insn "altivec_vspltish"
1306 [(set (match_operand:V8HI 0 "register_operand" "=v")
1307 (unspec:V8HI [(match_operand:QI 1 "immediate_operand" "i")] 140))]
1310 [(set_attr "type" "vecsimple")])
1312 (define_insn "altivec_vspltisw"
1313 [(set (match_operand:V4SI 0 "register_operand" "=v")
1314 (unspec:V4SI [(match_operand:QI 1 "immediate_operand" "i")] 141))]
1317 [(set_attr "type" "vecsimple")])
1320 [(set (match_operand:V4SF 0 "register_operand" "=v")
1321 (unspec:V4SF [(match_operand:QI 1 "immediate_operand" "i")] 142))]
1324 [(set_attr "type" "vecsimple")])
1326 (define_insn "ftruncv4sf2"
1327 [(set (match_operand:V4SF 0 "register_operand" "=v")
1328 (fix:V4SF (match_operand:V4SF 1 "register_operand" "v")))]
1331 [(set_attr "type" "vecfloat")])
1333 (define_insn "altivec_vperm_4si"
1334 [(set (match_operand:V4SI 0 "register_operand" "=v")
1335 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1336 (match_operand:V4SI 2 "register_operand" "v")
1337 (match_operand:V16QI 3 "register_operand" "v")] 144))]
1340 [(set_attr "type" "vecperm")])
1342 (define_insn "altivec_vperm_4sf"
1343 [(set (match_operand:V4SF 0 "register_operand" "=v")
1344 (unspec:V4SF [(match_operand:V4SF 1 "register_operand" "v")
1345 (match_operand:V4SF 2 "register_operand" "v")
1346 (match_operand:V16QI 3 "register_operand" "v")] 145))]
1349 [(set_attr "type" "vecperm")])
1351 (define_insn "altivec_vperm_8hi"
1352 [(set (match_operand:V8HI 0 "register_operand" "=v")
1353 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
1354 (match_operand:V8HI 2 "register_operand" "v")
1355 (match_operand:V16QI 3 "register_operand" "v")] 146))]
1358 [(set_attr "type" "vecperm")])
1360 (define_insn "altivec_vperm_16qi"
1361 [(set (match_operand:V16QI 0 "register_operand" "=v")
1362 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
1363 (match_operand:V16QI 2 "register_operand" "v")
1364 (match_operand:V16QI 3 "register_operand" "v")] 147))]
1367 [(set_attr "type" "vecperm")])
1369 (define_insn "altivec_vrfip"
1370 [(set (match_operand:V4SF 0 "register_operand" "=v")
1371 (unspec:V4SF [(match_operand:V4SF 1 "register_operand" "v")] 148))]
1374 [(set_attr "type" "vecfloat")])
1376 (define_insn "altivec_vrfin"
1377 [(set (match_operand:V4SF 0 "register_operand" "=v")
1378 (unspec:V4SF [(match_operand:V4SF 1 "register_operand" "v")] 149))]
1381 [(set_attr "type" "vecfloat")])
1383 (define_insn "altivec_vrfim"
1384 [(set (match_operand:V4SF 0 "register_operand" "=v")
1385 (unspec:V4SF [(match_operand:V4SF 1 "register_operand" "v")] 150))]
1388 [(set_attr "type" "vecfloat")])
1390 (define_insn "altivec_vcfux"
1391 [(set (match_operand:V4SF 0 "register_operand" "=v")
1392 (unspec:V4SF [(match_operand:V4SI 1 "register_operand" "v")
1393 (match_operand:QI 2 "immediate_operand" "i")] 151))]
1396 [(set_attr "type" "vecfloat")])
1398 (define_insn "altivec_vcfsx"
1399 [(set (match_operand:V4SF 0 "register_operand" "=v")
1400 (unspec:V4SF [(match_operand:V4SI 1 "register_operand" "v")
1401 (match_operand:QI 2 "immediate_operand" "i")] 152))]
1404 [(set_attr "type" "vecfloat")])
1406 (define_insn "altivec_vctuxs"
1407 [(set (match_operand:V4SI 0 "register_operand" "=v")
1408 (unspec:V4SI [(match_operand:V4SF 1 "register_operand" "v")
1409 (match_operand:QI 2 "immediate_operand" "i")] 153))
1410 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
1413 [(set_attr "type" "vecfloat")])
1415 (define_insn "altivec_vctsxs"
1416 [(set (match_operand:V4SI 0 "register_operand" "=v")
1417 (unspec:V4SI [(match_operand:V4SF 1 "register_operand" "v")
1418 (match_operand:QI 2 "immediate_operand" "i")] 154))
1419 (set (reg:SI 110) (unspec:SI [(const_int 0)] 213))]
1422 [(set_attr "type" "vecfloat")])
1424 (define_insn "altivec_vlogefp"
1425 [(set (match_operand:V4SF 0 "register_operand" "=v")
1426 (unspec:V4SF [(match_operand:V4SF 1 "register_operand" "v")] 155))]
1429 [(set_attr "type" "vecfloat")])
1431 (define_insn "altivec_vexptefp"
1432 [(set (match_operand:V4SF 0 "register_operand" "=v")
1433 (unspec:V4SF [(match_operand:V4SF 1 "register_operand" "v")] 156))]
1436 [(set_attr "type" "vecfloat")])
1438 (define_insn "altivec_vrsqrtefp"
1439 [(set (match_operand:V4SF 0 "register_operand" "=v")
1440 (unspec:V4SF [(match_operand:V4SF 1 "register_operand" "v")] 157))]
1443 [(set_attr "type" "vecfloat")])
1445 (define_insn "altivec_vrefp"
1446 [(set (match_operand:V4SF 0 "register_operand" "=v")
1447 (unspec:V4SF [(match_operand:V4SF 1 "register_operand" "v")] 158))]
1450 [(set_attr "type" "vecfloat")])
1452 (define_insn "altivec_vsel_4si"
1453 [(set (match_operand:V4SI 0 "register_operand" "=v")
1454 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1455 (match_operand:V4SI 2 "register_operand" "v")
1456 (match_operand:V4SI 3 "register_operand" "v")] 159))]
1459 [(set_attr "type" "vecperm")])
1461 (define_insn "altivec_vsel_4sf"
1462 [(set (match_operand:V4SF 0 "register_operand" "=v")
1463 (unspec:V4SF [(match_operand:V4SF 1 "register_operand" "v")
1464 (match_operand:V4SF 2 "register_operand" "v")
1465 (match_operand:V4SI 3 "register_operand" "v")] 160))]
1468 [(set_attr "type" "vecperm")])
1470 (define_insn "altivec_vsel_8hi"
1471 [(set (match_operand:V8HI 0 "register_operand" "=v")
1472 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
1473 (match_operand:V8HI 2 "register_operand" "v")
1474 (match_operand:V8HI 3 "register_operand" "v")] 161))]
1477 [(set_attr "type" "vecperm")])
1479 (define_insn "altivec_vsel_16qi"
1480 [(set (match_operand:V16QI 0 "register_operand" "=v")
1481 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
1482 (match_operand:V16QI 2 "register_operand" "v")
1483 (match_operand:V16QI 3 "register_operand" "v")] 162))]
1486 [(set_attr "type" "vecperm")])
1488 (define_insn "altivec_vsldoi_4si"
1489 [(set (match_operand:V4SI 0 "register_operand" "=v")
1490 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")
1491 (match_operand:V4SI 2 "register_operand" "v")
1492 (match_operand:QI 3 "immediate_operand" "i")] 163))]
1494 "vsldoi %0, %1, %2, %3"
1495 [(set_attr "type" "vecperm")])
1497 (define_insn "altivec_vsldoi_4sf"
1498 [(set (match_operand:V4SF 0 "register_operand" "=v")
1499 (unspec:V4SF [(match_operand:V4SF 1 "register_operand" "v")
1500 (match_operand:V4SF 2 "register_operand" "v")
1501 (match_operand:QI 3 "immediate_operand" "i")] 164))]
1503 "vsldoi %0, %1, %2, %3"
1504 [(set_attr "type" "vecperm")])
1506 (define_insn "altivec_vsldoi_8hi"
1507 [(set (match_operand:V8HI 0 "register_operand" "=v")
1508 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")
1509 (match_operand:V8HI 2 "register_operand" "v")
1510 (match_operand:QI 3 "immediate_operand" "i")] 165))]
1512 "vsldoi %0, %1, %2, %3"
1513 [(set_attr "type" "vecperm")])
1515 (define_insn "altivec_vsldoi_16qi"
1516 [(set (match_operand:V16QI 0 "register_operand" "=v")
1517 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")
1518 (match_operand:V16QI 2 "register_operand" "v")
1519 (match_operand:QI 3 "immediate_operand" "i")] 166))]
1521 "vsldoi %0, %1, %2, %3"
1522 [(set_attr "type" "vecperm")])
1524 (define_insn "altivec_vupkhsb"
1525 [(set (match_operand:V8HI 0 "register_operand" "=v")
1526 (unspec:V8HI [(match_operand:V16QI 1 "register_operand" "v")] 167))]
1529 [(set_attr "type" "vecperm")])
1531 (define_insn "altivec_vupkhpx"
1532 [(set (match_operand:V4SI 0 "register_operand" "=v")
1533 (unspec:V4SI [(match_operand:V8HI 1 "register_operand" "v")] 168))]
1536 [(set_attr "type" "vecperm")])
1538 (define_insn "altivec_vupkhsh"
1539 [(set (match_operand:V4SI 0 "register_operand" "=v")
1540 (unspec:V4SI [(match_operand:V8HI 1 "register_operand" "v")] 169))]
1543 [(set_attr "type" "vecperm")])
1545 (define_insn "altivec_vupklsb"
1546 [(set (match_operand:V8HI 0 "register_operand" "=v")
1547 (unspec:V8HI [(match_operand:V16QI 1 "register_operand" "v")] 170))]
1550 [(set_attr "type" "vecperm")])
1552 (define_insn "altivec_vupklpx"
1553 [(set (match_operand:V4SI 0 "register_operand" "=v")
1554 (unspec:V4SI [(match_operand:V8HI 1 "register_operand" "v")] 171))]
1557 [(set_attr "type" "vecperm")])
1559 (define_insn "altivec_vupklsh"
1560 [(set (match_operand:V4SI 0 "register_operand" "=v")
1561 (unspec:V4SI [(match_operand:V8HI 1 "register_operand" "v")] 172))]
1564 [(set_attr "type" "vecperm")])
1566 ;; AltiVec predicates.
1568 (define_expand "cr6_test_for_zero"
1569 [(set (match_operand:SI 0 "register_operand" "=r")
1575 (define_expand "cr6_test_for_zero_reverse"
1576 [(set (match_operand:SI 0 "register_operand" "=r")
1579 (set (match_dup 0) (minus:SI (const_int 1) (match_dup 0)))]
1583 (define_expand "cr6_test_for_lt"
1584 [(set (match_operand:SI 0 "register_operand" "=r")
1590 (define_expand "cr6_test_for_lt_reverse"
1591 [(set (match_operand:SI 0 "register_operand" "=r")
1594 (set (match_dup 0) (minus:SI (const_int 1) (match_dup 0)))]
1598 ;; We can get away with generating the opcode on the fly (%3 below)
1599 ;; because all the predicates have the same scheduling parameters.
1601 (define_insn "altivec_predicate_v4si"
1603 (unspec:CC [(match_operand:V4SI 1 "register_operand" "v")
1604 (match_operand:V4SI 2 "register_operand" "v")
1605 (match_operand 3 "any_operand" "")] 173))
1606 (clobber (match_scratch:V4SI 0 "=v"))]
1609 [(set_attr "type" "veccmp")])
1611 (define_insn "altivec_predicate_v4sf"
1613 (unspec:CC [(match_operand:V4SF 1 "register_operand" "v")
1614 (match_operand:V4SF 2 "register_operand" "v")
1615 (match_operand 3 "any_operand" "")] 174))
1616 (clobber (match_scratch:V4SF 0 "=v"))]
1619 [(set_attr "type" "veccmp")])
1621 (define_insn "altivec_predicate_v8hi"
1623 (unspec:CC [(match_operand:V8HI 1 "register_operand" "v")
1624 (match_operand:V8HI 2 "register_operand" "v")
1625 (match_operand 3 "any_operand" "")] 175))
1626 (clobber (match_scratch:V8HI 0 "=v"))]
1629 [(set_attr "type" "veccmp")])
1631 (define_insn "altivec_predicate_v16qi"
1633 (unspec:CC [(match_operand:V16QI 1 "register_operand" "v")
1634 (match_operand:V16QI 2 "register_operand" "v")
1635 (match_operand 3 "any_operand" "")] 175))
1636 (clobber (match_scratch:V16QI 0 "=v"))]
1639 [(set_attr "type" "veccmp")])
1641 (define_insn "altivec_mtvscr"
1644 [(match_operand:V4SI 0 "register_operand" "v")] 186))]
1647 [(set_attr "type" "vecsimple")])
1649 (define_insn "altivec_mfvscr"
1650 [(set (match_operand:V8HI 0 "register_operand" "=v")
1651 (unspec_volatile:V8HI [(reg:SI 110)] 187))]
1654 [(set_attr "type" "vecsimple")])
1656 (define_insn "altivec_dssall"
1657 [(unspec [(const_int 0)] 188)]
1660 [(set_attr "type" "vecsimple")])
1662 (define_insn "altivec_dss"
1663 [(unspec [(match_operand:QI 0 "immediate_operand" "i")] 189)]
1666 [(set_attr "type" "vecsimple")])
1668 (define_insn "altivec_dst"
1669 [(unspec [(match_operand:SI 0 "register_operand" "b")
1670 (match_operand:SI 1 "register_operand" "r")
1671 (match_operand:QI 2 "immediate_operand" "i")] 190)]
1674 [(set_attr "type" "vecsimple")])
1676 (define_insn "altivec_dstt"
1677 [(unspec [(match_operand:SI 0 "register_operand" "b")
1678 (match_operand:SI 1 "register_operand" "r")
1679 (match_operand:QI 2 "immediate_operand" "i")] 191)]
1682 [(set_attr "type" "vecsimple")])
1684 (define_insn "altivec_dstst"
1685 [(unspec [(match_operand:SI 0 "register_operand" "b")
1686 (match_operand:SI 1 "register_operand" "r")
1687 (match_operand:QI 2 "immediate_operand" "i")] 192)]
1690 [(set_attr "type" "vecsimple")])
1692 (define_insn "altivec_dststt"
1693 [(unspec [(match_operand:SI 0 "register_operand" "b")
1694 (match_operand:SI 1 "register_operand" "r")
1695 (match_operand:QI 2 "immediate_operand" "i")] 193)]
1698 [(set_attr "type" "vecsimple")])
1700 (define_insn "altivec_lvsl"
1701 [(set (match_operand:V16QI 0 "register_operand" "=v")
1702 (unspec:V16QI [(match_operand:SI 1 "register_operand" "b")
1703 (match_operand:SI 2 "register_operand" "r")] 194))]
1706 [(set_attr "type" "vecload")])
1708 (define_insn "altivec_lvsr"
1709 [(set (match_operand:V16QI 0 "register_operand" "=v")
1710 (unspec:V16QI [(match_operand:SI 1 "register_operand" "b")
1711 (match_operand:SI 2 "register_operand" "r")] 195))]
1714 [(set_attr "type" "vecload")])
1716 ;; Parallel some of the LVE* and STV*'s with unspecs because some have
1717 ;; identical rtl but different instructions-- and gcc gets confused.
1719 (define_insn "altivec_lvebx"
1721 [(set (match_operand:V16QI 0 "register_operand" "=v")
1722 (mem:V16QI (plus:SI (match_operand:SI 1 "register_operand" "b")
1723 (match_operand:SI 2 "register_operand" "r"))))
1724 (unspec [(const_int 0)] 196)])]
1727 [(set_attr "type" "vecload")])
1729 (define_insn "altivec_lvehx"
1731 [(set (match_operand:V8HI 0 "register_operand" "=v")
1733 (and:SI (plus:SI (match_operand:SI 1 "register_operand" "b")
1734 (match_operand:SI 2 "register_operand" "r"))
1736 (unspec [(const_int 0)] 197)])]
1739 [(set_attr "type" "vecload")])
1741 (define_insn "altivec_lvewx"
1743 [(set (match_operand:V4SI 0 "register_operand" "=v")
1745 (and:SI (plus:SI (match_operand:SI 1 "register_operand" "b")
1746 (match_operand:SI 2 "register_operand" "r"))
1748 (unspec [(const_int 0)] 198)])]
1751 [(set_attr "type" "vecload")])
1753 (define_insn "altivec_lvxl"
1755 [(set (match_operand:V4SI 0 "register_operand" "=v")
1756 (mem:V4SI (plus:SI (match_operand:SI 1 "register_operand" "b")
1757 (match_operand:SI 2 "register_operand" "r"))))
1758 (unspec [(const_int 0)] 213)])]
1761 [(set_attr "type" "vecload")])
1763 (define_insn "altivec_lvx"
1764 [(set (match_operand:V4SI 0 "register_operand" "=v")
1765 (mem:V4SI (plus:SI (match_operand:SI 1 "register_operand" "b")
1766 (match_operand:SI 2 "register_operand" "r"))))]
1769 [(set_attr "type" "vecload")])
1771 (define_insn "altivec_stvx"
1774 (and:SI (plus:SI (match_operand:SI 0 "register_operand" "b")
1775 (match_operand:SI 1 "register_operand" "r"))
1777 (match_operand:V4SI 2 "register_operand" "v"))
1778 (unspec [(const_int 0)] 201)])]
1781 [(set_attr "type" "vecstore")])
1783 (define_insn "altivec_stvxl"
1786 (and:SI (plus:SI (match_operand:SI 0 "register_operand" "b")
1787 (match_operand:SI 1 "register_operand" "r"))
1789 (match_operand:V4SI 2 "register_operand" "v"))
1790 (unspec [(const_int 0)] 202)])]
1793 [(set_attr "type" "vecstore")])
1795 (define_insn "altivec_stvebx"
1798 (plus:SI (match_operand:SI 0 "register_operand" "b")
1799 (match_operand:SI 1 "register_operand" "r")))
1800 (match_operand:V16QI 2 "register_operand" "v"))
1801 (unspec [(const_int 0)] 203)])]
1804 [(set_attr "type" "vecstore")])
1806 (define_insn "altivec_stvehx"
1809 (and:SI (plus:SI (match_operand:SI 0 "register_operand" "b")
1810 (match_operand:SI 1 "register_operand" "r"))
1812 (match_operand:V8HI 2 "register_operand" "v"))
1813 (unspec [(const_int 0)] 204)])]
1816 [(set_attr "type" "vecstore")])
1818 (define_insn "altivec_stvewx"
1821 (and:SI (plus:SI (match_operand:SI 0 "register_operand" "b")
1822 (match_operand:SI 1 "register_operand" "r"))
1824 (match_operand:V4SI 2 "register_operand" "v"))
1825 (unspec [(const_int 0)] 205)])]
1828 [(set_attr "type" "vecstore")])
1830 (define_insn "absv16qi2"
1831 [(set (match_operand:V16QI 0 "register_operand" "=v")
1832 (abs:V16QI (match_operand:V16QI 1 "register_operand" "v")))
1833 (clobber (match_scratch:V16QI 2 "=v"))
1834 (clobber (match_scratch:V16QI 3 "=v"))]
1836 "vspltisb %2,0\;vsububm %3,%2,%1\;vmaxsb %0,%1,%3"
1837 [(set_attr "type" "altivec")
1838 (set_attr "length" "12")])
1840 (define_insn "absv8hi2"
1841 [(set (match_operand:V8HI 0 "register_operand" "=v")
1842 (abs:V8HI (match_operand:V8HI 1 "register_operand" "v")))
1843 (clobber (match_scratch:V8HI 2 "=v"))
1844 (clobber (match_scratch:V8HI 3 "=v"))]
1846 "vspltisb %2,0\;vsubuhm %3,%2,%1\;vmaxsh %0,%1,%3"
1847 [(set_attr "type" "altivec")
1848 (set_attr "length" "12")])
1850 (define_insn "absv4si2"
1851 [(set (match_operand:V4SI 0 "register_operand" "=v")
1852 (abs:V4SI (match_operand:V4SI 1 "register_operand" "v")))
1853 (clobber (match_scratch:V4SI 2 "=v"))
1854 (clobber (match_scratch:V4SI 3 "=v"))]
1856 "vspltisb %2,0\;vsubuwm %3,%2,%1\;vmaxsw %0,%1,%3"
1857 [(set_attr "type" "altivec")
1858 (set_attr "length" "12")])
1860 (define_insn "absv4sf2"
1861 [(set (match_operand:V4SF 0 "register_operand" "=v")
1862 (abs:V4SF (match_operand:V4SF 1 "register_operand" "v")))
1863 (clobber (match_scratch:V4SF 2 "=v"))
1864 (clobber (match_scratch:V4SF 3 "=v"))]
1866 "vspltisw %2, -1\;vslw %3,%2,%2\;vandc %0,%1,%3"
1867 [(set_attr "type" "altivec")
1868 (set_attr "length" "12")])
1870 (define_insn "altivec_abss_v16qi"
1871 [(set (match_operand:V16QI 0 "register_operand" "=v")
1872 (unspec:V16QI [(match_operand:V16QI 1 "register_operand" "v")] 210))
1873 (clobber (match_scratch:V16QI 2 "=v"))
1874 (clobber (match_scratch:V16QI 3 "=v"))]
1876 "vspltisb %2,0\;vsubsbs %3,%2,%1\;vmaxsb %0,%1,%3"
1877 [(set_attr "type" "altivec")
1878 (set_attr "length" "12")])
1880 (define_insn "altivec_abss_v8hi"
1881 [(set (match_operand:V8HI 0 "register_operand" "=v")
1882 (unspec:V8HI [(match_operand:V8HI 1 "register_operand" "v")] 211))
1883 (clobber (match_scratch:V8HI 2 "=v"))
1884 (clobber (match_scratch:V8HI 3 "=v"))]
1886 "vspltisb %2,0\;vsubshs %3,%2,%1\;vmaxsh %0,%1,%3"
1887 [(set_attr "type" "altivec")
1888 (set_attr "length" "12")])
1890 (define_insn "altivec_abss_v4si"
1891 [(set (match_operand:V4SI 0 "register_operand" "=v")
1892 (unspec:V4SI [(match_operand:V4SI 1 "register_operand" "v")] 212))
1893 (clobber (match_scratch:V4SI 2 "=v"))
1894 (clobber (match_scratch:V4SI 3 "=v"))]
1896 "vspltisb %2,0\;vsubsws %3,%2,%1\;vmaxsw %0,%1,%3"
1897 [(set_attr "type" "altivec")
1898 (set_attr "length" "12")])