1/*===---- altivec.h - Standard header for type generic math ---------------===*\ 2 * 3 * Permission is hereby granted, free of charge, to any person obtaining a copy 4 * of this software and associated documentation files (the "Software"), to deal 5 * in the Software without restriction, including without limitation the rights 6 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 * copies of the Software, and to permit persons to whom the Software is 8 * furnished to do so, subject to the following conditions: 9 * 10 * The above copyright notice and this permission notice shall be included in 11 * all copies or substantial portions of the Software. 12 * 13 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 19 * THE SOFTWARE. 20 * 21\*===----------------------------------------------------------------------===*/ 22 23#ifndef __ALTIVEC_H 24#define __ALTIVEC_H 25 26#ifndef __ALTIVEC__ 27#error "AltiVec support not enabled" 28#endif 29 30/* constants for mapping CR6 bits to predicate result. */ 31 32#define __CR6_EQ 0 33#define __CR6_EQ_REV 1 34#define __CR6_LT 2 35#define __CR6_LT_REV 3 36 37#define __ATTRS_o_ai __attribute__((__overloadable__, __always_inline__)) 38 39static vector signed char __ATTRS_o_ai 40vec_perm(vector signed char __a, vector signed char __b, vector unsigned char __c); 41 42static vector unsigned char __ATTRS_o_ai 43vec_perm(vector unsigned char __a, 44 vector unsigned char __b, 45 vector unsigned char __c); 46 47static vector bool char __ATTRS_o_ai 48vec_perm(vector bool char __a, vector bool char __b, vector unsigned char __c); 49 50static vector short __ATTRS_o_ai 51vec_perm(vector short __a, vector short __b, vector unsigned char __c); 52 53static vector unsigned short __ATTRS_o_ai 54vec_perm(vector unsigned short __a, 55 vector unsigned short __b, 56 vector unsigned char __c); 57 58static vector bool short __ATTRS_o_ai 59vec_perm(vector bool short __a, vector bool short __b, vector unsigned char __c); 60 61static vector pixel __ATTRS_o_ai 62vec_perm(vector pixel __a, vector pixel __b, vector unsigned char __c); 63 64static vector int __ATTRS_o_ai 65vec_perm(vector int __a, vector int __b, vector unsigned char __c); 66 67static vector unsigned int __ATTRS_o_ai 68vec_perm(vector unsigned int __a, vector unsigned int __b, vector unsigned char __c); 69 70static vector bool int __ATTRS_o_ai 71vec_perm(vector bool int __a, vector bool int __b, vector unsigned char __c); 72 73static vector float __ATTRS_o_ai 74vec_perm(vector float __a, vector float __b, vector unsigned char __c); 75 76/* vec_abs */ 77 78#define __builtin_altivec_abs_v16qi vec_abs 79#define __builtin_altivec_abs_v8hi vec_abs 80#define __builtin_altivec_abs_v4si vec_abs 81 82static vector signed char __ATTRS_o_ai 83vec_abs(vector signed char __a) 84{ 85 return __builtin_altivec_vmaxsb(__a, -__a); 86} 87 88static vector signed short __ATTRS_o_ai 89vec_abs(vector signed short __a) 90{ 91 return __builtin_altivec_vmaxsh(__a, -__a); 92} 93 94static vector signed int __ATTRS_o_ai 95vec_abs(vector signed int __a) 96{ 97 return __builtin_altivec_vmaxsw(__a, -__a); 98} 99 100static vector float __ATTRS_o_ai 101vec_abs(vector float __a) 102{ 103 vector unsigned int __res = (vector unsigned int)__a 104 & (vector unsigned int)(0x7FFFFFFF); 105 return (vector float)__res; 106} 107 108/* vec_abss */ 109 110#define __builtin_altivec_abss_v16qi vec_abss 111#define __builtin_altivec_abss_v8hi vec_abss 112#define __builtin_altivec_abss_v4si vec_abss 113 114static vector signed char __ATTRS_o_ai 115vec_abss(vector signed char __a) 116{ 117 return __builtin_altivec_vmaxsb 118 (__a, __builtin_altivec_vsubsbs((vector signed char)(0), __a)); 119} 120 121static vector signed short __ATTRS_o_ai 122vec_abss(vector signed short __a) 123{ 124 return __builtin_altivec_vmaxsh 125 (__a, __builtin_altivec_vsubshs((vector signed short)(0), __a)); 126} 127 128static vector signed int __ATTRS_o_ai 129vec_abss(vector signed int __a) 130{ 131 return __builtin_altivec_vmaxsw 132 (__a, __builtin_altivec_vsubsws((vector signed int)(0), __a)); 133} 134 135/* vec_add */ 136 137static vector signed char __ATTRS_o_ai 138vec_add(vector signed char __a, vector signed char __b) 139{ 140 return __a + __b; 141} 142 143static vector signed char __ATTRS_o_ai 144vec_add(vector bool char __a, vector signed char __b) 145{ 146 return (vector signed char)__a + __b; 147} 148 149static vector signed char __ATTRS_o_ai 150vec_add(vector signed char __a, vector bool char __b) 151{ 152 return __a + (vector signed char)__b; 153} 154 155static vector unsigned char __ATTRS_o_ai 156vec_add(vector unsigned char __a, vector unsigned char __b) 157{ 158 return __a + __b; 159} 160 161static vector unsigned char __ATTRS_o_ai 162vec_add(vector bool char __a, vector unsigned char __b) 163{ 164 return (vector unsigned char)__a + __b; 165} 166 167static vector unsigned char __ATTRS_o_ai 168vec_add(vector unsigned char __a, vector bool char __b) 169{ 170 return __a + (vector unsigned char)__b; 171} 172 173static vector short __ATTRS_o_ai 174vec_add(vector short __a, vector short __b) 175{ 176 return __a + __b; 177} 178 179static vector short __ATTRS_o_ai 180vec_add(vector bool short __a, vector short __b) 181{ 182 return (vector short)__a + __b; 183} 184 185static vector short __ATTRS_o_ai 186vec_add(vector short __a, vector bool short __b) 187{ 188 return __a + (vector short)__b; 189} 190 191static vector unsigned short __ATTRS_o_ai 192vec_add(vector unsigned short __a, vector unsigned short __b) 193{ 194 return __a + __b; 195} 196 197static vector unsigned short __ATTRS_o_ai 198vec_add(vector bool short __a, vector unsigned short __b) 199{ 200 return (vector unsigned short)__a + __b; 201} 202 203static vector unsigned short __ATTRS_o_ai 204vec_add(vector unsigned short __a, vector bool short __b) 205{ 206 return __a + (vector unsigned short)__b; 207} 208 209static vector int __ATTRS_o_ai 210vec_add(vector int __a, vector int __b) 211{ 212 return __a + __b; 213} 214 215static vector int __ATTRS_o_ai 216vec_add(vector bool int __a, vector int __b) 217{ 218 return (vector int)__a + __b; 219} 220 221static vector int __ATTRS_o_ai 222vec_add(vector int __a, vector bool int __b) 223{ 224 return __a + (vector int)__b; 225} 226 227static vector unsigned int __ATTRS_o_ai 228vec_add(vector unsigned int __a, vector unsigned int __b) 229{ 230 return __a + __b; 231} 232 233static vector unsigned int __ATTRS_o_ai 234vec_add(vector bool int __a, vector unsigned int __b) 235{ 236 return (vector unsigned int)__a + __b; 237} 238 239static vector unsigned int __ATTRS_o_ai 240vec_add(vector unsigned int __a, vector bool int __b) 241{ 242 return __a + (vector unsigned int)__b; 243} 244 245static vector float __ATTRS_o_ai 246vec_add(vector float __a, vector float __b) 247{ 248 return __a + __b; 249} 250 251/* vec_vaddubm */ 252 253#define __builtin_altivec_vaddubm vec_vaddubm 254 255static vector signed char __ATTRS_o_ai 256vec_vaddubm(vector signed char __a, vector signed char __b) 257{ 258 return __a + __b; 259} 260 261static vector signed char __ATTRS_o_ai 262vec_vaddubm(vector bool char __a, vector signed char __b) 263{ 264 return (vector signed char)__a + __b; 265} 266 267static vector signed char __ATTRS_o_ai 268vec_vaddubm(vector signed char __a, vector bool char __b) 269{ 270 return __a + (vector signed char)__b; 271} 272 273static vector unsigned char __ATTRS_o_ai 274vec_vaddubm(vector unsigned char __a, vector unsigned char __b) 275{ 276 return __a + __b; 277} 278 279static vector unsigned char __ATTRS_o_ai 280vec_vaddubm(vector bool char __a, vector unsigned char __b) 281{ 282 return (vector unsigned char)__a + __b; 283} 284 285static vector unsigned char __ATTRS_o_ai 286vec_vaddubm(vector unsigned char __a, vector bool char __b) 287{ 288 return __a + (vector unsigned char)__b; 289} 290 291/* vec_vadduhm */ 292 293#define __builtin_altivec_vadduhm vec_vadduhm 294 295static vector short __ATTRS_o_ai 296vec_vadduhm(vector short __a, vector short __b) 297{ 298 return __a + __b; 299} 300 301static vector short __ATTRS_o_ai 302vec_vadduhm(vector bool short __a, vector short __b) 303{ 304 return (vector short)__a + __b; 305} 306 307static vector short __ATTRS_o_ai 308vec_vadduhm(vector short __a, vector bool short __b) 309{ 310 return __a + (vector short)__b; 311} 312 313static vector unsigned short __ATTRS_o_ai 314vec_vadduhm(vector unsigned short __a, vector unsigned short __b) 315{ 316 return __a + __b; 317} 318 319static vector unsigned short __ATTRS_o_ai 320vec_vadduhm(vector bool short __a, vector unsigned short __b) 321{ 322 return (vector unsigned short)__a + __b; 323} 324 325static vector unsigned short __ATTRS_o_ai 326vec_vadduhm(vector unsigned short __a, vector bool short __b) 327{ 328 return __a + (vector unsigned short)__b; 329} 330 331/* vec_vadduwm */ 332 333#define __builtin_altivec_vadduwm vec_vadduwm 334 335static vector int __ATTRS_o_ai 336vec_vadduwm(vector int __a, vector int __b) 337{ 338 return __a + __b; 339} 340 341static vector int __ATTRS_o_ai 342vec_vadduwm(vector bool int __a, vector int __b) 343{ 344 return (vector int)__a + __b; 345} 346 347static vector int __ATTRS_o_ai 348vec_vadduwm(vector int __a, vector bool int __b) 349{ 350 return __a + (vector int)__b; 351} 352 353static vector unsigned int __ATTRS_o_ai 354vec_vadduwm(vector unsigned int __a, vector unsigned int __b) 355{ 356 return __a + __b; 357} 358 359static vector unsigned int __ATTRS_o_ai 360vec_vadduwm(vector bool int __a, vector unsigned int __b) 361{ 362 return (vector unsigned int)__a + __b; 363} 364 365static vector unsigned int __ATTRS_o_ai 366vec_vadduwm(vector unsigned int __a, vector bool int __b) 367{ 368 return __a + (vector unsigned int)__b; 369} 370 371/* vec_vaddfp */ 372 373#define __builtin_altivec_vaddfp vec_vaddfp 374 375static vector float __attribute__((__always_inline__)) 376vec_vaddfp(vector float __a, vector float __b) 377{ 378 return __a + __b; 379} 380 381/* vec_addc */ 382 383static vector unsigned int __attribute__((__always_inline__)) 384vec_addc(vector unsigned int __a, vector unsigned int __b) 385{ 386 return __builtin_altivec_vaddcuw(__a, __b); 387} 388 389/* vec_vaddcuw */ 390 391static vector unsigned int __attribute__((__always_inline__)) 392vec_vaddcuw(vector unsigned int __a, vector unsigned int __b) 393{ 394 return __builtin_altivec_vaddcuw(__a, __b); 395} 396 397/* vec_adds */ 398 399static vector signed char __ATTRS_o_ai 400vec_adds(vector signed char __a, vector signed char __b) 401{ 402 return __builtin_altivec_vaddsbs(__a, __b); 403} 404 405static vector signed char __ATTRS_o_ai 406vec_adds(vector bool char __a, vector signed char __b) 407{ 408 return __builtin_altivec_vaddsbs((vector signed char)__a, __b); 409} 410 411static vector signed char __ATTRS_o_ai 412vec_adds(vector signed char __a, vector bool char __b) 413{ 414 return __builtin_altivec_vaddsbs(__a, (vector signed char)__b); 415} 416 417static vector unsigned char __ATTRS_o_ai 418vec_adds(vector unsigned char __a, vector unsigned char __b) 419{ 420 return __builtin_altivec_vaddubs(__a, __b); 421} 422 423static vector unsigned char __ATTRS_o_ai 424vec_adds(vector bool char __a, vector unsigned char __b) 425{ 426 return __builtin_altivec_vaddubs((vector unsigned char)__a, __b); 427} 428 429static vector unsigned char __ATTRS_o_ai 430vec_adds(vector unsigned char __a, vector bool char __b) 431{ 432 return __builtin_altivec_vaddubs(__a, (vector unsigned char)__b); 433} 434 435static vector short __ATTRS_o_ai 436vec_adds(vector short __a, vector short __b) 437{ 438 return __builtin_altivec_vaddshs(__a, __b); 439} 440 441static vector short __ATTRS_o_ai 442vec_adds(vector bool short __a, vector short __b) 443{ 444 return __builtin_altivec_vaddshs((vector short)__a, __b); 445} 446 447static vector short __ATTRS_o_ai 448vec_adds(vector short __a, vector bool short __b) 449{ 450 return __builtin_altivec_vaddshs(__a, (vector short)__b); 451} 452 453static vector unsigned short __ATTRS_o_ai 454vec_adds(vector unsigned short __a, vector unsigned short __b) 455{ 456 return __builtin_altivec_vadduhs(__a, __b); 457} 458 459static vector unsigned short __ATTRS_o_ai 460vec_adds(vector bool short __a, vector unsigned short __b) 461{ 462 return __builtin_altivec_vadduhs((vector unsigned short)__a, __b); 463} 464 465static vector unsigned short __ATTRS_o_ai 466vec_adds(vector unsigned short __a, vector bool short __b) 467{ 468 return __builtin_altivec_vadduhs(__a, (vector unsigned short)__b); 469} 470 471static vector int __ATTRS_o_ai 472vec_adds(vector int __a, vector int __b) 473{ 474 return __builtin_altivec_vaddsws(__a, __b); 475} 476 477static vector int __ATTRS_o_ai 478vec_adds(vector bool int __a, vector int __b) 479{ 480 return __builtin_altivec_vaddsws((vector int)__a, __b); 481} 482 483static vector int __ATTRS_o_ai 484vec_adds(vector int __a, vector bool int __b) 485{ 486 return __builtin_altivec_vaddsws(__a, (vector int)__b); 487} 488 489static vector unsigned int __ATTRS_o_ai 490vec_adds(vector unsigned int __a, vector unsigned int __b) 491{ 492 return __builtin_altivec_vadduws(__a, __b); 493} 494 495static vector unsigned int __ATTRS_o_ai 496vec_adds(vector bool int __a, vector unsigned int __b) 497{ 498 return __builtin_altivec_vadduws((vector unsigned int)__a, __b); 499} 500 501static vector unsigned int __ATTRS_o_ai 502vec_adds(vector unsigned int __a, vector bool int __b) 503{ 504 return __builtin_altivec_vadduws(__a, (vector unsigned int)__b); 505} 506 507/* vec_vaddsbs */ 508 509static vector signed char __ATTRS_o_ai 510vec_vaddsbs(vector signed char __a, vector signed char __b) 511{ 512 return __builtin_altivec_vaddsbs(__a, __b); 513} 514 515static vector signed char __ATTRS_o_ai 516vec_vaddsbs(vector bool char __a, vector signed char __b) 517{ 518 return __builtin_altivec_vaddsbs((vector signed char)__a, __b); 519} 520 521static vector signed char __ATTRS_o_ai 522vec_vaddsbs(vector signed char __a, vector bool char __b) 523{ 524 return __builtin_altivec_vaddsbs(__a, (vector signed char)__b); 525} 526 527/* vec_vaddubs */ 528 529static vector unsigned char __ATTRS_o_ai 530vec_vaddubs(vector unsigned char __a, vector unsigned char __b) 531{ 532 return __builtin_altivec_vaddubs(__a, __b); 533} 534 535static vector unsigned char __ATTRS_o_ai 536vec_vaddubs(vector bool char __a, vector unsigned char __b) 537{ 538 return __builtin_altivec_vaddubs((vector unsigned char)__a, __b); 539} 540 541static vector unsigned char __ATTRS_o_ai 542vec_vaddubs(vector unsigned char __a, vector bool char __b) 543{ 544 return __builtin_altivec_vaddubs(__a, (vector unsigned char)__b); 545} 546 547/* vec_vaddshs */ 548 549static vector short __ATTRS_o_ai 550vec_vaddshs(vector short __a, vector short __b) 551{ 552 return __builtin_altivec_vaddshs(__a, __b); 553} 554 555static vector short __ATTRS_o_ai 556vec_vaddshs(vector bool short __a, vector short __b) 557{ 558 return __builtin_altivec_vaddshs((vector short)__a, __b); 559} 560 561static vector short __ATTRS_o_ai 562vec_vaddshs(vector short __a, vector bool short __b) 563{ 564 return __builtin_altivec_vaddshs(__a, (vector short)__b); 565} 566 567/* vec_vadduhs */ 568 569static vector unsigned short __ATTRS_o_ai 570vec_vadduhs(vector unsigned short __a, vector unsigned short __b) 571{ 572 return __builtin_altivec_vadduhs(__a, __b); 573} 574 575static vector unsigned short __ATTRS_o_ai 576vec_vadduhs(vector bool short __a, vector unsigned short __b) 577{ 578 return __builtin_altivec_vadduhs((vector unsigned short)__a, __b); 579} 580 581static vector unsigned short __ATTRS_o_ai 582vec_vadduhs(vector unsigned short __a, vector bool short __b) 583{ 584 return __builtin_altivec_vadduhs(__a, (vector unsigned short)__b); 585} 586 587/* vec_vaddsws */ 588 589static vector int __ATTRS_o_ai 590vec_vaddsws(vector int __a, vector int __b) 591{ 592 return __builtin_altivec_vaddsws(__a, __b); 593} 594 595static vector int __ATTRS_o_ai 596vec_vaddsws(vector bool int __a, vector int __b) 597{ 598 return __builtin_altivec_vaddsws((vector int)__a, __b); 599} 600 601static vector int __ATTRS_o_ai 602vec_vaddsws(vector int __a, vector bool int __b) 603{ 604 return __builtin_altivec_vaddsws(__a, (vector int)__b); 605} 606 607/* vec_vadduws */ 608 609static vector unsigned int __ATTRS_o_ai 610vec_vadduws(vector unsigned int __a, vector unsigned int __b) 611{ 612 return __builtin_altivec_vadduws(__a, __b); 613} 614 615static vector unsigned int __ATTRS_o_ai 616vec_vadduws(vector bool int __a, vector unsigned int __b) 617{ 618 return __builtin_altivec_vadduws((vector unsigned int)__a, __b); 619} 620 621static vector unsigned int __ATTRS_o_ai 622vec_vadduws(vector unsigned int __a, vector bool int __b) 623{ 624 return __builtin_altivec_vadduws(__a, (vector unsigned int)__b); 625} 626 627/* vec_and */ 628 629#define __builtin_altivec_vand vec_and 630 631static vector signed char __ATTRS_o_ai 632vec_and(vector signed char __a, vector signed char __b) 633{ 634 return __a & __b; 635} 636 637static vector signed char __ATTRS_o_ai 638vec_and(vector bool char __a, vector signed char __b) 639{ 640 return (vector signed char)__a & __b; 641} 642 643static vector signed char __ATTRS_o_ai 644vec_and(vector signed char __a, vector bool char __b) 645{ 646 return __a & (vector signed char)__b; 647} 648 649static vector unsigned char __ATTRS_o_ai 650vec_and(vector unsigned char __a, vector unsigned char __b) 651{ 652 return __a & __b; 653} 654 655static vector unsigned char __ATTRS_o_ai 656vec_and(vector bool char __a, vector unsigned char __b) 657{ 658 return (vector unsigned char)__a & __b; 659} 660 661static vector unsigned char __ATTRS_o_ai 662vec_and(vector unsigned char __a, vector bool char __b) 663{ 664 return __a & (vector unsigned char)__b; 665} 666 667static vector bool char __ATTRS_o_ai 668vec_and(vector bool char __a, vector bool char __b) 669{ 670 return __a & __b; 671} 672 673static vector short __ATTRS_o_ai 674vec_and(vector short __a, vector short __b) 675{ 676 return __a & __b; 677} 678 679static vector short __ATTRS_o_ai 680vec_and(vector bool short __a, vector short __b) 681{ 682 return (vector short)__a & __b; 683} 684 685static vector short __ATTRS_o_ai 686vec_and(vector short __a, vector bool short __b) 687{ 688 return __a & (vector short)__b; 689} 690 691static vector unsigned short __ATTRS_o_ai 692vec_and(vector unsigned short __a, vector unsigned short __b) 693{ 694 return __a & __b; 695} 696 697static vector unsigned short __ATTRS_o_ai 698vec_and(vector bool short __a, vector unsigned short __b) 699{ 700 return (vector unsigned short)__a & __b; 701} 702 703static vector unsigned short __ATTRS_o_ai 704vec_and(vector unsigned short __a, vector bool short __b) 705{ 706 return __a & (vector unsigned short)__b; 707} 708 709static vector bool short __ATTRS_o_ai 710vec_and(vector bool short __a, vector bool short __b) 711{ 712 return __a & __b; 713} 714 715static vector int __ATTRS_o_ai 716vec_and(vector int __a, vector int __b) 717{ 718 return __a & __b; 719} 720 721static vector int __ATTRS_o_ai 722vec_and(vector bool int __a, vector int __b) 723{ 724 return (vector int)__a & __b; 725} 726 727static vector int __ATTRS_o_ai 728vec_and(vector int __a, vector bool int __b) 729{ 730 return __a & (vector int)__b; 731} 732 733static vector unsigned int __ATTRS_o_ai 734vec_and(vector unsigned int __a, vector unsigned int __b) 735{ 736 return __a & __b; 737} 738 739static vector unsigned int __ATTRS_o_ai 740vec_and(vector bool int __a, vector unsigned int __b) 741{ 742 return (vector unsigned int)__a & __b; 743} 744 745static vector unsigned int __ATTRS_o_ai 746vec_and(vector unsigned int __a, vector bool int __b) 747{ 748 return __a & (vector unsigned int)__b; 749} 750 751static vector bool int __ATTRS_o_ai 752vec_and(vector bool int __a, vector bool int __b) 753{ 754 return __a & __b; 755} 756 757static vector float __ATTRS_o_ai 758vec_and(vector float __a, vector float __b) 759{ 760 vector unsigned int __res = (vector unsigned int)__a & (vector unsigned int)__b; 761 return (vector float)__res; 762} 763 764static vector float __ATTRS_o_ai 765vec_and(vector bool int __a, vector float __b) 766{ 767 vector unsigned int __res = (vector unsigned int)__a & (vector unsigned int)__b; 768 return (vector float)__res; 769} 770 771static vector float __ATTRS_o_ai 772vec_and(vector float __a, vector bool int __b) 773{ 774 vector unsigned int __res = (vector unsigned int)__a & (vector unsigned int)__b; 775 return (vector float)__res; 776} 777 778/* vec_vand */ 779 780static vector signed char __ATTRS_o_ai 781vec_vand(vector signed char __a, vector signed char __b) 782{ 783 return __a & __b; 784} 785 786static vector signed char __ATTRS_o_ai 787vec_vand(vector bool char __a, vector signed char __b) 788{ 789 return (vector signed char)__a & __b; 790} 791 792static vector signed char __ATTRS_o_ai 793vec_vand(vector signed char __a, vector bool char __b) 794{ 795 return __a & (vector signed char)__b; 796} 797 798static vector unsigned char __ATTRS_o_ai 799vec_vand(vector unsigned char __a, vector unsigned char __b) 800{ 801 return __a & __b; 802} 803 804static vector unsigned char __ATTRS_o_ai 805vec_vand(vector bool char __a, vector unsigned char __b) 806{ 807 return (vector unsigned char)__a & __b; 808} 809 810static vector unsigned char __ATTRS_o_ai 811vec_vand(vector unsigned char __a, vector bool char __b) 812{ 813 return __a & (vector unsigned char)__b; 814} 815 816static vector bool char __ATTRS_o_ai 817vec_vand(vector bool char __a, vector bool char __b) 818{ 819 return __a & __b; 820} 821 822static vector short __ATTRS_o_ai 823vec_vand(vector short __a, vector short __b) 824{ 825 return __a & __b; 826} 827 828static vector short __ATTRS_o_ai 829vec_vand(vector bool short __a, vector short __b) 830{ 831 return (vector short)__a & __b; 832} 833 834static vector short __ATTRS_o_ai 835vec_vand(vector short __a, vector bool short __b) 836{ 837 return __a & (vector short)__b; 838} 839 840static vector unsigned short __ATTRS_o_ai 841vec_vand(vector unsigned short __a, vector unsigned short __b) 842{ 843 return __a & __b; 844} 845 846static vector unsigned short __ATTRS_o_ai 847vec_vand(vector bool short __a, vector unsigned short __b) 848{ 849 return (vector unsigned short)__a & __b; 850} 851 852static vector unsigned short __ATTRS_o_ai 853vec_vand(vector unsigned short __a, vector bool short __b) 854{ 855 return __a & (vector unsigned short)__b; 856} 857 858static vector bool short __ATTRS_o_ai 859vec_vand(vector bool short __a, vector bool short __b) 860{ 861 return __a & __b; 862} 863 864static vector int __ATTRS_o_ai 865vec_vand(vector int __a, vector int __b) 866{ 867 return __a & __b; 868} 869 870static vector int __ATTRS_o_ai 871vec_vand(vector bool int __a, vector int __b) 872{ 873 return (vector int)__a & __b; 874} 875 876static vector int __ATTRS_o_ai 877vec_vand(vector int __a, vector bool int __b) 878{ 879 return __a & (vector int)__b; 880} 881 882static vector unsigned int __ATTRS_o_ai 883vec_vand(vector unsigned int __a, vector unsigned int __b) 884{ 885 return __a & __b; 886} 887 888static vector unsigned int __ATTRS_o_ai 889vec_vand(vector bool int __a, vector unsigned int __b) 890{ 891 return (vector unsigned int)__a & __b; 892} 893 894static vector unsigned int __ATTRS_o_ai 895vec_vand(vector unsigned int __a, vector bool int __b) 896{ 897 return __a & (vector unsigned int)__b; 898} 899 900static vector bool int __ATTRS_o_ai 901vec_vand(vector bool int __a, vector bool int __b) 902{ 903 return __a & __b; 904} 905 906static vector float __ATTRS_o_ai 907vec_vand(vector float __a, vector float __b) 908{ 909 vector unsigned int __res = (vector unsigned int)__a & (vector unsigned int)__b; 910 return (vector float)__res; 911} 912 913static vector float __ATTRS_o_ai 914vec_vand(vector bool int __a, vector float __b) 915{ 916 vector unsigned int __res = (vector unsigned int)__a & (vector unsigned int)__b; 917 return (vector float)__res; 918} 919 920static vector float __ATTRS_o_ai 921vec_vand(vector float __a, vector bool int __b) 922{ 923 vector unsigned int __res = (vector unsigned int)__a & (vector unsigned int)__b; 924 return (vector float)__res; 925} 926 927/* vec_andc */ 928 929#define __builtin_altivec_vandc vec_andc 930 931static vector signed char __ATTRS_o_ai 932vec_andc(vector signed char __a, vector signed char __b) 933{ 934 return __a & ~__b; 935} 936 937static vector signed char __ATTRS_o_ai 938vec_andc(vector bool char __a, vector signed char __b) 939{ 940 return (vector signed char)__a & ~__b; 941} 942 943static vector signed char __ATTRS_o_ai 944vec_andc(vector signed char __a, vector bool char __b) 945{ 946 return __a & ~(vector signed char)__b; 947} 948 949static vector unsigned char __ATTRS_o_ai 950vec_andc(vector unsigned char __a, vector unsigned char __b) 951{ 952 return __a & ~__b; 953} 954 955static vector unsigned char __ATTRS_o_ai 956vec_andc(vector bool char __a, vector unsigned char __b) 957{ 958 return (vector unsigned char)__a & ~__b; 959} 960 961static vector unsigned char __ATTRS_o_ai 962vec_andc(vector unsigned char __a, vector bool char __b) 963{ 964 return __a & ~(vector unsigned char)__b; 965} 966 967static vector bool char __ATTRS_o_ai 968vec_andc(vector bool char __a, vector bool char __b) 969{ 970 return __a & ~__b; 971} 972 973static vector short __ATTRS_o_ai 974vec_andc(vector short __a, vector short __b) 975{ 976 return __a & ~__b; 977} 978 979static vector short __ATTRS_o_ai 980vec_andc(vector bool short __a, vector short __b) 981{ 982 return (vector short)__a & ~__b; 983} 984 985static vector short __ATTRS_o_ai 986vec_andc(vector short __a, vector bool short __b) 987{ 988 return __a & ~(vector short)__b; 989} 990 991static vector unsigned short __ATTRS_o_ai 992vec_andc(vector unsigned short __a, vector unsigned short __b) 993{ 994 return __a & ~__b; 995} 996 997static vector unsigned short __ATTRS_o_ai 998vec_andc(vector bool short __a, vector unsigned short __b) 999{ 1000 return (vector unsigned short)__a & ~__b; 1001} 1002 1003static vector unsigned short __ATTRS_o_ai 1004vec_andc(vector unsigned short __a, vector bool short __b) 1005{ 1006 return __a & ~(vector unsigned short)__b; 1007} 1008 1009static vector bool short __ATTRS_o_ai 1010vec_andc(vector bool short __a, vector bool short __b) 1011{ 1012 return __a & ~__b; 1013} 1014 1015static vector int __ATTRS_o_ai 1016vec_andc(vector int __a, vector int __b) 1017{ 1018 return __a & ~__b; 1019} 1020 1021static vector int __ATTRS_o_ai 1022vec_andc(vector bool int __a, vector int __b) 1023{ 1024 return (vector int)__a & ~__b; 1025} 1026 1027static vector int __ATTRS_o_ai 1028vec_andc(vector int __a, vector bool int __b) 1029{ 1030 return __a & ~(vector int)__b; 1031} 1032 1033static vector unsigned int __ATTRS_o_ai 1034vec_andc(vector unsigned int __a, vector unsigned int __b) 1035{ 1036 return __a & ~__b; 1037} 1038 1039static vector unsigned int __ATTRS_o_ai 1040vec_andc(vector bool int __a, vector unsigned int __b) 1041{ 1042 return (vector unsigned int)__a & ~__b; 1043} 1044 1045static vector unsigned int __ATTRS_o_ai 1046vec_andc(vector unsigned int __a, vector bool int __b) 1047{ 1048 return __a & ~(vector unsigned int)__b; 1049} 1050 1051static vector bool int __ATTRS_o_ai 1052vec_andc(vector bool int __a, vector bool int __b) 1053{ 1054 return __a & ~__b; 1055} 1056 1057static vector float __ATTRS_o_ai 1058vec_andc(vector float __a, vector float __b) 1059{ 1060 vector unsigned int __res = (vector unsigned int)__a & ~(vector unsigned int)__b; 1061 return (vector float)__res; 1062} 1063 1064static vector float __ATTRS_o_ai 1065vec_andc(vector bool int __a, vector float __b) 1066{ 1067 vector unsigned int __res = (vector unsigned int)__a & ~(vector unsigned int)__b; 1068 return (vector float)__res; 1069} 1070 1071static vector float __ATTRS_o_ai 1072vec_andc(vector float __a, vector bool int __b) 1073{ 1074 vector unsigned int __res = (vector unsigned int)__a & ~(vector unsigned int)__b; 1075 return (vector float)__res; 1076} 1077 1078/* vec_vandc */ 1079 1080static vector signed char __ATTRS_o_ai 1081vec_vandc(vector signed char __a, vector signed char __b) 1082{ 1083 return __a & ~__b; 1084} 1085 1086static vector signed char __ATTRS_o_ai 1087vec_vandc(vector bool char __a, vector signed char __b) 1088{ 1089 return (vector signed char)__a & ~__b; 1090} 1091 1092static vector signed char __ATTRS_o_ai 1093vec_vandc(vector signed char __a, vector bool char __b) 1094{ 1095 return __a & ~(vector signed char)__b; 1096} 1097 1098static vector unsigned char __ATTRS_o_ai 1099vec_vandc(vector unsigned char __a, vector unsigned char __b) 1100{ 1101 return __a & ~__b; 1102} 1103 1104static vector unsigned char __ATTRS_o_ai 1105vec_vandc(vector bool char __a, vector unsigned char __b) 1106{ 1107 return (vector unsigned char)__a & ~__b; 1108} 1109 1110static vector unsigned char __ATTRS_o_ai 1111vec_vandc(vector unsigned char __a, vector bool char __b) 1112{ 1113 return __a & ~(vector unsigned char)__b; 1114} 1115 1116static vector bool char __ATTRS_o_ai 1117vec_vandc(vector bool char __a, vector bool char __b) 1118{ 1119 return __a & ~__b; 1120} 1121 1122static vector short __ATTRS_o_ai 1123vec_vandc(vector short __a, vector short __b) 1124{ 1125 return __a & ~__b; 1126} 1127 1128static vector short __ATTRS_o_ai 1129vec_vandc(vector bool short __a, vector short __b) 1130{ 1131 return (vector short)__a & ~__b; 1132} 1133 1134static vector short __ATTRS_o_ai 1135vec_vandc(vector short __a, vector bool short __b) 1136{ 1137 return __a & ~(vector short)__b; 1138} 1139 1140static vector unsigned short __ATTRS_o_ai 1141vec_vandc(vector unsigned short __a, vector unsigned short __b) 1142{ 1143 return __a & ~__b; 1144} 1145 1146static vector unsigned short __ATTRS_o_ai 1147vec_vandc(vector bool short __a, vector unsigned short __b) 1148{ 1149 return (vector unsigned short)__a & ~__b; 1150} 1151 1152static vector unsigned short __ATTRS_o_ai 1153vec_vandc(vector unsigned short __a, vector bool short __b) 1154{ 1155 return __a & ~(vector unsigned short)__b; 1156} 1157 1158static vector bool short __ATTRS_o_ai 1159vec_vandc(vector bool short __a, vector bool short __b) 1160{ 1161 return __a & ~__b; 1162} 1163 1164static vector int __ATTRS_o_ai 1165vec_vandc(vector int __a, vector int __b) 1166{ 1167 return __a & ~__b; 1168} 1169 1170static vector int __ATTRS_o_ai 1171vec_vandc(vector bool int __a, vector int __b) 1172{ 1173 return (vector int)__a & ~__b; 1174} 1175 1176static vector int __ATTRS_o_ai 1177vec_vandc(vector int __a, vector bool int __b) 1178{ 1179 return __a & ~(vector int)__b; 1180} 1181 1182static vector unsigned int __ATTRS_o_ai 1183vec_vandc(vector unsigned int __a, vector unsigned int __b) 1184{ 1185 return __a & ~__b; 1186} 1187 1188static vector unsigned int __ATTRS_o_ai 1189vec_vandc(vector bool int __a, vector unsigned int __b) 1190{ 1191 return (vector unsigned int)__a & ~__b; 1192} 1193 1194static vector unsigned int __ATTRS_o_ai 1195vec_vandc(vector unsigned int __a, vector bool int __b) 1196{ 1197 return __a & ~(vector unsigned int)__b; 1198} 1199 1200static vector bool int __ATTRS_o_ai 1201vec_vandc(vector bool int __a, vector bool int __b) 1202{ 1203 return __a & ~__b; 1204} 1205 1206static vector float __ATTRS_o_ai 1207vec_vandc(vector float __a, vector float __b) 1208{ 1209 vector unsigned int __res = (vector unsigned int)__a & ~(vector unsigned int)__b; 1210 return (vector float)__res; 1211} 1212 1213static vector float __ATTRS_o_ai 1214vec_vandc(vector bool int __a, vector float __b) 1215{ 1216 vector unsigned int __res = (vector unsigned int)__a & ~(vector unsigned int)__b; 1217 return (vector float)__res; 1218} 1219 1220static vector float __ATTRS_o_ai 1221vec_vandc(vector float __a, vector bool int __b) 1222{ 1223 vector unsigned int __res = (vector unsigned int)__a & ~(vector unsigned int)__b; 1224 return (vector float)__res; 1225} 1226 1227/* vec_avg */ 1228 1229static vector signed char __ATTRS_o_ai 1230vec_avg(vector signed char __a, vector signed char __b) 1231{ 1232 return __builtin_altivec_vavgsb(__a, __b); 1233} 1234 1235static vector unsigned char __ATTRS_o_ai 1236vec_avg(vector unsigned char __a, vector unsigned char __b) 1237{ 1238 return __builtin_altivec_vavgub(__a, __b); 1239} 1240 1241static vector short __ATTRS_o_ai 1242vec_avg(vector short __a, vector short __b) 1243{ 1244 return __builtin_altivec_vavgsh(__a, __b); 1245} 1246 1247static vector unsigned short __ATTRS_o_ai 1248vec_avg(vector unsigned short __a, vector unsigned short __b) 1249{ 1250 return __builtin_altivec_vavguh(__a, __b); 1251} 1252 1253static vector int __ATTRS_o_ai 1254vec_avg(vector int __a, vector int __b) 1255{ 1256 return __builtin_altivec_vavgsw(__a, __b); 1257} 1258 1259static vector unsigned int __ATTRS_o_ai 1260vec_avg(vector unsigned int __a, vector unsigned int __b) 1261{ 1262 return __builtin_altivec_vavguw(__a, __b); 1263} 1264 1265/* vec_vavgsb */ 1266 1267static vector signed char __attribute__((__always_inline__)) 1268vec_vavgsb(vector signed char __a, vector signed char __b) 1269{ 1270 return __builtin_altivec_vavgsb(__a, __b); 1271} 1272 1273/* vec_vavgub */ 1274 1275static vector unsigned char __attribute__((__always_inline__)) 1276vec_vavgub(vector unsigned char __a, vector unsigned char __b) 1277{ 1278 return __builtin_altivec_vavgub(__a, __b); 1279} 1280 1281/* vec_vavgsh */ 1282 1283static vector short __attribute__((__always_inline__)) 1284vec_vavgsh(vector short __a, vector short __b) 1285{ 1286 return __builtin_altivec_vavgsh(__a, __b); 1287} 1288 1289/* vec_vavguh */ 1290 1291static vector unsigned short __attribute__((__always_inline__)) 1292vec_vavguh(vector unsigned short __a, vector unsigned short __b) 1293{ 1294 return __builtin_altivec_vavguh(__a, __b); 1295} 1296 1297/* vec_vavgsw */ 1298 1299static vector int __attribute__((__always_inline__)) 1300vec_vavgsw(vector int __a, vector int __b) 1301{ 1302 return __builtin_altivec_vavgsw(__a, __b); 1303} 1304 1305/* vec_vavguw */ 1306 1307static vector unsigned int __attribute__((__always_inline__)) 1308vec_vavguw(vector unsigned int __a, vector unsigned int __b) 1309{ 1310 return __builtin_altivec_vavguw(__a, __b); 1311} 1312 1313/* vec_ceil */ 1314 1315static vector float __attribute__((__always_inline__)) 1316vec_ceil(vector float __a) 1317{ 1318 return __builtin_altivec_vrfip(__a); 1319} 1320 1321/* vec_vrfip */ 1322 1323static vector float __attribute__((__always_inline__)) 1324vec_vrfip(vector float __a) 1325{ 1326 return __builtin_altivec_vrfip(__a); 1327} 1328 1329/* vec_cmpb */ 1330 1331static vector int __attribute__((__always_inline__)) 1332vec_cmpb(vector float __a, vector float __b) 1333{ 1334 return __builtin_altivec_vcmpbfp(__a, __b); 1335} 1336 1337/* vec_vcmpbfp */ 1338 1339static vector int __attribute__((__always_inline__)) 1340vec_vcmpbfp(vector float __a, vector float __b) 1341{ 1342 return __builtin_altivec_vcmpbfp(__a, __b); 1343} 1344 1345/* vec_cmpeq */ 1346 1347static vector bool char __ATTRS_o_ai 1348vec_cmpeq(vector signed char __a, vector signed char __b) 1349{ 1350 return (vector bool char) 1351 __builtin_altivec_vcmpequb((vector char)__a, (vector char)__b); 1352} 1353 1354static vector bool char __ATTRS_o_ai 1355vec_cmpeq(vector unsigned char __a, vector unsigned char __b) 1356{ 1357 return (vector bool char) 1358 __builtin_altivec_vcmpequb((vector char)__a, (vector char)__b); 1359} 1360 1361static vector bool short __ATTRS_o_ai 1362vec_cmpeq(vector short __a, vector short __b) 1363{ 1364 return (vector bool short)__builtin_altivec_vcmpequh(__a, __b); 1365} 1366 1367static vector bool short __ATTRS_o_ai 1368vec_cmpeq(vector unsigned short __a, vector unsigned short __b) 1369{ 1370 return (vector bool short) 1371 __builtin_altivec_vcmpequh((vector short)__a, (vector short)__b); 1372} 1373 1374static vector bool int __ATTRS_o_ai 1375vec_cmpeq(vector int __a, vector int __b) 1376{ 1377 return (vector bool int)__builtin_altivec_vcmpequw(__a, __b); 1378} 1379 1380static vector bool int __ATTRS_o_ai 1381vec_cmpeq(vector unsigned int __a, vector unsigned int __b) 1382{ 1383 return (vector bool int) 1384 __builtin_altivec_vcmpequw((vector int)__a, (vector int)__b); 1385} 1386 1387static vector bool int __ATTRS_o_ai 1388vec_cmpeq(vector float __a, vector float __b) 1389{ 1390 return (vector bool int)__builtin_altivec_vcmpeqfp(__a, __b); 1391} 1392 1393/* vec_cmpge */ 1394 1395static vector bool int __attribute__((__always_inline__)) 1396vec_cmpge(vector float __a, vector float __b) 1397{ 1398 return (vector bool int)__builtin_altivec_vcmpgefp(__a, __b); 1399} 1400 1401/* vec_vcmpgefp */ 1402 1403static vector bool int __attribute__((__always_inline__)) 1404vec_vcmpgefp(vector float __a, vector float __b) 1405{ 1406 return (vector bool int)__builtin_altivec_vcmpgefp(__a, __b); 1407} 1408 1409/* vec_cmpgt */ 1410 1411static vector bool char __ATTRS_o_ai 1412vec_cmpgt(vector signed char __a, vector signed char __b) 1413{ 1414 return (vector bool char)__builtin_altivec_vcmpgtsb(__a, __b); 1415} 1416 1417static vector bool char __ATTRS_o_ai 1418vec_cmpgt(vector unsigned char __a, vector unsigned char __b) 1419{ 1420 return (vector bool char)__builtin_altivec_vcmpgtub(__a, __b); 1421} 1422 1423static vector bool short __ATTRS_o_ai 1424vec_cmpgt(vector short __a, vector short __b) 1425{ 1426 return (vector bool short)__builtin_altivec_vcmpgtsh(__a, __b); 1427} 1428 1429static vector bool short __ATTRS_o_ai 1430vec_cmpgt(vector unsigned short __a, vector unsigned short __b) 1431{ 1432 return (vector bool short)__builtin_altivec_vcmpgtuh(__a, __b); 1433} 1434 1435static vector bool int __ATTRS_o_ai 1436vec_cmpgt(vector int __a, vector int __b) 1437{ 1438 return (vector bool int)__builtin_altivec_vcmpgtsw(__a, __b); 1439} 1440 1441static vector bool int __ATTRS_o_ai 1442vec_cmpgt(vector unsigned int __a, vector unsigned int __b) 1443{ 1444 return (vector bool int)__builtin_altivec_vcmpgtuw(__a, __b); 1445} 1446 1447static vector bool int __ATTRS_o_ai 1448vec_cmpgt(vector float __a, vector float __b) 1449{ 1450 return (vector bool int)__builtin_altivec_vcmpgtfp(__a, __b); 1451} 1452 1453/* vec_vcmpgtsb */ 1454 1455static vector bool char __attribute__((__always_inline__)) 1456vec_vcmpgtsb(vector signed char __a, vector signed char __b) 1457{ 1458 return (vector bool char)__builtin_altivec_vcmpgtsb(__a, __b); 1459} 1460 1461/* vec_vcmpgtub */ 1462 1463static vector bool char __attribute__((__always_inline__)) 1464vec_vcmpgtub(vector unsigned char __a, vector unsigned char __b) 1465{ 1466 return (vector bool char)__builtin_altivec_vcmpgtub(__a, __b); 1467} 1468 1469/* vec_vcmpgtsh */ 1470 1471static vector bool short __attribute__((__always_inline__)) 1472vec_vcmpgtsh(vector short __a, vector short __b) 1473{ 1474 return (vector bool short)__builtin_altivec_vcmpgtsh(__a, __b); 1475} 1476 1477/* vec_vcmpgtuh */ 1478 1479static vector bool short __attribute__((__always_inline__)) 1480vec_vcmpgtuh(vector unsigned short __a, vector unsigned short __b) 1481{ 1482 return (vector bool short)__builtin_altivec_vcmpgtuh(__a, __b); 1483} 1484 1485/* vec_vcmpgtsw */ 1486 1487static vector bool int __attribute__((__always_inline__)) 1488vec_vcmpgtsw(vector int __a, vector int __b) 1489{ 1490 return (vector bool int)__builtin_altivec_vcmpgtsw(__a, __b); 1491} 1492 1493/* vec_vcmpgtuw */ 1494 1495static vector bool int __attribute__((__always_inline__)) 1496vec_vcmpgtuw(vector unsigned int __a, vector unsigned int __b) 1497{ 1498 return (vector bool int)__builtin_altivec_vcmpgtuw(__a, __b); 1499} 1500 1501/* vec_vcmpgtfp */ 1502 1503static vector bool int __attribute__((__always_inline__)) 1504vec_vcmpgtfp(vector float __a, vector float __b) 1505{ 1506 return (vector bool int)__builtin_altivec_vcmpgtfp(__a, __b); 1507} 1508 1509/* vec_cmple */ 1510 1511static vector bool int __attribute__((__always_inline__)) 1512vec_cmple(vector float __a, vector float __b) 1513{ 1514 return (vector bool int)__builtin_altivec_vcmpgefp(__b, __a); 1515} 1516 1517/* vec_cmplt */ 1518 1519static vector bool char __ATTRS_o_ai 1520vec_cmplt(vector signed char __a, vector signed char __b) 1521{ 1522 return (vector bool char)__builtin_altivec_vcmpgtsb(__b, __a); 1523} 1524 1525static vector bool char __ATTRS_o_ai 1526vec_cmplt(vector unsigned char __a, vector unsigned char __b) 1527{ 1528 return (vector bool char)__builtin_altivec_vcmpgtub(__b, __a); 1529} 1530 1531static vector bool short __ATTRS_o_ai 1532vec_cmplt(vector short __a, vector short __b) 1533{ 1534 return (vector bool short)__builtin_altivec_vcmpgtsh(__b, __a); 1535} 1536 1537static vector bool short __ATTRS_o_ai 1538vec_cmplt(vector unsigned short __a, vector unsigned short __b) 1539{ 1540 return (vector bool short)__builtin_altivec_vcmpgtuh(__b, __a); 1541} 1542 1543static vector bool int __ATTRS_o_ai 1544vec_cmplt(vector int __a, vector int __b) 1545{ 1546 return (vector bool int)__builtin_altivec_vcmpgtsw(__b, __a); 1547} 1548 1549static vector bool int __ATTRS_o_ai 1550vec_cmplt(vector unsigned int __a, vector unsigned int __b) 1551{ 1552 return (vector bool int)__builtin_altivec_vcmpgtuw(__b, __a); 1553} 1554 1555static vector bool int __ATTRS_o_ai 1556vec_cmplt(vector float __a, vector float __b) 1557{ 1558 return (vector bool int)__builtin_altivec_vcmpgtfp(__b, __a); 1559} 1560 1561/* vec_ctf */ 1562 1563static vector float __ATTRS_o_ai 1564vec_ctf(vector int __a, int __b) 1565{ 1566 return __builtin_altivec_vcfsx(__a, __b); 1567} 1568 1569static vector float __ATTRS_o_ai 1570vec_ctf(vector unsigned int __a, int __b) 1571{ 1572 return __builtin_altivec_vcfux((vector int)__a, __b); 1573} 1574 1575/* vec_vcfsx */ 1576 1577static vector float __attribute__((__always_inline__)) 1578vec_vcfsx(vector int __a, int __b) 1579{ 1580 return __builtin_altivec_vcfsx(__a, __b); 1581} 1582 1583/* vec_vcfux */ 1584 1585static vector float __attribute__((__always_inline__)) 1586vec_vcfux(vector unsigned int __a, int __b) 1587{ 1588 return __builtin_altivec_vcfux((vector int)__a, __b); 1589} 1590 1591/* vec_cts */ 1592 1593static vector int __attribute__((__always_inline__)) 1594vec_cts(vector float __a, int __b) 1595{ 1596 return __builtin_altivec_vctsxs(__a, __b); 1597} 1598 1599/* vec_vctsxs */ 1600 1601static vector int __attribute__((__always_inline__)) 1602vec_vctsxs(vector float __a, int __b) 1603{ 1604 return __builtin_altivec_vctsxs(__a, __b); 1605} 1606 1607/* vec_ctu */ 1608 1609static vector unsigned int __attribute__((__always_inline__)) 1610vec_ctu(vector float __a, int __b) 1611{ 1612 return __builtin_altivec_vctuxs(__a, __b); 1613} 1614 1615/* vec_vctuxs */ 1616 1617static vector unsigned int __attribute__((__always_inline__)) 1618vec_vctuxs(vector float __a, int __b) 1619{ 1620 return __builtin_altivec_vctuxs(__a, __b); 1621} 1622 1623/* vec_dss */ 1624 1625static void __attribute__((__always_inline__)) 1626vec_dss(int __a) 1627{ 1628 __builtin_altivec_dss(__a); 1629} 1630 1631/* vec_dssall */ 1632 1633static void __attribute__((__always_inline__)) 1634vec_dssall(void) 1635{ 1636 __builtin_altivec_dssall(); 1637} 1638 1639/* vec_dst */ 1640 1641static void __attribute__((__always_inline__)) 1642vec_dst(const void *__a, int __b, int __c) 1643{ 1644 __builtin_altivec_dst(__a, __b, __c); 1645} 1646 1647/* vec_dstst */ 1648 1649static void __attribute__((__always_inline__)) 1650vec_dstst(const void *__a, int __b, int __c) 1651{ 1652 __builtin_altivec_dstst(__a, __b, __c); 1653} 1654 1655/* vec_dststt */ 1656 1657static void __attribute__((__always_inline__)) 1658vec_dststt(const void *__a, int __b, int __c) 1659{ 1660 __builtin_altivec_dststt(__a, __b, __c); 1661} 1662 1663/* vec_dstt */ 1664 1665static void __attribute__((__always_inline__)) 1666vec_dstt(const void *__a, int __b, int __c) 1667{ 1668 __builtin_altivec_dstt(__a, __b, __c); 1669} 1670 1671/* vec_expte */ 1672 1673static vector float __attribute__((__always_inline__)) 1674vec_expte(vector float __a) 1675{ 1676 return __builtin_altivec_vexptefp(__a); 1677} 1678 1679/* vec_vexptefp */ 1680 1681static vector float __attribute__((__always_inline__)) 1682vec_vexptefp(vector float __a) 1683{ 1684 return __builtin_altivec_vexptefp(__a); 1685} 1686 1687/* vec_floor */ 1688 1689static vector float __attribute__((__always_inline__)) 1690vec_floor(vector float __a) 1691{ 1692 return __builtin_altivec_vrfim(__a); 1693} 1694 1695/* vec_vrfim */ 1696 1697static vector float __attribute__((__always_inline__)) 1698vec_vrfim(vector float __a) 1699{ 1700 return __builtin_altivec_vrfim(__a); 1701} 1702 1703/* vec_ld */ 1704 1705static vector signed char __ATTRS_o_ai 1706vec_ld(int __a, const vector signed char *__b) 1707{ 1708 return (vector signed char)__builtin_altivec_lvx(__a, __b); 1709} 1710 1711static vector signed char __ATTRS_o_ai 1712vec_ld(int __a, const signed char *__b) 1713{ 1714 return (vector signed char)__builtin_altivec_lvx(__a, __b); 1715} 1716 1717static vector unsigned char __ATTRS_o_ai 1718vec_ld(int __a, const vector unsigned char *__b) 1719{ 1720 return (vector unsigned char)__builtin_altivec_lvx(__a, __b); 1721} 1722 1723static vector unsigned char __ATTRS_o_ai 1724vec_ld(int __a, const unsigned char *__b) 1725{ 1726 return (vector unsigned char)__builtin_altivec_lvx(__a, __b); 1727} 1728 1729static vector bool char __ATTRS_o_ai 1730vec_ld(int __a, const vector bool char *__b) 1731{ 1732 return (vector bool char)__builtin_altivec_lvx(__a, __b); 1733} 1734 1735static vector short __ATTRS_o_ai 1736vec_ld(int __a, const vector short *__b) 1737{ 1738 return (vector short)__builtin_altivec_lvx(__a, __b); 1739} 1740 1741static vector short __ATTRS_o_ai 1742vec_ld(int __a, const short *__b) 1743{ 1744 return (vector short)__builtin_altivec_lvx(__a, __b); 1745} 1746 1747static vector unsigned short __ATTRS_o_ai 1748vec_ld(int __a, const vector unsigned short *__b) 1749{ 1750 return (vector unsigned short)__builtin_altivec_lvx(__a, __b); 1751} 1752 1753static vector unsigned short __ATTRS_o_ai 1754vec_ld(int __a, const unsigned short *__b) 1755{ 1756 return (vector unsigned short)__builtin_altivec_lvx(__a, __b); 1757} 1758 1759static vector bool short __ATTRS_o_ai 1760vec_ld(int __a, const vector bool short *__b) 1761{ 1762 return (vector bool short)__builtin_altivec_lvx(__a, __b); 1763} 1764 1765static vector pixel __ATTRS_o_ai 1766vec_ld(int __a, const vector pixel *__b) 1767{ 1768 return (vector pixel)__builtin_altivec_lvx(__a, __b); 1769} 1770 1771static vector int __ATTRS_o_ai 1772vec_ld(int __a, const vector int *__b) 1773{ 1774 return (vector int)__builtin_altivec_lvx(__a, __b); 1775} 1776 1777static vector int __ATTRS_o_ai 1778vec_ld(int __a, const int *__b) 1779{ 1780 return (vector int)__builtin_altivec_lvx(__a, __b); 1781} 1782 1783static vector unsigned int __ATTRS_o_ai 1784vec_ld(int __a, const vector unsigned int *__b) 1785{ 1786 return (vector unsigned int)__builtin_altivec_lvx(__a, __b); 1787} 1788 1789static vector unsigned int __ATTRS_o_ai 1790vec_ld(int __a, const unsigned int *__b) 1791{ 1792 return (vector unsigned int)__builtin_altivec_lvx(__a, __b); 1793} 1794 1795static vector bool int __ATTRS_o_ai 1796vec_ld(int __a, const vector bool int *__b) 1797{ 1798 return (vector bool int)__builtin_altivec_lvx(__a, __b); 1799} 1800 1801static vector float __ATTRS_o_ai 1802vec_ld(int __a, const vector float *__b) 1803{ 1804 return (vector float)__builtin_altivec_lvx(__a, __b); 1805} 1806 1807static vector float __ATTRS_o_ai 1808vec_ld(int __a, const float *__b) 1809{ 1810 return (vector float)__builtin_altivec_lvx(__a, __b); 1811} 1812 1813/* vec_lvx */ 1814 1815static vector signed char __ATTRS_o_ai 1816vec_lvx(int __a, const vector signed char *__b) 1817{ 1818 return (vector signed char)__builtin_altivec_lvx(__a, __b); 1819} 1820 1821static vector signed char __ATTRS_o_ai 1822vec_lvx(int __a, const signed char *__b) 1823{ 1824 return (vector signed char)__builtin_altivec_lvx(__a, __b); 1825} 1826 1827static vector unsigned char __ATTRS_o_ai 1828vec_lvx(int __a, const vector unsigned char *__b) 1829{ 1830 return (vector unsigned char)__builtin_altivec_lvx(__a, __b); 1831} 1832 1833static vector unsigned char __ATTRS_o_ai 1834vec_lvx(int __a, const unsigned char *__b) 1835{ 1836 return (vector unsigned char)__builtin_altivec_lvx(__a, __b); 1837} 1838 1839static vector bool char __ATTRS_o_ai 1840vec_lvx(int __a, const vector bool char *__b) 1841{ 1842 return (vector bool char)__builtin_altivec_lvx(__a, __b); 1843} 1844 1845static vector short __ATTRS_o_ai 1846vec_lvx(int __a, const vector short *__b) 1847{ 1848 return (vector short)__builtin_altivec_lvx(__a, __b); 1849} 1850 1851static vector short __ATTRS_o_ai 1852vec_lvx(int __a, const short *__b) 1853{ 1854 return (vector short)__builtin_altivec_lvx(__a, __b); 1855} 1856 1857static vector unsigned short __ATTRS_o_ai 1858vec_lvx(int __a, const vector unsigned short *__b) 1859{ 1860 return (vector unsigned short)__builtin_altivec_lvx(__a, __b); 1861} 1862 1863static vector unsigned short __ATTRS_o_ai 1864vec_lvx(int __a, const unsigned short *__b) 1865{ 1866 return (vector unsigned short)__builtin_altivec_lvx(__a, __b); 1867} 1868 1869static vector bool short __ATTRS_o_ai 1870vec_lvx(int __a, const vector bool short *__b) 1871{ 1872 return (vector bool short)__builtin_altivec_lvx(__a, __b); 1873} 1874 1875static vector pixel __ATTRS_o_ai 1876vec_lvx(int __a, const vector pixel *__b) 1877{ 1878 return (vector pixel)__builtin_altivec_lvx(__a, __b); 1879} 1880 1881static vector int __ATTRS_o_ai 1882vec_lvx(int __a, const vector int *__b) 1883{ 1884 return (vector int)__builtin_altivec_lvx(__a, __b); 1885} 1886 1887static vector int __ATTRS_o_ai 1888vec_lvx(int __a, const int *__b) 1889{ 1890 return (vector int)__builtin_altivec_lvx(__a, __b); 1891} 1892 1893static vector unsigned int __ATTRS_o_ai 1894vec_lvx(int __a, const vector unsigned int *__b) 1895{ 1896 return (vector unsigned int)__builtin_altivec_lvx(__a, __b); 1897} 1898 1899static vector unsigned int __ATTRS_o_ai 1900vec_lvx(int __a, const unsigned int *__b) 1901{ 1902 return (vector unsigned int)__builtin_altivec_lvx(__a, __b); 1903} 1904 1905static vector bool int __ATTRS_o_ai 1906vec_lvx(int __a, const vector bool int *__b) 1907{ 1908 return (vector bool int)__builtin_altivec_lvx(__a, __b); 1909} 1910 1911static vector float __ATTRS_o_ai 1912vec_lvx(int __a, const vector float *__b) 1913{ 1914 return (vector float)__builtin_altivec_lvx(__a, __b); 1915} 1916 1917static vector float __ATTRS_o_ai 1918vec_lvx(int __a, const float *__b) 1919{ 1920 return (vector float)__builtin_altivec_lvx(__a, __b); 1921} 1922 1923/* vec_lde */ 1924 1925static vector signed char __ATTRS_o_ai 1926vec_lde(int __a, const signed char *__b) 1927{ 1928 return (vector signed char)__builtin_altivec_lvebx(__a, __b); 1929} 1930 1931static vector unsigned char __ATTRS_o_ai 1932vec_lde(int __a, const unsigned char *__b) 1933{ 1934 return (vector unsigned char)__builtin_altivec_lvebx(__a, __b); 1935} 1936 1937static vector short __ATTRS_o_ai 1938vec_lde(int __a, const short *__b) 1939{ 1940 return (vector short)__builtin_altivec_lvehx(__a, __b); 1941} 1942 1943static vector unsigned short __ATTRS_o_ai 1944vec_lde(int __a, const unsigned short *__b) 1945{ 1946 return (vector unsigned short)__builtin_altivec_lvehx(__a, __b); 1947} 1948 1949static vector int __ATTRS_o_ai 1950vec_lde(int __a, const int *__b) 1951{ 1952 return (vector int)__builtin_altivec_lvewx(__a, __b); 1953} 1954 1955static vector unsigned int __ATTRS_o_ai 1956vec_lde(int __a, const unsigned int *__b) 1957{ 1958 return (vector unsigned int)__builtin_altivec_lvewx(__a, __b); 1959} 1960 1961static vector float __ATTRS_o_ai 1962vec_lde(int __a, const float *__b) 1963{ 1964 return (vector float)__builtin_altivec_lvewx(__a, __b); 1965} 1966 1967/* vec_lvebx */ 1968 1969static vector signed char __ATTRS_o_ai 1970vec_lvebx(int __a, const signed char *__b) 1971{ 1972 return (vector signed char)__builtin_altivec_lvebx(__a, __b); 1973} 1974 1975static vector unsigned char __ATTRS_o_ai 1976vec_lvebx(int __a, const unsigned char *__b) 1977{ 1978 return (vector unsigned char)__builtin_altivec_lvebx(__a, __b); 1979} 1980 1981/* vec_lvehx */ 1982 1983static vector short __ATTRS_o_ai 1984vec_lvehx(int __a, const short *__b) 1985{ 1986 return (vector short)__builtin_altivec_lvehx(__a, __b); 1987} 1988 1989static vector unsigned short __ATTRS_o_ai 1990vec_lvehx(int __a, const unsigned short *__b) 1991{ 1992 return (vector unsigned short)__builtin_altivec_lvehx(__a, __b); 1993} 1994 1995/* vec_lvewx */ 1996 1997static vector int __ATTRS_o_ai 1998vec_lvewx(int __a, const int *__b) 1999{ 2000 return (vector int)__builtin_altivec_lvewx(__a, __b); 2001} 2002 2003static vector unsigned int __ATTRS_o_ai 2004vec_lvewx(int __a, const unsigned int *__b) 2005{ 2006 return (vector unsigned int)__builtin_altivec_lvewx(__a, __b); 2007} 2008 2009static vector float __ATTRS_o_ai 2010vec_lvewx(int __a, const float *__b) 2011{ 2012 return (vector float)__builtin_altivec_lvewx(__a, __b); 2013} 2014 2015/* vec_ldl */ 2016 2017static vector signed char __ATTRS_o_ai 2018vec_ldl(int __a, const vector signed char *__b) 2019{ 2020 return (vector signed char)__builtin_altivec_lvxl(__a, __b); 2021} 2022 2023static vector signed char __ATTRS_o_ai 2024vec_ldl(int __a, const signed char *__b) 2025{ 2026 return (vector signed char)__builtin_altivec_lvxl(__a, __b); 2027} 2028 2029static vector unsigned char __ATTRS_o_ai 2030vec_ldl(int __a, const vector unsigned char *__b) 2031{ 2032 return (vector unsigned char)__builtin_altivec_lvxl(__a, __b); 2033} 2034 2035static vector unsigned char __ATTRS_o_ai 2036vec_ldl(int __a, const unsigned char *__b) 2037{ 2038 return (vector unsigned char)__builtin_altivec_lvxl(__a, __b); 2039} 2040 2041static vector bool char __ATTRS_o_ai 2042vec_ldl(int __a, const vector bool char *__b) 2043{ 2044 return (vector bool char)__builtin_altivec_lvxl(__a, __b); 2045} 2046 2047static vector short __ATTRS_o_ai 2048vec_ldl(int __a, const vector short *__b) 2049{ 2050 return (vector short)__builtin_altivec_lvxl(__a, __b); 2051} 2052 2053static vector short __ATTRS_o_ai 2054vec_ldl(int __a, const short *__b) 2055{ 2056 return (vector short)__builtin_altivec_lvxl(__a, __b); 2057} 2058 2059static vector unsigned short __ATTRS_o_ai 2060vec_ldl(int __a, const vector unsigned short *__b) 2061{ 2062 return (vector unsigned short)__builtin_altivec_lvxl(__a, __b); 2063} 2064 2065static vector unsigned short __ATTRS_o_ai 2066vec_ldl(int __a, const unsigned short *__b) 2067{ 2068 return (vector unsigned short)__builtin_altivec_lvxl(__a, __b); 2069} 2070 2071static vector bool short __ATTRS_o_ai 2072vec_ldl(int __a, const vector bool short *__b) 2073{ 2074 return (vector bool short)__builtin_altivec_lvxl(__a, __b); 2075} 2076 2077static vector pixel __ATTRS_o_ai 2078vec_ldl(int __a, const vector pixel *__b) 2079{ 2080 return (vector pixel short)__builtin_altivec_lvxl(__a, __b); 2081} 2082 2083static vector int __ATTRS_o_ai 2084vec_ldl(int __a, const vector int *__b) 2085{ 2086 return (vector int)__builtin_altivec_lvxl(__a, __b); 2087} 2088 2089static vector int __ATTRS_o_ai 2090vec_ldl(int __a, const int *__b) 2091{ 2092 return (vector int)__builtin_altivec_lvxl(__a, __b); 2093} 2094 2095static vector unsigned int __ATTRS_o_ai 2096vec_ldl(int __a, const vector unsigned int *__b) 2097{ 2098 return (vector unsigned int)__builtin_altivec_lvxl(__a, __b); 2099} 2100 2101static vector unsigned int __ATTRS_o_ai 2102vec_ldl(int __a, const unsigned int *__b) 2103{ 2104 return (vector unsigned int)__builtin_altivec_lvxl(__a, __b); 2105} 2106 2107static vector bool int __ATTRS_o_ai 2108vec_ldl(int __a, const vector bool int *__b) 2109{ 2110 return (vector bool int)__builtin_altivec_lvxl(__a, __b); 2111} 2112 2113static vector float __ATTRS_o_ai 2114vec_ldl(int __a, const vector float *__b) 2115{ 2116 return (vector float)__builtin_altivec_lvxl(__a, __b); 2117} 2118 2119static vector float __ATTRS_o_ai 2120vec_ldl(int __a, const float *__b) 2121{ 2122 return (vector float)__builtin_altivec_lvxl(__a, __b); 2123} 2124 2125/* vec_lvxl */ 2126 2127static vector signed char __ATTRS_o_ai 2128vec_lvxl(int __a, const vector signed char *__b) 2129{ 2130 return (vector signed char)__builtin_altivec_lvxl(__a, __b); 2131} 2132 2133static vector signed char __ATTRS_o_ai 2134vec_lvxl(int __a, const signed char *__b) 2135{ 2136 return (vector signed char)__builtin_altivec_lvxl(__a, __b); 2137} 2138 2139static vector unsigned char __ATTRS_o_ai 2140vec_lvxl(int __a, const vector unsigned char *__b) 2141{ 2142 return (vector unsigned char)__builtin_altivec_lvxl(__a, __b); 2143} 2144 2145static vector unsigned char __ATTRS_o_ai 2146vec_lvxl(int __a, const unsigned char *__b) 2147{ 2148 return (vector unsigned char)__builtin_altivec_lvxl(__a, __b); 2149} 2150 2151static vector bool char __ATTRS_o_ai 2152vec_lvxl(int __a, const vector bool char *__b) 2153{ 2154 return (vector bool char)__builtin_altivec_lvxl(__a, __b); 2155} 2156 2157static vector short __ATTRS_o_ai 2158vec_lvxl(int __a, const vector short *__b) 2159{ 2160 return (vector short)__builtin_altivec_lvxl(__a, __b); 2161} 2162 2163static vector short __ATTRS_o_ai 2164vec_lvxl(int __a, const short *__b) 2165{ 2166 return (vector short)__builtin_altivec_lvxl(__a, __b); 2167} 2168 2169static vector unsigned short __ATTRS_o_ai 2170vec_lvxl(int __a, const vector unsigned short *__b) 2171{ 2172 return (vector unsigned short)__builtin_altivec_lvxl(__a, __b); 2173} 2174 2175static vector unsigned short __ATTRS_o_ai 2176vec_lvxl(int __a, const unsigned short *__b) 2177{ 2178 return (vector unsigned short)__builtin_altivec_lvxl(__a, __b); 2179} 2180 2181static vector bool short __ATTRS_o_ai 2182vec_lvxl(int __a, const vector bool short *__b) 2183{ 2184 return (vector bool short)__builtin_altivec_lvxl(__a, __b); 2185} 2186 2187static vector pixel __ATTRS_o_ai 2188vec_lvxl(int __a, const vector pixel *__b) 2189{ 2190 return (vector pixel)__builtin_altivec_lvxl(__a, __b); 2191} 2192 2193static vector int __ATTRS_o_ai 2194vec_lvxl(int __a, const vector int *__b) 2195{ 2196 return (vector int)__builtin_altivec_lvxl(__a, __b); 2197} 2198 2199static vector int __ATTRS_o_ai 2200vec_lvxl(int __a, const int *__b) 2201{ 2202 return (vector int)__builtin_altivec_lvxl(__a, __b); 2203} 2204 2205static vector unsigned int __ATTRS_o_ai 2206vec_lvxl(int __a, const vector unsigned int *__b) 2207{ 2208 return (vector unsigned int)__builtin_altivec_lvxl(__a, __b); 2209} 2210 2211static vector unsigned int __ATTRS_o_ai 2212vec_lvxl(int __a, const unsigned int *__b) 2213{ 2214 return (vector unsigned int)__builtin_altivec_lvxl(__a, __b); 2215} 2216 2217static vector bool int __ATTRS_o_ai 2218vec_lvxl(int __a, const vector bool int *__b) 2219{ 2220 return (vector bool int)__builtin_altivec_lvxl(__a, __b); 2221} 2222 2223static vector float __ATTRS_o_ai 2224vec_lvxl(int __a, const vector float *__b) 2225{ 2226 return (vector float)__builtin_altivec_lvxl(__a, __b); 2227} 2228 2229static vector float __ATTRS_o_ai 2230vec_lvxl(int __a, const float *__b) 2231{ 2232 return (vector float)__builtin_altivec_lvxl(__a, __b); 2233} 2234 2235/* vec_loge */ 2236 2237static vector float __attribute__((__always_inline__)) 2238vec_loge(vector float __a) 2239{ 2240 return __builtin_altivec_vlogefp(__a); 2241} 2242 2243/* vec_vlogefp */ 2244 2245static vector float __attribute__((__always_inline__)) 2246vec_vlogefp(vector float __a) 2247{ 2248 return __builtin_altivec_vlogefp(__a); 2249} 2250 2251/* vec_lvsl */ 2252 2253static vector unsigned char __ATTRS_o_ai 2254vec_lvsl(int __a, const signed char *__b) 2255{ 2256 return (vector unsigned char)__builtin_altivec_lvsl(__a, __b); 2257} 2258 2259static vector unsigned char __ATTRS_o_ai 2260vec_lvsl(int __a, const unsigned char *__b) 2261{ 2262 return (vector unsigned char)__builtin_altivec_lvsl(__a, __b); 2263} 2264 2265static vector unsigned char __ATTRS_o_ai 2266vec_lvsl(int __a, const short *__b) 2267{ 2268 return (vector unsigned char)__builtin_altivec_lvsl(__a, __b); 2269} 2270 2271static vector unsigned char __ATTRS_o_ai 2272vec_lvsl(int __a, const unsigned short *__b) 2273{ 2274 return (vector unsigned char)__builtin_altivec_lvsl(__a, __b); 2275} 2276 2277static vector unsigned char __ATTRS_o_ai 2278vec_lvsl(int __a, const int *__b) 2279{ 2280 return (vector unsigned char)__builtin_altivec_lvsl(__a, __b); 2281} 2282 2283static vector unsigned char __ATTRS_o_ai 2284vec_lvsl(int __a, const unsigned int *__b) 2285{ 2286 return (vector unsigned char)__builtin_altivec_lvsl(__a, __b); 2287} 2288 2289static vector unsigned char __ATTRS_o_ai 2290vec_lvsl(int __a, const float *__b) 2291{ 2292 return (vector unsigned char)__builtin_altivec_lvsl(__a, __b); 2293} 2294 2295/* vec_lvsr */ 2296 2297static vector unsigned char __ATTRS_o_ai 2298vec_lvsr(int __a, const signed char *__b) 2299{ 2300 return (vector unsigned char)__builtin_altivec_lvsr(__a, __b); 2301} 2302 2303static vector unsigned char __ATTRS_o_ai 2304vec_lvsr(int __a, const unsigned char *__b) 2305{ 2306 return (vector unsigned char)__builtin_altivec_lvsr(__a, __b); 2307} 2308 2309static vector unsigned char __ATTRS_o_ai 2310vec_lvsr(int __a, const short *__b) 2311{ 2312 return (vector unsigned char)__builtin_altivec_lvsr(__a, __b); 2313} 2314 2315static vector unsigned char __ATTRS_o_ai 2316vec_lvsr(int __a, const unsigned short *__b) 2317{ 2318 return (vector unsigned char)__builtin_altivec_lvsr(__a, __b); 2319} 2320 2321static vector unsigned char __ATTRS_o_ai 2322vec_lvsr(int __a, const int *__b) 2323{ 2324 return (vector unsigned char)__builtin_altivec_lvsr(__a, __b); 2325} 2326 2327static vector unsigned char __ATTRS_o_ai 2328vec_lvsr(int __a, const unsigned int *__b) 2329{ 2330 return (vector unsigned char)__builtin_altivec_lvsr(__a, __b); 2331} 2332 2333static vector unsigned char __ATTRS_o_ai 2334vec_lvsr(int __a, const float *__b) 2335{ 2336 return (vector unsigned char)__builtin_altivec_lvsr(__a, __b); 2337} 2338 2339/* vec_madd */ 2340 2341static vector float __attribute__((__always_inline__)) 2342vec_madd(vector float __a, vector float __b, vector float __c) 2343{ 2344 return __builtin_altivec_vmaddfp(__a, __b, __c); 2345} 2346 2347/* vec_vmaddfp */ 2348 2349static vector float __attribute__((__always_inline__)) 2350vec_vmaddfp(vector float __a, vector float __b, vector float __c) 2351{ 2352 return __builtin_altivec_vmaddfp(__a, __b, __c); 2353} 2354 2355/* vec_madds */ 2356 2357static vector signed short __attribute__((__always_inline__)) 2358vec_madds(vector signed short __a, vector signed short __b, vector signed short __c) 2359{ 2360 return __builtin_altivec_vmhaddshs(__a, __b, __c); 2361} 2362 2363/* vec_vmhaddshs */ 2364static vector signed short __attribute__((__always_inline__)) 2365vec_vmhaddshs(vector signed short __a, 2366 vector signed short __b, 2367 vector signed short __c) 2368{ 2369 return __builtin_altivec_vmhaddshs(__a, __b, __c); 2370} 2371 2372/* vec_max */ 2373 2374static vector signed char __ATTRS_o_ai 2375vec_max(vector signed char __a, vector signed char __b) 2376{ 2377 return __builtin_altivec_vmaxsb(__a, __b); 2378} 2379 2380static vector signed char __ATTRS_o_ai 2381vec_max(vector bool char __a, vector signed char __b) 2382{ 2383 return __builtin_altivec_vmaxsb((vector signed char)__a, __b); 2384} 2385 2386static vector signed char __ATTRS_o_ai 2387vec_max(vector signed char __a, vector bool char __b) 2388{ 2389 return __builtin_altivec_vmaxsb(__a, (vector signed char)__b); 2390} 2391 2392static vector unsigned char __ATTRS_o_ai 2393vec_max(vector unsigned char __a, vector unsigned char __b) 2394{ 2395 return __builtin_altivec_vmaxub(__a, __b); 2396} 2397 2398static vector unsigned char __ATTRS_o_ai 2399vec_max(vector bool char __a, vector unsigned char __b) 2400{ 2401 return __builtin_altivec_vmaxub((vector unsigned char)__a, __b); 2402} 2403 2404static vector unsigned char __ATTRS_o_ai 2405vec_max(vector unsigned char __a, vector bool char __b) 2406{ 2407 return __builtin_altivec_vmaxub(__a, (vector unsigned char)__b); 2408} 2409 2410static vector short __ATTRS_o_ai 2411vec_max(vector short __a, vector short __b) 2412{ 2413 return __builtin_altivec_vmaxsh(__a, __b); 2414} 2415 2416static vector short __ATTRS_o_ai 2417vec_max(vector bool short __a, vector short __b) 2418{ 2419 return __builtin_altivec_vmaxsh((vector short)__a, __b); 2420} 2421 2422static vector short __ATTRS_o_ai 2423vec_max(vector short __a, vector bool short __b) 2424{ 2425 return __builtin_altivec_vmaxsh(__a, (vector short)__b); 2426} 2427 2428static vector unsigned short __ATTRS_o_ai 2429vec_max(vector unsigned short __a, vector unsigned short __b) 2430{ 2431 return __builtin_altivec_vmaxuh(__a, __b); 2432} 2433 2434static vector unsigned short __ATTRS_o_ai 2435vec_max(vector bool short __a, vector unsigned short __b) 2436{ 2437 return __builtin_altivec_vmaxuh((vector unsigned short)__a, __b); 2438} 2439 2440static vector unsigned short __ATTRS_o_ai 2441vec_max(vector unsigned short __a, vector bool short __b) 2442{ 2443 return __builtin_altivec_vmaxuh(__a, (vector unsigned short)__b); 2444} 2445 2446static vector int __ATTRS_o_ai 2447vec_max(vector int __a, vector int __b) 2448{ 2449 return __builtin_altivec_vmaxsw(__a, __b); 2450} 2451 2452static vector int __ATTRS_o_ai 2453vec_max(vector bool int __a, vector int __b) 2454{ 2455 return __builtin_altivec_vmaxsw((vector int)__a, __b); 2456} 2457 2458static vector int __ATTRS_o_ai 2459vec_max(vector int __a, vector bool int __b) 2460{ 2461 return __builtin_altivec_vmaxsw(__a, (vector int)__b); 2462} 2463 2464static vector unsigned int __ATTRS_o_ai 2465vec_max(vector unsigned int __a, vector unsigned int __b) 2466{ 2467 return __builtin_altivec_vmaxuw(__a, __b); 2468} 2469 2470static vector unsigned int __ATTRS_o_ai 2471vec_max(vector bool int __a, vector unsigned int __b) 2472{ 2473 return __builtin_altivec_vmaxuw((vector unsigned int)__a, __b); 2474} 2475 2476static vector unsigned int __ATTRS_o_ai 2477vec_max(vector unsigned int __a, vector bool int __b) 2478{ 2479 return __builtin_altivec_vmaxuw(__a, (vector unsigned int)__b); 2480} 2481 2482static vector float __ATTRS_o_ai 2483vec_max(vector float __a, vector float __b) 2484{ 2485 return __builtin_altivec_vmaxfp(__a, __b); 2486} 2487 2488/* vec_vmaxsb */ 2489 2490static vector signed char __ATTRS_o_ai 2491vec_vmaxsb(vector signed char __a, vector signed char __b) 2492{ 2493 return __builtin_altivec_vmaxsb(__a, __b); 2494} 2495 2496static vector signed char __ATTRS_o_ai 2497vec_vmaxsb(vector bool char __a, vector signed char __b) 2498{ 2499 return __builtin_altivec_vmaxsb((vector signed char)__a, __b); 2500} 2501 2502static vector signed char __ATTRS_o_ai 2503vec_vmaxsb(vector signed char __a, vector bool char __b) 2504{ 2505 return __builtin_altivec_vmaxsb(__a, (vector signed char)__b); 2506} 2507 2508/* vec_vmaxub */ 2509 2510static vector unsigned char __ATTRS_o_ai 2511vec_vmaxub(vector unsigned char __a, vector unsigned char __b) 2512{ 2513 return __builtin_altivec_vmaxub(__a, __b); 2514} 2515 2516static vector unsigned char __ATTRS_o_ai 2517vec_vmaxub(vector bool char __a, vector unsigned char __b) 2518{ 2519 return __builtin_altivec_vmaxub((vector unsigned char)__a, __b); 2520} 2521 2522static vector unsigned char __ATTRS_o_ai 2523vec_vmaxub(vector unsigned char __a, vector bool char __b) 2524{ 2525 return __builtin_altivec_vmaxub(__a, (vector unsigned char)__b); 2526} 2527 2528/* vec_vmaxsh */ 2529 2530static vector short __ATTRS_o_ai 2531vec_vmaxsh(vector short __a, vector short __b) 2532{ 2533 return __builtin_altivec_vmaxsh(__a, __b); 2534} 2535 2536static vector short __ATTRS_o_ai 2537vec_vmaxsh(vector bool short __a, vector short __b) 2538{ 2539 return __builtin_altivec_vmaxsh((vector short)__a, __b); 2540} 2541 2542static vector short __ATTRS_o_ai 2543vec_vmaxsh(vector short __a, vector bool short __b) 2544{ 2545 return __builtin_altivec_vmaxsh(__a, (vector short)__b); 2546} 2547 2548/* vec_vmaxuh */ 2549 2550static vector unsigned short __ATTRS_o_ai 2551vec_vmaxuh(vector unsigned short __a, vector unsigned short __b) 2552{ 2553 return __builtin_altivec_vmaxuh(__a, __b); 2554} 2555 2556static vector unsigned short __ATTRS_o_ai 2557vec_vmaxuh(vector bool short __a, vector unsigned short __b) 2558{ 2559 return __builtin_altivec_vmaxuh((vector unsigned short)__a, __b); 2560} 2561 2562static vector unsigned short __ATTRS_o_ai 2563vec_vmaxuh(vector unsigned short __a, vector bool short __b) 2564{ 2565 return __builtin_altivec_vmaxuh(__a, (vector unsigned short)__b); 2566} 2567 2568/* vec_vmaxsw */ 2569 2570static vector int __ATTRS_o_ai 2571vec_vmaxsw(vector int __a, vector int __b) 2572{ 2573 return __builtin_altivec_vmaxsw(__a, __b); 2574} 2575 2576static vector int __ATTRS_o_ai 2577vec_vmaxsw(vector bool int __a, vector int __b) 2578{ 2579 return __builtin_altivec_vmaxsw((vector int)__a, __b); 2580} 2581 2582static vector int __ATTRS_o_ai 2583vec_vmaxsw(vector int __a, vector bool int __b) 2584{ 2585 return __builtin_altivec_vmaxsw(__a, (vector int)__b); 2586} 2587 2588/* vec_vmaxuw */ 2589 2590static vector unsigned int __ATTRS_o_ai 2591vec_vmaxuw(vector unsigned int __a, vector unsigned int __b) 2592{ 2593 return __builtin_altivec_vmaxuw(__a, __b); 2594} 2595 2596static vector unsigned int __ATTRS_o_ai 2597vec_vmaxuw(vector bool int __a, vector unsigned int __b) 2598{ 2599 return __builtin_altivec_vmaxuw((vector unsigned int)__a, __b); 2600} 2601 2602static vector unsigned int __ATTRS_o_ai 2603vec_vmaxuw(vector unsigned int __a, vector bool int __b) 2604{ 2605 return __builtin_altivec_vmaxuw(__a, (vector unsigned int)__b); 2606} 2607 2608/* vec_vmaxfp */ 2609 2610static vector float __attribute__((__always_inline__)) 2611vec_vmaxfp(vector float __a, vector float __b) 2612{ 2613 return __builtin_altivec_vmaxfp(__a, __b); 2614} 2615 2616/* vec_mergeh */ 2617 2618static vector signed char __ATTRS_o_ai 2619vec_mergeh(vector signed char __a, vector signed char __b) 2620{ 2621 return vec_perm(__a, __b, (vector unsigned char) 2622 (0x00, 0x10, 0x01, 0x11, 0x02, 0x12, 0x03, 0x13, 2623 0x04, 0x14, 0x05, 0x15, 0x06, 0x16, 0x07, 0x17)); 2624} 2625 2626static vector unsigned char __ATTRS_o_ai 2627vec_mergeh(vector unsigned char __a, vector unsigned char __b) 2628{ 2629 return vec_perm(__a, __b, (vector unsigned char) 2630 (0x00, 0x10, 0x01, 0x11, 0x02, 0x12, 0x03, 0x13, 2631 0x04, 0x14, 0x05, 0x15, 0x06, 0x16, 0x07, 0x17)); 2632} 2633 2634static vector bool char __ATTRS_o_ai 2635vec_mergeh(vector bool char __a, vector bool char __b) 2636{ 2637 return vec_perm(__a, __b, (vector unsigned char) 2638 (0x00, 0x10, 0x01, 0x11, 0x02, 0x12, 0x03, 0x13, 2639 0x04, 0x14, 0x05, 0x15, 0x06, 0x16, 0x07, 0x17)); 2640} 2641 2642static vector short __ATTRS_o_ai 2643vec_mergeh(vector short __a, vector short __b) 2644{ 2645 return vec_perm(__a, __b, (vector unsigned char) 2646 (0x00, 0x01, 0x10, 0x11, 0x02, 0x03, 0x12, 0x13, 2647 0x04, 0x05, 0x14, 0x15, 0x06, 0x07, 0x16, 0x17)); 2648} 2649 2650static vector unsigned short __ATTRS_o_ai 2651vec_mergeh(vector unsigned short __a, vector unsigned short __b) 2652{ 2653 return vec_perm(__a, __b, (vector unsigned char) 2654 (0x00, 0x01, 0x10, 0x11, 0x02, 0x03, 0x12, 0x13, 2655 0x04, 0x05, 0x14, 0x15, 0x06, 0x07, 0x16, 0x17)); 2656} 2657 2658static vector bool short __ATTRS_o_ai 2659vec_mergeh(vector bool short __a, vector bool short __b) 2660{ 2661 return vec_perm(__a, __b, (vector unsigned char) 2662 (0x00, 0x01, 0x10, 0x11, 0x02, 0x03, 0x12, 0x13, 2663 0x04, 0x05, 0x14, 0x15, 0x06, 0x07, 0x16, 0x17)); 2664} 2665 2666static vector pixel __ATTRS_o_ai 2667vec_mergeh(vector pixel __a, vector pixel __b) 2668{ 2669 return vec_perm(__a, __b, (vector unsigned char) 2670 (0x00, 0x01, 0x10, 0x11, 0x02, 0x03, 0x12, 0x13, 2671 0x04, 0x05, 0x14, 0x15, 0x06, 0x07, 0x16, 0x17)); 2672} 2673 2674static vector int __ATTRS_o_ai 2675vec_mergeh(vector int __a, vector int __b) 2676{ 2677 return vec_perm(__a, __b, (vector unsigned char) 2678 (0x00, 0x01, 0x02, 0x03, 0x10, 0x11, 0x12, 0x13, 2679 0x04, 0x05, 0x06, 0x07, 0x14, 0x15, 0x16, 0x17)); 2680} 2681 2682static vector unsigned int __ATTRS_o_ai 2683vec_mergeh(vector unsigned int __a, vector unsigned int __b) 2684{ 2685 return vec_perm(__a, __b, (vector unsigned char) 2686 (0x00, 0x01, 0x02, 0x03, 0x10, 0x11, 0x12, 0x13, 2687 0x04, 0x05, 0x06, 0x07, 0x14, 0x15, 0x16, 0x17)); 2688} 2689 2690static vector bool int __ATTRS_o_ai 2691vec_mergeh(vector bool int __a, vector bool int __b) 2692{ 2693 return vec_perm(__a, __b, (vector unsigned char) 2694 (0x00, 0x01, 0x02, 0x03, 0x10, 0x11, 0x12, 0x13, 2695 0x04, 0x05, 0x06, 0x07, 0x14, 0x15, 0x16, 0x17)); 2696} 2697 2698static vector float __ATTRS_o_ai 2699vec_mergeh(vector float __a, vector float __b) 2700{ 2701 return vec_perm(__a, __b, (vector unsigned char) 2702 (0x00, 0x01, 0x02, 0x03, 0x10, 0x11, 0x12, 0x13, 2703 0x04, 0x05, 0x06, 0x07, 0x14, 0x15, 0x16, 0x17)); 2704} 2705 2706/* vec_vmrghb */ 2707 2708#define __builtin_altivec_vmrghb vec_vmrghb 2709 2710static vector signed char __ATTRS_o_ai 2711vec_vmrghb(vector signed char __a, vector signed char __b) 2712{ 2713 return vec_perm(__a, __b, (vector unsigned char) 2714 (0x00, 0x10, 0x01, 0x11, 0x02, 0x12, 0x03, 0x13, 2715 0x04, 0x14, 0x05, 0x15, 0x06, 0x16, 0x07, 0x17)); 2716} 2717 2718static vector unsigned char __ATTRS_o_ai 2719vec_vmrghb(vector unsigned char __a, vector unsigned char __b) 2720{ 2721 return vec_perm(__a, __b, (vector unsigned char) 2722 (0x00, 0x10, 0x01, 0x11, 0x02, 0x12, 0x03, 0x13, 2723 0x04, 0x14, 0x05, 0x15, 0x06, 0x16, 0x07, 0x17)); 2724} 2725 2726static vector bool char __ATTRS_o_ai 2727vec_vmrghb(vector bool char __a, vector bool char __b) 2728{ 2729 return vec_perm(__a, __b, (vector unsigned char) 2730 (0x00, 0x10, 0x01, 0x11, 0x02, 0x12, 0x03, 0x13, 2731 0x04, 0x14, 0x05, 0x15, 0x06, 0x16, 0x07, 0x17)); 2732} 2733 2734/* vec_vmrghh */ 2735 2736#define __builtin_altivec_vmrghh vec_vmrghh 2737 2738static vector short __ATTRS_o_ai 2739vec_vmrghh(vector short __a, vector short __b) 2740{ 2741 return vec_perm(__a, __b, (vector unsigned char) 2742 (0x00, 0x01, 0x10, 0x11, 0x02, 0x03, 0x12, 0x13, 2743 0x04, 0x05, 0x14, 0x15, 0x06, 0x07, 0x16, 0x17)); 2744} 2745 2746static vector unsigned short __ATTRS_o_ai 2747vec_vmrghh(vector unsigned short __a, vector unsigned short __b) 2748{ 2749 return vec_perm(__a, __b, (vector unsigned char) 2750 (0x00, 0x01, 0x10, 0x11, 0x02, 0x03, 0x12, 0x13, 2751 0x04, 0x05, 0x14, 0x15, 0x06, 0x07, 0x16, 0x17)); 2752} 2753 2754static vector bool short __ATTRS_o_ai 2755vec_vmrghh(vector bool short __a, vector bool short __b) 2756{ 2757 return vec_perm(__a, __b, (vector unsigned char) 2758 (0x00, 0x01, 0x10, 0x11, 0x02, 0x03, 0x12, 0x13, 2759 0x04, 0x05, 0x14, 0x15, 0x06, 0x07, 0x16, 0x17)); 2760} 2761 2762static vector pixel __ATTRS_o_ai 2763vec_vmrghh(vector pixel __a, vector pixel __b) 2764{ 2765 return vec_perm(__a, __b, (vector unsigned char) 2766 (0x00, 0x01, 0x10, 0x11, 0x02, 0x03, 0x12, 0x13, 2767 0x04, 0x05, 0x14, 0x15, 0x06, 0x07, 0x16, 0x17)); 2768} 2769 2770/* vec_vmrghw */ 2771 2772#define __builtin_altivec_vmrghw vec_vmrghw 2773 2774static vector int __ATTRS_o_ai 2775vec_vmrghw(vector int __a, vector int __b) 2776{ 2777 return vec_perm(__a, __b, (vector unsigned char) 2778 (0x00, 0x01, 0x02, 0x03, 0x10, 0x11, 0x12, 0x13, 2779 0x04, 0x05, 0x06, 0x07, 0x14, 0x15, 0x16, 0x17)); 2780} 2781 2782static vector unsigned int __ATTRS_o_ai 2783vec_vmrghw(vector unsigned int __a, vector unsigned int __b) 2784{ 2785 return vec_perm(__a, __b, (vector unsigned char) 2786 (0x00, 0x01, 0x02, 0x03, 0x10, 0x11, 0x12, 0x13, 2787 0x04, 0x05, 0x06, 0x07, 0x14, 0x15, 0x16, 0x17)); 2788} 2789 2790static vector bool int __ATTRS_o_ai 2791vec_vmrghw(vector bool int __a, vector bool int __b) 2792{ 2793 return vec_perm(__a, __b, (vector unsigned char) 2794 (0x00, 0x01, 0x02, 0x03, 0x10, 0x11, 0x12, 0x13, 2795 0x04, 0x05, 0x06, 0x07, 0x14, 0x15, 0x16, 0x17)); 2796} 2797 2798static vector float __ATTRS_o_ai 2799vec_vmrghw(vector float __a, vector float __b) 2800{ 2801 return vec_perm(__a, __b, (vector unsigned char) 2802 (0x00, 0x01, 0x02, 0x03, 0x10, 0x11, 0x12, 0x13, 2803 0x04, 0x05, 0x06, 0x07, 0x14, 0x15, 0x16, 0x17)); 2804} 2805 2806/* vec_mergel */ 2807 2808static vector signed char __ATTRS_o_ai 2809vec_mergel(vector signed char __a, vector signed char __b) 2810{ 2811 return vec_perm(__a, __b, (vector unsigned char) 2812 (0x08, 0x18, 0x09, 0x19, 0x0A, 0x1A, 0x0B, 0x1B, 2813 0x0C, 0x1C, 0x0D, 0x1D, 0x0E, 0x1E, 0x0F, 0x1F)); 2814} 2815 2816static vector unsigned char __ATTRS_o_ai 2817vec_mergel(vector unsigned char __a, vector unsigned char __b) 2818{ 2819 return vec_perm(__a, __b, (vector unsigned char) 2820 (0x08, 0x18, 0x09, 0x19, 0x0A, 0x1A, 0x0B, 0x1B, 2821 0x0C, 0x1C, 0x0D, 0x1D, 0x0E, 0x1E, 0x0F, 0x1F)); 2822} 2823 2824static vector bool char __ATTRS_o_ai 2825vec_mergel(vector bool char __a, vector bool char __b) 2826{ 2827 return vec_perm(__a, __b, (vector unsigned char) 2828 (0x08, 0x18, 0x09, 0x19, 0x0A, 0x1A, 0x0B, 0x1B, 2829 0x0C, 0x1C, 0x0D, 0x1D, 0x0E, 0x1E, 0x0F, 0x1F)); 2830} 2831 2832static vector short __ATTRS_o_ai 2833vec_mergel(vector short __a, vector short __b) 2834{ 2835 return vec_perm(__a, __b, (vector unsigned char) 2836 (0x08, 0x09, 0x18, 0x19, 0x0A, 0x0B, 0x1A, 0x1B, 2837 0x0C, 0x0D, 0x1C, 0x1D, 0x0E, 0x0F, 0x1E, 0x1F)); 2838} 2839 2840static vector unsigned short __ATTRS_o_ai 2841vec_mergel(vector unsigned short __a, vector unsigned short __b) 2842{ 2843 return vec_perm(__a, __b, (vector unsigned char) 2844 (0x08, 0x09, 0x18, 0x19, 0x0A, 0x0B, 0x1A, 0x1B, 2845 0x0C, 0x0D, 0x1C, 0x1D, 0x0E, 0x0F, 0x1E, 0x1F)); 2846} 2847 2848static vector bool short __ATTRS_o_ai 2849vec_mergel(vector bool short __a, vector bool short __b) 2850{ 2851 return vec_perm(__a, __b, (vector unsigned char) 2852 (0x08, 0x09, 0x18, 0x19, 0x0A, 0x0B, 0x1A, 0x1B, 2853 0x0C, 0x0D, 0x1C, 0x1D, 0x0E, 0x0F, 0x1E, 0x1F)); 2854} 2855 2856static vector pixel __ATTRS_o_ai 2857vec_mergel(vector pixel __a, vector pixel __b) 2858{ 2859 return vec_perm(__a, __b, (vector unsigned char) 2860 (0x08, 0x09, 0x18, 0x19, 0x0A, 0x0B, 0x1A, 0x1B, 2861 0x0C, 0x0D, 0x1C, 0x1D, 0x0E, 0x0F, 0x1E, 0x1F)); 2862} 2863 2864static vector int __ATTRS_o_ai 2865vec_mergel(vector int __a, vector int __b) 2866{ 2867 return vec_perm(__a, __b, (vector unsigned char) 2868 (0x08, 0x09, 0x0A, 0x0B, 0x18, 0x19, 0x1A, 0x1B, 2869 0x0C, 0x0D, 0x0E, 0x0F, 0x1C, 0x1D, 0x1E, 0x1F)); 2870} 2871 2872static vector unsigned int __ATTRS_o_ai 2873vec_mergel(vector unsigned int __a, vector unsigned int __b) 2874{ 2875 return vec_perm(__a, __b, (vector unsigned char) 2876 (0x08, 0x09, 0x0A, 0x0B, 0x18, 0x19, 0x1A, 0x1B, 2877 0x0C, 0x0D, 0x0E, 0x0F, 0x1C, 0x1D, 0x1E, 0x1F)); 2878} 2879 2880static vector bool int __ATTRS_o_ai 2881vec_mergel(vector bool int __a, vector bool int __b) 2882{ 2883 return vec_perm(__a, __b, (vector unsigned char) 2884 (0x08, 0x09, 0x0A, 0x0B, 0x18, 0x19, 0x1A, 0x1B, 2885 0x0C, 0x0D, 0x0E, 0x0F, 0x1C, 0x1D, 0x1E, 0x1F)); 2886} 2887 2888static vector float __ATTRS_o_ai 2889vec_mergel(vector float __a, vector float __b) 2890{ 2891 return vec_perm(__a, __b, (vector unsigned char) 2892 (0x08, 0x09, 0x0A, 0x0B, 0x18, 0x19, 0x1A, 0x1B, 2893 0x0C, 0x0D, 0x0E, 0x0F, 0x1C, 0x1D, 0x1E, 0x1F)); 2894} 2895 2896/* vec_vmrglb */ 2897 2898#define __builtin_altivec_vmrglb vec_vmrglb 2899 2900static vector signed char __ATTRS_o_ai 2901vec_vmrglb(vector signed char __a, vector signed char __b) 2902{ 2903 return vec_perm(__a, __b, (vector unsigned char) 2904 (0x08, 0x18, 0x09, 0x19, 0x0A, 0x1A, 0x0B, 0x1B, 2905 0x0C, 0x1C, 0x0D, 0x1D, 0x0E, 0x1E, 0x0F, 0x1F)); 2906} 2907 2908static vector unsigned char __ATTRS_o_ai 2909vec_vmrglb(vector unsigned char __a, vector unsigned char __b) 2910{ 2911 return vec_perm(__a, __b, (vector unsigned char) 2912 (0x08, 0x18, 0x09, 0x19, 0x0A, 0x1A, 0x0B, 0x1B, 2913 0x0C, 0x1C, 0x0D, 0x1D, 0x0E, 0x1E, 0x0F, 0x1F)); 2914} 2915 2916static vector bool char __ATTRS_o_ai 2917vec_vmrglb(vector bool char __a, vector bool char __b) 2918{ 2919 return vec_perm(__a, __b, (vector unsigned char) 2920 (0x08, 0x18, 0x09, 0x19, 0x0A, 0x1A, 0x0B, 0x1B, 2921 0x0C, 0x1C, 0x0D, 0x1D, 0x0E, 0x1E, 0x0F, 0x1F)); 2922} 2923 2924/* vec_vmrglh */ 2925 2926#define __builtin_altivec_vmrglh vec_vmrglh 2927 2928static vector short __ATTRS_o_ai 2929vec_vmrglh(vector short __a, vector short __b) 2930{ 2931 return vec_perm(__a, __b, (vector unsigned char) 2932 (0x08, 0x09, 0x18, 0x19, 0x0A, 0x0B, 0x1A, 0x1B, 2933 0x0C, 0x0D, 0x1C, 0x1D, 0x0E, 0x0F, 0x1E, 0x1F)); 2934} 2935 2936static vector unsigned short __ATTRS_o_ai 2937vec_vmrglh(vector unsigned short __a, vector unsigned short __b) 2938{ 2939 return vec_perm(__a, __b, (vector unsigned char) 2940 (0x08, 0x09, 0x18, 0x19, 0x0A, 0x0B, 0x1A, 0x1B, 2941 0x0C, 0x0D, 0x1C, 0x1D, 0x0E, 0x0F, 0x1E, 0x1F)); 2942} 2943 2944static vector bool short __ATTRS_o_ai 2945vec_vmrglh(vector bool short __a, vector bool short __b) 2946{ 2947 return vec_perm(__a, __b, (vector unsigned char) 2948 (0x08, 0x09, 0x18, 0x19, 0x0A, 0x0B, 0x1A, 0x1B, 2949 0x0C, 0x0D, 0x1C, 0x1D, 0x0E, 0x0F, 0x1E, 0x1F)); 2950} 2951 2952static vector pixel __ATTRS_o_ai 2953vec_vmrglh(vector pixel __a, vector pixel __b) 2954{ 2955 return vec_perm(__a, __b, (vector unsigned char) 2956 (0x08, 0x09, 0x18, 0x19, 0x0A, 0x0B, 0x1A, 0x1B, 2957 0x0C, 0x0D, 0x1C, 0x1D, 0x0E, 0x0F, 0x1E, 0x1F)); 2958} 2959 2960/* vec_vmrglw */ 2961 2962#define __builtin_altivec_vmrglw vec_vmrglw 2963 2964static vector int __ATTRS_o_ai 2965vec_vmrglw(vector int __a, vector int __b) 2966{ 2967 return vec_perm(__a, __b, (vector unsigned char) 2968 (0x08, 0x09, 0x0A, 0x0B, 0x18, 0x19, 0x1A, 0x1B, 2969 0x0C, 0x0D, 0x0E, 0x0F, 0x1C, 0x1D, 0x1E, 0x1F)); 2970} 2971 2972static vector unsigned int __ATTRS_o_ai 2973vec_vmrglw(vector unsigned int __a, vector unsigned int __b) 2974{ 2975 return vec_perm(__a, __b, (vector unsigned char) 2976 (0x08, 0x09, 0x0A, 0x0B, 0x18, 0x19, 0x1A, 0x1B, 2977 0x0C, 0x0D, 0x0E, 0x0F, 0x1C, 0x1D, 0x1E, 0x1F)); 2978} 2979 2980static vector bool int __ATTRS_o_ai 2981vec_vmrglw(vector bool int __a, vector bool int __b) 2982{ 2983 return vec_perm(__a, __b, (vector unsigned char) 2984 (0x08, 0x09, 0x0A, 0x0B, 0x18, 0x19, 0x1A, 0x1B, 2985 0x0C, 0x0D, 0x0E, 0x0F, 0x1C, 0x1D, 0x1E, 0x1F)); 2986} 2987 2988static vector float __ATTRS_o_ai 2989vec_vmrglw(vector float __a, vector float __b) 2990{ 2991 return vec_perm(__a, __b, (vector unsigned char) 2992 (0x08, 0x09, 0x0A, 0x0B, 0x18, 0x19, 0x1A, 0x1B, 2993 0x0C, 0x0D, 0x0E, 0x0F, 0x1C, 0x1D, 0x1E, 0x1F)); 2994} 2995 2996/* vec_mfvscr */ 2997 2998static vector unsigned short __attribute__((__always_inline__)) 2999vec_mfvscr(void) 3000{ 3001 return __builtin_altivec_mfvscr(); 3002} 3003 3004/* vec_min */ 3005 3006static vector signed char __ATTRS_o_ai 3007vec_min(vector signed char __a, vector signed char __b) 3008{ 3009 return __builtin_altivec_vminsb(__a, __b); 3010} 3011 3012static vector signed char __ATTRS_o_ai 3013vec_min(vector bool char __a, vector signed char __b) 3014{ 3015 return __builtin_altivec_vminsb((vector signed char)__a, __b); 3016} 3017 3018static vector signed char __ATTRS_o_ai 3019vec_min(vector signed char __a, vector bool char __b) 3020{ 3021 return __builtin_altivec_vminsb(__a, (vector signed char)__b); 3022} 3023 3024static vector unsigned char __ATTRS_o_ai 3025vec_min(vector unsigned char __a, vector unsigned char __b) 3026{ 3027 return __builtin_altivec_vminub(__a, __b); 3028} 3029 3030static vector unsigned char __ATTRS_o_ai 3031vec_min(vector bool char __a, vector unsigned char __b) 3032{ 3033 return __builtin_altivec_vminub((vector unsigned char)__a, __b); 3034} 3035 3036static vector unsigned char __ATTRS_o_ai 3037vec_min(vector unsigned char __a, vector bool char __b) 3038{ 3039 return __builtin_altivec_vminub(__a, (vector unsigned char)__b); 3040} 3041 3042static vector short __ATTRS_o_ai 3043vec_min(vector short __a, vector short __b) 3044{ 3045 return __builtin_altivec_vminsh(__a, __b); 3046} 3047 3048static vector short __ATTRS_o_ai 3049vec_min(vector bool short __a, vector short __b) 3050{ 3051 return __builtin_altivec_vminsh((vector short)__a, __b); 3052} 3053 3054static vector short __ATTRS_o_ai 3055vec_min(vector short __a, vector bool short __b) 3056{ 3057 return __builtin_altivec_vminsh(__a, (vector short)__b); 3058} 3059 3060static vector unsigned short __ATTRS_o_ai 3061vec_min(vector unsigned short __a, vector unsigned short __b) 3062{ 3063 return __builtin_altivec_vminuh(__a, __b); 3064} 3065 3066static vector unsigned short __ATTRS_o_ai 3067vec_min(vector bool short __a, vector unsigned short __b) 3068{ 3069 return __builtin_altivec_vminuh((vector unsigned short)__a, __b); 3070} 3071 3072static vector unsigned short __ATTRS_o_ai 3073vec_min(vector unsigned short __a, vector bool short __b) 3074{ 3075 return __builtin_altivec_vminuh(__a, (vector unsigned short)__b); 3076} 3077 3078static vector int __ATTRS_o_ai 3079vec_min(vector int __a, vector int __b) 3080{ 3081 return __builtin_altivec_vminsw(__a, __b); 3082} 3083 3084static vector int __ATTRS_o_ai 3085vec_min(vector bool int __a, vector int __b) 3086{ 3087 return __builtin_altivec_vminsw((vector int)__a, __b); 3088} 3089 3090static vector int __ATTRS_o_ai 3091vec_min(vector int __a, vector bool int __b) 3092{ 3093 return __builtin_altivec_vminsw(__a, (vector int)__b); 3094} 3095 3096static vector unsigned int __ATTRS_o_ai 3097vec_min(vector unsigned int __a, vector unsigned int __b) 3098{ 3099 return __builtin_altivec_vminuw(__a, __b); 3100} 3101 3102static vector unsigned int __ATTRS_o_ai 3103vec_min(vector bool int __a, vector unsigned int __b) 3104{ 3105 return __builtin_altivec_vminuw((vector unsigned int)__a, __b); 3106} 3107 3108static vector unsigned int __ATTRS_o_ai 3109vec_min(vector unsigned int __a, vector bool int __b) 3110{ 3111 return __builtin_altivec_vminuw(__a, (vector unsigned int)__b); 3112} 3113 3114static vector float __ATTRS_o_ai 3115vec_min(vector float __a, vector float __b) 3116{ 3117 return __builtin_altivec_vminfp(__a, __b); 3118} 3119 3120/* vec_vminsb */ 3121 3122static vector signed char __ATTRS_o_ai 3123vec_vminsb(vector signed char __a, vector signed char __b) 3124{ 3125 return __builtin_altivec_vminsb(__a, __b); 3126} 3127 3128static vector signed char __ATTRS_o_ai 3129vec_vminsb(vector bool char __a, vector signed char __b) 3130{ 3131 return __builtin_altivec_vminsb((vector signed char)__a, __b); 3132} 3133 3134static vector signed char __ATTRS_o_ai 3135vec_vminsb(vector signed char __a, vector bool char __b) 3136{ 3137 return __builtin_altivec_vminsb(__a, (vector signed char)__b); 3138} 3139 3140/* vec_vminub */ 3141 3142static vector unsigned char __ATTRS_o_ai 3143vec_vminub(vector unsigned char __a, vector unsigned char __b) 3144{ 3145 return __builtin_altivec_vminub(__a, __b); 3146} 3147 3148static vector unsigned char __ATTRS_o_ai 3149vec_vminub(vector bool char __a, vector unsigned char __b) 3150{ 3151 return __builtin_altivec_vminub((vector unsigned char)__a, __b); 3152} 3153 3154static vector unsigned char __ATTRS_o_ai 3155vec_vminub(vector unsigned char __a, vector bool char __b) 3156{ 3157 return __builtin_altivec_vminub(__a, (vector unsigned char)__b); 3158} 3159 3160/* vec_vminsh */ 3161 3162static vector short __ATTRS_o_ai 3163vec_vminsh(vector short __a, vector short __b) 3164{ 3165 return __builtin_altivec_vminsh(__a, __b); 3166} 3167 3168static vector short __ATTRS_o_ai 3169vec_vminsh(vector bool short __a, vector short __b) 3170{ 3171 return __builtin_altivec_vminsh((vector short)__a, __b); 3172} 3173 3174static vector short __ATTRS_o_ai 3175vec_vminsh(vector short __a, vector bool short __b) 3176{ 3177 return __builtin_altivec_vminsh(__a, (vector short)__b); 3178} 3179 3180/* vec_vminuh */ 3181 3182static vector unsigned short __ATTRS_o_ai 3183vec_vminuh(vector unsigned short __a, vector unsigned short __b) 3184{ 3185 return __builtin_altivec_vminuh(__a, __b); 3186} 3187 3188static vector unsigned short __ATTRS_o_ai 3189vec_vminuh(vector bool short __a, vector unsigned short __b) 3190{ 3191 return __builtin_altivec_vminuh((vector unsigned short)__a, __b); 3192} 3193 3194static vector unsigned short __ATTRS_o_ai 3195vec_vminuh(vector unsigned short __a, vector bool short __b) 3196{ 3197 return __builtin_altivec_vminuh(__a, (vector unsigned short)__b); 3198} 3199 3200/* vec_vminsw */ 3201 3202static vector int __ATTRS_o_ai 3203vec_vminsw(vector int __a, vector int __b) 3204{ 3205 return __builtin_altivec_vminsw(__a, __b); 3206} 3207 3208static vector int __ATTRS_o_ai 3209vec_vminsw(vector bool int __a, vector int __b) 3210{ 3211 return __builtin_altivec_vminsw((vector int)__a, __b); 3212} 3213 3214static vector int __ATTRS_o_ai 3215vec_vminsw(vector int __a, vector bool int __b) 3216{ 3217 return __builtin_altivec_vminsw(__a, (vector int)__b); 3218} 3219 3220/* vec_vminuw */ 3221 3222static vector unsigned int __ATTRS_o_ai 3223vec_vminuw(vector unsigned int __a, vector unsigned int __b) 3224{ 3225 return __builtin_altivec_vminuw(__a, __b); 3226} 3227 3228static vector unsigned int __ATTRS_o_ai 3229vec_vminuw(vector bool int __a, vector unsigned int __b) 3230{ 3231 return __builtin_altivec_vminuw((vector unsigned int)__a, __b); 3232} 3233 3234static vector unsigned int __ATTRS_o_ai 3235vec_vminuw(vector unsigned int __a, vector bool int __b) 3236{ 3237 return __builtin_altivec_vminuw(__a, (vector unsigned int)__b); 3238} 3239 3240/* vec_vminfp */ 3241 3242static vector float __attribute__((__always_inline__)) 3243vec_vminfp(vector float __a, vector float __b) 3244{ 3245 return __builtin_altivec_vminfp(__a, __b); 3246} 3247 3248/* vec_mladd */ 3249 3250#define __builtin_altivec_vmladduhm vec_mladd 3251 3252static vector short __ATTRS_o_ai 3253vec_mladd(vector short __a, vector short __b, vector short __c) 3254{ 3255 return __a * __b + __c; 3256} 3257 3258static vector short __ATTRS_o_ai 3259vec_mladd(vector short __a, vector unsigned short __b, vector unsigned short __c) 3260{ 3261 return __a * (vector short)__b + (vector short)__c; 3262} 3263 3264static vector short __ATTRS_o_ai 3265vec_mladd(vector unsigned short __a, vector short __b, vector short __c) 3266{ 3267 return (vector short)__a * __b + __c; 3268} 3269 3270static vector unsigned short __ATTRS_o_ai 3271vec_mladd(vector unsigned short __a, 3272 vector unsigned short __b, 3273 vector unsigned short __c) 3274{ 3275 return __a * __b + __c; 3276} 3277 3278/* vec_vmladduhm */ 3279 3280static vector short __ATTRS_o_ai 3281vec_vmladduhm(vector short __a, vector short __b, vector short __c) 3282{ 3283 return __a * __b + __c; 3284} 3285 3286static vector short __ATTRS_o_ai 3287vec_vmladduhm(vector short __a, vector unsigned short __b, vector unsigned short __c) 3288{ 3289 return __a * (vector short)__b + (vector short)__c; 3290} 3291 3292static vector short __ATTRS_o_ai 3293vec_vmladduhm(vector unsigned short __a, vector short __b, vector short __c) 3294{ 3295 return (vector short)__a * __b + __c; 3296} 3297 3298static vector unsigned short __ATTRS_o_ai 3299vec_vmladduhm(vector unsigned short __a, 3300 vector unsigned short __b, 3301 vector unsigned short __c) 3302{ 3303 return __a * __b + __c; 3304} 3305 3306/* vec_mradds */ 3307 3308static vector short __attribute__((__always_inline__)) 3309vec_mradds(vector short __a, vector short __b, vector short __c) 3310{ 3311 return __builtin_altivec_vmhraddshs(__a, __b, __c); 3312} 3313 3314/* vec_vmhraddshs */ 3315 3316static vector short __attribute__((__always_inline__)) 3317vec_vmhraddshs(vector short __a, vector short __b, vector short __c) 3318{ 3319 return __builtin_altivec_vmhraddshs(__a, __b, __c); 3320} 3321 3322/* vec_msum */ 3323 3324static vector int __ATTRS_o_ai 3325vec_msum(vector signed char __a, vector unsigned char __b, vector int __c) 3326{ 3327 return __builtin_altivec_vmsummbm(__a, __b, __c); 3328} 3329 3330static vector unsigned int __ATTRS_o_ai 3331vec_msum(vector unsigned char __a, vector unsigned char __b, vector unsigned int __c) 3332{ 3333 return __builtin_altivec_vmsumubm(__a, __b, __c); 3334} 3335 3336static vector int __ATTRS_o_ai 3337vec_msum(vector short __a, vector short __b, vector int __c) 3338{ 3339 return __builtin_altivec_vmsumshm(__a, __b, __c); 3340} 3341 3342static vector unsigned int __ATTRS_o_ai 3343vec_msum(vector unsigned short __a, 3344 vector unsigned short __b, 3345 vector unsigned int __c) 3346{ 3347 return __builtin_altivec_vmsumuhm(__a, __b, __c); 3348} 3349 3350/* vec_vmsummbm */ 3351 3352static vector int __attribute__((__always_inline__)) 3353vec_vmsummbm(vector signed char __a, vector unsigned char __b, vector int __c) 3354{ 3355 return __builtin_altivec_vmsummbm(__a, __b, __c); 3356} 3357 3358/* vec_vmsumubm */ 3359 3360static vector unsigned int __attribute__((__always_inline__)) 3361vec_vmsumubm(vector unsigned char __a, 3362 vector unsigned char __b, 3363 vector unsigned int __c) 3364{ 3365 return __builtin_altivec_vmsumubm(__a, __b, __c); 3366} 3367 3368/* vec_vmsumshm */ 3369 3370static vector int __attribute__((__always_inline__)) 3371vec_vmsumshm(vector short __a, vector short __b, vector int __c) 3372{ 3373 return __builtin_altivec_vmsumshm(__a, __b, __c); 3374} 3375 3376/* vec_vmsumuhm */ 3377 3378static vector unsigned int __attribute__((__always_inline__)) 3379vec_vmsumuhm(vector unsigned short __a, 3380 vector unsigned short __b, 3381 vector unsigned int __c) 3382{ 3383 return __builtin_altivec_vmsumuhm(__a, __b, __c); 3384} 3385 3386/* vec_msums */ 3387 3388static vector int __ATTRS_o_ai 3389vec_msums(vector short __a, vector short __b, vector int __c) 3390{ 3391 return __builtin_altivec_vmsumshs(__a, __b, __c); 3392} 3393 3394static vector unsigned int __ATTRS_o_ai 3395vec_msums(vector unsigned short __a, 3396 vector unsigned short __b, 3397 vector unsigned int __c) 3398{ 3399 return __builtin_altivec_vmsumuhs(__a, __b, __c); 3400} 3401 3402/* vec_vmsumshs */ 3403 3404static vector int __attribute__((__always_inline__)) 3405vec_vmsumshs(vector short __a, vector short __b, vector int __c) 3406{ 3407 return __builtin_altivec_vmsumshs(__a, __b, __c); 3408} 3409 3410/* vec_vmsumuhs */ 3411 3412static vector unsigned int __attribute__((__always_inline__)) 3413vec_vmsumuhs(vector unsigned short __a, 3414 vector unsigned short __b, 3415 vector unsigned int __c) 3416{ 3417 return __builtin_altivec_vmsumuhs(__a, __b, __c); 3418} 3419 3420/* vec_mtvscr */ 3421 3422static void __ATTRS_o_ai 3423vec_mtvscr(vector signed char __a) 3424{ 3425 __builtin_altivec_mtvscr((vector int)__a); 3426} 3427 3428static void __ATTRS_o_ai 3429vec_mtvscr(vector unsigned char __a) 3430{ 3431 __builtin_altivec_mtvscr((vector int)__a); 3432} 3433 3434static void __ATTRS_o_ai 3435vec_mtvscr(vector bool char __a) 3436{ 3437 __builtin_altivec_mtvscr((vector int)__a); 3438} 3439 3440static void __ATTRS_o_ai 3441vec_mtvscr(vector short __a) 3442{ 3443 __builtin_altivec_mtvscr((vector int)__a); 3444} 3445 3446static void __ATTRS_o_ai 3447vec_mtvscr(vector unsigned short __a) 3448{ 3449 __builtin_altivec_mtvscr((vector int)__a); 3450} 3451 3452static void __ATTRS_o_ai 3453vec_mtvscr(vector bool short __a) 3454{ 3455 __builtin_altivec_mtvscr((vector int)__a); 3456} 3457 3458static void __ATTRS_o_ai 3459vec_mtvscr(vector pixel __a) 3460{ 3461 __builtin_altivec_mtvscr((vector int)__a); 3462} 3463 3464static void __ATTRS_o_ai 3465vec_mtvscr(vector int __a) 3466{ 3467 __builtin_altivec_mtvscr((vector int)__a); 3468} 3469 3470static void __ATTRS_o_ai 3471vec_mtvscr(vector unsigned int __a) 3472{ 3473 __builtin_altivec_mtvscr((vector int)__a); 3474} 3475 3476static void __ATTRS_o_ai 3477vec_mtvscr(vector bool int __a) 3478{ 3479 __builtin_altivec_mtvscr((vector int)__a); 3480} 3481 3482static void __ATTRS_o_ai 3483vec_mtvscr(vector float __a) 3484{ 3485 __builtin_altivec_mtvscr((vector int)__a); 3486} 3487 3488/* vec_mule */ 3489 3490static vector short __ATTRS_o_ai 3491vec_mule(vector signed char __a, vector signed char __b) 3492{ 3493 return __builtin_altivec_vmulesb(__a, __b); 3494} 3495 3496static vector unsigned short __ATTRS_o_ai 3497vec_mule(vector unsigned char __a, vector unsigned char __b) 3498{ 3499 return __builtin_altivec_vmuleub(__a, __b); 3500} 3501 3502static vector int __ATTRS_o_ai 3503vec_mule(vector short __a, vector short __b) 3504{ 3505 return __builtin_altivec_vmulesh(__a, __b); 3506} 3507 3508static vector unsigned int __ATTRS_o_ai 3509vec_mule(vector unsigned short __a, vector unsigned short __b) 3510{ 3511 return __builtin_altivec_vmuleuh(__a, __b); 3512} 3513 3514/* vec_vmulesb */ 3515 3516static vector short __attribute__((__always_inline__)) 3517vec_vmulesb(vector signed char __a, vector signed char __b) 3518{ 3519 return __builtin_altivec_vmulesb(__a, __b); 3520} 3521 3522/* vec_vmuleub */ 3523 3524static vector unsigned short __attribute__((__always_inline__)) 3525vec_vmuleub(vector unsigned char __a, vector unsigned char __b) 3526{ 3527 return __builtin_altivec_vmuleub(__a, __b); 3528} 3529 3530/* vec_vmulesh */ 3531 3532static vector int __attribute__((__always_inline__)) 3533vec_vmulesh(vector short __a, vector short __b) 3534{ 3535 return __builtin_altivec_vmulesh(__a, __b); 3536} 3537 3538/* vec_vmuleuh */ 3539 3540static vector unsigned int __attribute__((__always_inline__)) 3541vec_vmuleuh(vector unsigned short __a, vector unsigned short __b) 3542{ 3543 return __builtin_altivec_vmuleuh(__a, __b); 3544} 3545 3546/* vec_mulo */ 3547 3548static vector short __ATTRS_o_ai 3549vec_mulo(vector signed char __a, vector signed char __b) 3550{ 3551 return __builtin_altivec_vmulosb(__a, __b); 3552} 3553 3554static vector unsigned short __ATTRS_o_ai 3555vec_mulo(vector unsigned char __a, vector unsigned char __b) 3556{ 3557 return __builtin_altivec_vmuloub(__a, __b); 3558} 3559 3560static vector int __ATTRS_o_ai 3561vec_mulo(vector short __a, vector short __b) 3562{ 3563 return __builtin_altivec_vmulosh(__a, __b); 3564} 3565 3566static vector unsigned int __ATTRS_o_ai 3567vec_mulo(vector unsigned short __a, vector unsigned short __b) 3568{ 3569 return __builtin_altivec_vmulouh(__a, __b); 3570} 3571 3572/* vec_vmulosb */ 3573 3574static vector short __attribute__((__always_inline__)) 3575vec_vmulosb(vector signed char __a, vector signed char __b) 3576{ 3577 return __builtin_altivec_vmulosb(__a, __b); 3578} 3579 3580/* vec_vmuloub */ 3581 3582static vector unsigned short __attribute__((__always_inline__)) 3583vec_vmuloub(vector unsigned char __a, vector unsigned char __b) 3584{ 3585 return __builtin_altivec_vmuloub(__a, __b); 3586} 3587 3588/* vec_vmulosh */ 3589 3590static vector int __attribute__((__always_inline__)) 3591vec_vmulosh(vector short __a, vector short __b) 3592{ 3593 return __builtin_altivec_vmulosh(__a, __b); 3594} 3595 3596/* vec_vmulouh */ 3597 3598static vector unsigned int __attribute__((__always_inline__)) 3599vec_vmulouh(vector unsigned short __a, vector unsigned short __b) 3600{ 3601 return __builtin_altivec_vmulouh(__a, __b); 3602} 3603 3604/* vec_nmsub */ 3605 3606static vector float __attribute__((__always_inline__)) 3607vec_nmsub(vector float __a, vector float __b, vector float __c) 3608{ 3609 return __builtin_altivec_vnmsubfp(__a, __b, __c); 3610} 3611 3612/* vec_vnmsubfp */ 3613 3614static vector float __attribute__((__always_inline__)) 3615vec_vnmsubfp(vector float __a, vector float __b, vector float __c) 3616{ 3617 return __builtin_altivec_vnmsubfp(__a, __b, __c); 3618} 3619 3620/* vec_nor */ 3621 3622#define __builtin_altivec_vnor vec_nor 3623 3624static vector signed char __ATTRS_o_ai 3625vec_nor(vector signed char __a, vector signed char __b) 3626{ 3627 return ~(__a | __b); 3628} 3629 3630static vector unsigned char __ATTRS_o_ai 3631vec_nor(vector unsigned char __a, vector unsigned char __b) 3632{ 3633 return ~(__a | __b); 3634} 3635 3636static vector bool char __ATTRS_o_ai 3637vec_nor(vector bool char __a, vector bool char __b) 3638{ 3639 return ~(__a | __b); 3640} 3641 3642static vector short __ATTRS_o_ai 3643vec_nor(vector short __a, vector short __b) 3644{ 3645 return ~(__a | __b); 3646} 3647 3648static vector unsigned short __ATTRS_o_ai 3649vec_nor(vector unsigned short __a, vector unsigned short __b) 3650{ 3651 return ~(__a | __b); 3652} 3653 3654static vector bool short __ATTRS_o_ai 3655vec_nor(vector bool short __a, vector bool short __b) 3656{ 3657 return ~(__a | __b); 3658} 3659 3660static vector int __ATTRS_o_ai 3661vec_nor(vector int __a, vector int __b) 3662{ 3663 return ~(__a | __b); 3664} 3665 3666static vector unsigned int __ATTRS_o_ai 3667vec_nor(vector unsigned int __a, vector unsigned int __b) 3668{ 3669 return ~(__a | __b); 3670} 3671 3672static vector bool int __ATTRS_o_ai 3673vec_nor(vector bool int __a, vector bool int __b) 3674{ 3675 return ~(__a | __b); 3676} 3677 3678static vector float __ATTRS_o_ai 3679vec_nor(vector float __a, vector float __b) 3680{ 3681 vector unsigned int __res = ~((vector unsigned int)__a | (vector unsigned int)__b); 3682 return (vector float)__res; 3683} 3684 3685/* vec_vnor */ 3686 3687static vector signed char __ATTRS_o_ai 3688vec_vnor(vector signed char __a, vector signed char __b) 3689{ 3690 return ~(__a | __b); 3691} 3692 3693static vector unsigned char __ATTRS_o_ai 3694vec_vnor(vector unsigned char __a, vector unsigned char __b) 3695{ 3696 return ~(__a | __b); 3697} 3698 3699static vector bool char __ATTRS_o_ai 3700vec_vnor(vector bool char __a, vector bool char __b) 3701{ 3702 return ~(__a | __b); 3703} 3704 3705static vector short __ATTRS_o_ai 3706vec_vnor(vector short __a, vector short __b) 3707{ 3708 return ~(__a | __b); 3709} 3710 3711static vector unsigned short __ATTRS_o_ai 3712vec_vnor(vector unsigned short __a, vector unsigned short __b) 3713{ 3714 return ~(__a | __b); 3715} 3716 3717static vector bool short __ATTRS_o_ai 3718vec_vnor(vector bool short __a, vector bool short __b) 3719{ 3720 return ~(__a | __b); 3721} 3722 3723static vector int __ATTRS_o_ai 3724vec_vnor(vector int __a, vector int __b) 3725{ 3726 return ~(__a | __b); 3727} 3728 3729static vector unsigned int __ATTRS_o_ai 3730vec_vnor(vector unsigned int __a, vector unsigned int __b) 3731{ 3732 return ~(__a | __b); 3733} 3734 3735static vector bool int __ATTRS_o_ai 3736vec_vnor(vector bool int __a, vector bool int __b) 3737{ 3738 return ~(__a | __b); 3739} 3740 3741static vector float __ATTRS_o_ai 3742vec_vnor(vector float __a, vector float __b) 3743{ 3744 vector unsigned int __res = ~((vector unsigned int)__a | (vector unsigned int)__b); 3745 return (vector float)__res; 3746} 3747 3748/* vec_or */ 3749 3750#define __builtin_altivec_vor vec_or 3751 3752static vector signed char __ATTRS_o_ai 3753vec_or(vector signed char __a, vector signed char __b) 3754{ 3755 return __a | __b; 3756} 3757 3758static vector signed char __ATTRS_o_ai 3759vec_or(vector bool char __a, vector signed char __b) 3760{ 3761 return (vector signed char)__a | __b; 3762} 3763 3764static vector signed char __ATTRS_o_ai 3765vec_or(vector signed char __a, vector bool char __b) 3766{ 3767 return __a | (vector signed char)__b; 3768} 3769 3770static vector unsigned char __ATTRS_o_ai 3771vec_or(vector unsigned char __a, vector unsigned char __b) 3772{ 3773 return __a | __b; 3774} 3775 3776static vector unsigned char __ATTRS_o_ai 3777vec_or(vector bool char __a, vector unsigned char __b) 3778{ 3779 return (vector unsigned char)__a | __b; 3780} 3781 3782static vector unsigned char __ATTRS_o_ai 3783vec_or(vector unsigned char __a, vector bool char __b) 3784{ 3785 return __a | (vector unsigned char)__b; 3786} 3787 3788static vector bool char __ATTRS_o_ai 3789vec_or(vector bool char __a, vector bool char __b) 3790{ 3791 return __a | __b; 3792} 3793 3794static vector short __ATTRS_o_ai 3795vec_or(vector short __a, vector short __b) 3796{ 3797 return __a | __b; 3798} 3799 3800static vector short __ATTRS_o_ai 3801vec_or(vector bool short __a, vector short __b) 3802{ 3803 return (vector short)__a | __b; 3804} 3805 3806static vector short __ATTRS_o_ai 3807vec_or(vector short __a, vector bool short __b) 3808{ 3809 return __a | (vector short)__b; 3810} 3811 3812static vector unsigned short __ATTRS_o_ai 3813vec_or(vector unsigned short __a, vector unsigned short __b) 3814{ 3815 return __a | __b; 3816} 3817 3818static vector unsigned short __ATTRS_o_ai 3819vec_or(vector bool short __a, vector unsigned short __b) 3820{ 3821 return (vector unsigned short)__a | __b; 3822} 3823 3824static vector unsigned short __ATTRS_o_ai 3825vec_or(vector unsigned short __a, vector bool short __b) 3826{ 3827 return __a | (vector unsigned short)__b; 3828} 3829 3830static vector bool short __ATTRS_o_ai 3831vec_or(vector bool short __a, vector bool short __b) 3832{ 3833 return __a | __b; 3834} 3835 3836static vector int __ATTRS_o_ai 3837vec_or(vector int __a, vector int __b) 3838{ 3839 return __a | __b; 3840} 3841 3842static vector int __ATTRS_o_ai 3843vec_or(vector bool int __a, vector int __b) 3844{ 3845 return (vector int)__a | __b; 3846} 3847 3848static vector int __ATTRS_o_ai 3849vec_or(vector int __a, vector bool int __b) 3850{ 3851 return __a | (vector int)__b; 3852} 3853 3854static vector unsigned int __ATTRS_o_ai 3855vec_or(vector unsigned int __a, vector unsigned int __b) 3856{ 3857 return __a | __b; 3858} 3859 3860static vector unsigned int __ATTRS_o_ai 3861vec_or(vector bool int __a, vector unsigned int __b) 3862{ 3863 return (vector unsigned int)__a | __b; 3864} 3865 3866static vector unsigned int __ATTRS_o_ai 3867vec_or(vector unsigned int __a, vector bool int __b) 3868{ 3869 return __a | (vector unsigned int)__b; 3870} 3871 3872static vector bool int __ATTRS_o_ai 3873vec_or(vector bool int __a, vector bool int __b) 3874{ 3875 return __a | __b; 3876} 3877 3878static vector float __ATTRS_o_ai 3879vec_or(vector float __a, vector float __b) 3880{ 3881 vector unsigned int __res = (vector unsigned int)__a | (vector unsigned int)__b; 3882 return (vector float)__res; 3883} 3884 3885static vector float __ATTRS_o_ai 3886vec_or(vector bool int __a, vector float __b) 3887{ 3888 vector unsigned int __res = (vector unsigned int)__a | (vector unsigned int)__b; 3889 return (vector float)__res; 3890} 3891 3892static vector float __ATTRS_o_ai 3893vec_or(vector float __a, vector bool int __b) 3894{ 3895 vector unsigned int __res = (vector unsigned int)__a | (vector unsigned int)__b; 3896 return (vector float)__res; 3897} 3898 3899/* vec_vor */ 3900 3901static vector signed char __ATTRS_o_ai 3902vec_vor(vector signed char __a, vector signed char __b) 3903{ 3904 return __a | __b; 3905} 3906 3907static vector signed char __ATTRS_o_ai 3908vec_vor(vector bool char __a, vector signed char __b) 3909{ 3910 return (vector signed char)__a | __b; 3911} 3912 3913static vector signed char __ATTRS_o_ai 3914vec_vor(vector signed char __a, vector bool char __b) 3915{ 3916 return __a | (vector signed char)__b; 3917} 3918 3919static vector unsigned char __ATTRS_o_ai 3920vec_vor(vector unsigned char __a, vector unsigned char __b) 3921{ 3922 return __a | __b; 3923} 3924 3925static vector unsigned char __ATTRS_o_ai 3926vec_vor(vector bool char __a, vector unsigned char __b) 3927{ 3928 return (vector unsigned char)__a | __b; 3929} 3930 3931static vector unsigned char __ATTRS_o_ai 3932vec_vor(vector unsigned char __a, vector bool char __b) 3933{ 3934 return __a | (vector unsigned char)__b; 3935} 3936 3937static vector bool char __ATTRS_o_ai 3938vec_vor(vector bool char __a, vector bool char __b) 3939{ 3940 return __a | __b; 3941} 3942 3943static vector short __ATTRS_o_ai 3944vec_vor(vector short __a, vector short __b) 3945{ 3946 return __a | __b; 3947} 3948 3949static vector short __ATTRS_o_ai 3950vec_vor(vector bool short __a, vector short __b) 3951{ 3952 return (vector short)__a | __b; 3953} 3954 3955static vector short __ATTRS_o_ai 3956vec_vor(vector short __a, vector bool short __b) 3957{ 3958 return __a | (vector short)__b; 3959} 3960 3961static vector unsigned short __ATTRS_o_ai 3962vec_vor(vector unsigned short __a, vector unsigned short __b) 3963{ 3964 return __a | __b; 3965} 3966 3967static vector unsigned short __ATTRS_o_ai 3968vec_vor(vector bool short __a, vector unsigned short __b) 3969{ 3970 return (vector unsigned short)__a | __b; 3971} 3972 3973static vector unsigned short __ATTRS_o_ai 3974vec_vor(vector unsigned short __a, vector bool short __b) 3975{ 3976 return __a | (vector unsigned short)__b; 3977} 3978 3979static vector bool short __ATTRS_o_ai 3980vec_vor(vector bool short __a, vector bool short __b) 3981{ 3982 return __a | __b; 3983} 3984 3985static vector int __ATTRS_o_ai 3986vec_vor(vector int __a, vector int __b) 3987{ 3988 return __a | __b; 3989} 3990 3991static vector int __ATTRS_o_ai 3992vec_vor(vector bool int __a, vector int __b) 3993{ 3994 return (vector int)__a | __b; 3995} 3996 3997static vector int __ATTRS_o_ai 3998vec_vor(vector int __a, vector bool int __b) 3999{ 4000 return __a | (vector int)__b; 4001} 4002 4003static vector unsigned int __ATTRS_o_ai 4004vec_vor(vector unsigned int __a, vector unsigned int __b) 4005{ 4006 return __a | __b; 4007} 4008 4009static vector unsigned int __ATTRS_o_ai 4010vec_vor(vector bool int __a, vector unsigned int __b) 4011{ 4012 return (vector unsigned int)__a | __b; 4013} 4014 4015static vector unsigned int __ATTRS_o_ai 4016vec_vor(vector unsigned int __a, vector bool int __b) 4017{ 4018 return __a | (vector unsigned int)__b; 4019} 4020 4021static vector bool int __ATTRS_o_ai 4022vec_vor(vector bool int __a, vector bool int __b) 4023{ 4024 return __a | __b; 4025} 4026 4027static vector float __ATTRS_o_ai 4028vec_vor(vector float __a, vector float __b) 4029{ 4030 vector unsigned int __res = (vector unsigned int)__a | (vector unsigned int)__b; 4031 return (vector float)__res; 4032} 4033 4034static vector float __ATTRS_o_ai 4035vec_vor(vector bool int __a, vector float __b) 4036{ 4037 vector unsigned int __res = (vector unsigned int)__a | (vector unsigned int)__b; 4038 return (vector float)__res; 4039} 4040 4041static vector float __ATTRS_o_ai 4042vec_vor(vector float __a, vector bool int __b) 4043{ 4044 vector unsigned int __res = (vector unsigned int)__a | (vector unsigned int)__b; 4045 return (vector float)__res; 4046} 4047 4048/* vec_pack */ 4049 4050static vector signed char __ATTRS_o_ai 4051vec_pack(vector signed short __a, vector signed short __b) 4052{ 4053 return (vector signed char)vec_perm(__a, __b, (vector unsigned char) 4054 (0x01, 0x03, 0x05, 0x07, 0x09, 0x0B, 0x0D, 0x0F, 4055 0x11, 0x13, 0x15, 0x17, 0x19, 0x1B, 0x1D, 0x1F)); 4056} 4057 4058static vector unsigned char __ATTRS_o_ai 4059vec_pack(vector unsigned short __a, vector unsigned short __b) 4060{ 4061 return (vector unsigned char)vec_perm(__a, __b, (vector unsigned char) 4062 (0x01, 0x03, 0x05, 0x07, 0x09, 0x0B, 0x0D, 0x0F, 4063 0x11, 0x13, 0x15, 0x17, 0x19, 0x1B, 0x1D, 0x1F)); 4064} 4065 4066static vector bool char __ATTRS_o_ai 4067vec_pack(vector bool short __a, vector bool short __b) 4068{ 4069 return (vector bool char)vec_perm(__a, __b, (vector unsigned char) 4070 (0x01, 0x03, 0x05, 0x07, 0x09, 0x0B, 0x0D, 0x0F, 4071 0x11, 0x13, 0x15, 0x17, 0x19, 0x1B, 0x1D, 0x1F)); 4072} 4073 4074static vector short __ATTRS_o_ai 4075vec_pack(vector int __a, vector int __b) 4076{ 4077 return (vector short)vec_perm(__a, __b, (vector unsigned char) 4078 (0x02, 0x03, 0x06, 0x07, 0x0A, 0x0B, 0x0E, 0x0F, 4079 0x12, 0x13, 0x16, 0x17, 0x1A, 0x1B, 0x1E, 0x1F)); 4080} 4081 4082static vector unsigned short __ATTRS_o_ai 4083vec_pack(vector unsigned int __a, vector unsigned int __b) 4084{ 4085 return (vector unsigned short)vec_perm(__a, __b, (vector unsigned char) 4086 (0x02, 0x03, 0x06, 0x07, 0x0A, 0x0B, 0x0E, 0x0F, 4087 0x12, 0x13, 0x16, 0x17, 0x1A, 0x1B, 0x1E, 0x1F)); 4088} 4089 4090static vector bool short __ATTRS_o_ai 4091vec_pack(vector bool int __a, vector bool int __b) 4092{ 4093 return (vector bool short)vec_perm(__a, __b, (vector unsigned char) 4094 (0x02, 0x03, 0x06, 0x07, 0x0A, 0x0B, 0x0E, 0x0F, 4095 0x12, 0x13, 0x16, 0x17, 0x1A, 0x1B, 0x1E, 0x1F)); 4096} 4097 4098/* vec_vpkuhum */ 4099 4100#define __builtin_altivec_vpkuhum vec_vpkuhum 4101 4102static vector signed char __ATTRS_o_ai 4103vec_vpkuhum(vector signed short __a, vector signed short __b) 4104{ 4105 return (vector signed char)vec_perm(__a, __b, (vector unsigned char) 4106 (0x01, 0x03, 0x05, 0x07, 0x09, 0x0B, 0x0D, 0x0F, 4107 0x11, 0x13, 0x15, 0x17, 0x19, 0x1B, 0x1D, 0x1F)); 4108} 4109 4110static vector unsigned char __ATTRS_o_ai 4111vec_vpkuhum(vector unsigned short __a, vector unsigned short __b) 4112{ 4113 return (vector unsigned char)vec_perm(__a, __b, (vector unsigned char) 4114 (0x01, 0x03, 0x05, 0x07, 0x09, 0x0B, 0x0D, 0x0F, 4115 0x11, 0x13, 0x15, 0x17, 0x19, 0x1B, 0x1D, 0x1F)); 4116} 4117 4118static vector bool char __ATTRS_o_ai 4119vec_vpkuhum(vector bool short __a, vector bool short __b) 4120{ 4121 return (vector bool char)vec_perm(__a, __b, (vector unsigned char) 4122 (0x01, 0x03, 0x05, 0x07, 0x09, 0x0B, 0x0D, 0x0F, 4123 0x11, 0x13, 0x15, 0x17, 0x19, 0x1B, 0x1D, 0x1F)); 4124} 4125 4126/* vec_vpkuwum */ 4127 4128#define __builtin_altivec_vpkuwum vec_vpkuwum 4129 4130static vector short __ATTRS_o_ai 4131vec_vpkuwum(vector int __a, vector int __b) 4132{ 4133 return (vector short)vec_perm(__a, __b, (vector unsigned char) 4134 (0x02, 0x03, 0x06, 0x07, 0x0A, 0x0B, 0x0E, 0x0F, 4135 0x12, 0x13, 0x16, 0x17, 0x1A, 0x1B, 0x1E, 0x1F)); 4136} 4137 4138static vector unsigned short __ATTRS_o_ai 4139vec_vpkuwum(vector unsigned int __a, vector unsigned int __b) 4140{ 4141 return (vector unsigned short)vec_perm(__a, __b, (vector unsigned char) 4142 (0x02, 0x03, 0x06, 0x07, 0x0A, 0x0B, 0x0E, 0x0F, 4143 0x12, 0x13, 0x16, 0x17, 0x1A, 0x1B, 0x1E, 0x1F)); 4144} 4145 4146static vector bool short __ATTRS_o_ai 4147vec_vpkuwum(vector bool int __a, vector bool int __b) 4148{ 4149 return (vector bool short)vec_perm(__a, __b, (vector unsigned char) 4150 (0x02, 0x03, 0x06, 0x07, 0x0A, 0x0B, 0x0E, 0x0F, 4151 0x12, 0x13, 0x16, 0x17, 0x1A, 0x1B, 0x1E, 0x1F)); 4152} 4153 4154/* vec_packpx */ 4155 4156static vector pixel __attribute__((__always_inline__)) 4157vec_packpx(vector unsigned int __a, vector unsigned int __b) 4158{ 4159 return (vector pixel)__builtin_altivec_vpkpx(__a, __b); 4160} 4161 4162/* vec_vpkpx */ 4163 4164static vector pixel __attribute__((__always_inline__)) 4165vec_vpkpx(vector unsigned int __a, vector unsigned int __b) 4166{ 4167 return (vector pixel)__builtin_altivec_vpkpx(__a, __b); 4168} 4169 4170/* vec_packs */ 4171 4172static vector signed char __ATTRS_o_ai 4173vec_packs(vector short __a, vector short __b) 4174{ 4175 return __builtin_altivec_vpkshss(__a, __b); 4176} 4177 4178static vector unsigned char __ATTRS_o_ai 4179vec_packs(vector unsigned short __a, vector unsigned short __b) 4180{ 4181 return __builtin_altivec_vpkuhus(__a, __b); 4182} 4183 4184static vector signed short __ATTRS_o_ai 4185vec_packs(vector int __a, vector int __b) 4186{ 4187 return __builtin_altivec_vpkswss(__a, __b); 4188} 4189 4190static vector unsigned short __ATTRS_o_ai 4191vec_packs(vector unsigned int __a, vector unsigned int __b) 4192{ 4193 return __builtin_altivec_vpkuwus(__a, __b); 4194} 4195 4196/* vec_vpkshss */ 4197 4198static vector signed char __attribute__((__always_inline__)) 4199vec_vpkshss(vector short __a, vector short __b) 4200{ 4201 return __builtin_altivec_vpkshss(__a, __b); 4202} 4203 4204/* vec_vpkuhus */ 4205 4206static vector unsigned char __attribute__((__always_inline__)) 4207vec_vpkuhus(vector unsigned short __a, vector unsigned short __b) 4208{ 4209 return __builtin_altivec_vpkuhus(__a, __b); 4210} 4211 4212/* vec_vpkswss */ 4213 4214static vector signed short __attribute__((__always_inline__)) 4215vec_vpkswss(vector int __a, vector int __b) 4216{ 4217 return __builtin_altivec_vpkswss(__a, __b); 4218} 4219 4220/* vec_vpkuwus */ 4221 4222static vector unsigned short __attribute__((__always_inline__)) 4223vec_vpkuwus(vector unsigned int __a, vector unsigned int __b) 4224{ 4225 return __builtin_altivec_vpkuwus(__a, __b); 4226} 4227 4228/* vec_packsu */ 4229 4230static vector unsigned char __ATTRS_o_ai 4231vec_packsu(vector short __a, vector short __b) 4232{ 4233 return __builtin_altivec_vpkshus(__a, __b); 4234} 4235 4236static vector unsigned char __ATTRS_o_ai 4237vec_packsu(vector unsigned short __a, vector unsigned short __b) 4238{ 4239 return __builtin_altivec_vpkuhus(__a, __b); 4240} 4241 4242static vector unsigned short __ATTRS_o_ai 4243vec_packsu(vector int __a, vector int __b) 4244{ 4245 return __builtin_altivec_vpkswus(__a, __b); 4246} 4247 4248static vector unsigned short __ATTRS_o_ai 4249vec_packsu(vector unsigned int __a, vector unsigned int __b) 4250{ 4251 return __builtin_altivec_vpkuwus(__a, __b); 4252} 4253 4254/* vec_vpkshus */ 4255 4256static vector unsigned char __ATTRS_o_ai 4257vec_vpkshus(vector short __a, vector short __b) 4258{ 4259 return __builtin_altivec_vpkshus(__a, __b); 4260} 4261 4262static vector unsigned char __ATTRS_o_ai 4263vec_vpkshus(vector unsigned short __a, vector unsigned short __b) 4264{ 4265 return __builtin_altivec_vpkuhus(__a, __b); 4266} 4267 4268/* vec_vpkswus */ 4269 4270static vector unsigned short __ATTRS_o_ai 4271vec_vpkswus(vector int __a, vector int __b) 4272{ 4273 return __builtin_altivec_vpkswus(__a, __b); 4274} 4275 4276static vector unsigned short __ATTRS_o_ai 4277vec_vpkswus(vector unsigned int __a, vector unsigned int __b) 4278{ 4279 return __builtin_altivec_vpkuwus(__a, __b); 4280} 4281 4282/* vec_perm */ 4283 4284vector signed char __ATTRS_o_ai 4285vec_perm(vector signed char __a, vector signed char __b, vector unsigned char __c) 4286{ 4287 return (vector signed char) 4288 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4289} 4290 4291vector unsigned char __ATTRS_o_ai 4292vec_perm(vector unsigned char __a, 4293 vector unsigned char __b, 4294 vector unsigned char __c) 4295{ 4296 return (vector unsigned char) 4297 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4298} 4299 4300vector bool char __ATTRS_o_ai 4301vec_perm(vector bool char __a, vector bool char __b, vector unsigned char __c) 4302{ 4303 return (vector bool char) 4304 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4305} 4306 4307vector short __ATTRS_o_ai 4308vec_perm(vector short __a, vector short __b, vector unsigned char __c) 4309{ 4310 return (vector short) 4311 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4312} 4313 4314vector unsigned short __ATTRS_o_ai 4315vec_perm(vector unsigned short __a, 4316 vector unsigned short __b, 4317 vector unsigned char __c) 4318{ 4319 return (vector unsigned short) 4320 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4321} 4322 4323vector bool short __ATTRS_o_ai 4324vec_perm(vector bool short __a, vector bool short __b, vector unsigned char __c) 4325{ 4326 return (vector bool short) 4327 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4328} 4329 4330vector pixel __ATTRS_o_ai 4331vec_perm(vector pixel __a, vector pixel __b, vector unsigned char __c) 4332{ 4333 return (vector pixel) 4334 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4335} 4336 4337vector int __ATTRS_o_ai 4338vec_perm(vector int __a, vector int __b, vector unsigned char __c) 4339{ 4340 return (vector int)__builtin_altivec_vperm_4si(__a, __b, __c); 4341} 4342 4343vector unsigned int __ATTRS_o_ai 4344vec_perm(vector unsigned int __a, vector unsigned int __b, vector unsigned char __c) 4345{ 4346 return (vector unsigned int) 4347 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4348} 4349 4350vector bool int __ATTRS_o_ai 4351vec_perm(vector bool int __a, vector bool int __b, vector unsigned char __c) 4352{ 4353 return (vector bool int) 4354 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4355} 4356 4357vector float __ATTRS_o_ai 4358vec_perm(vector float __a, vector float __b, vector unsigned char __c) 4359{ 4360 return (vector float) 4361 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4362} 4363 4364/* vec_vperm */ 4365 4366static vector signed char __ATTRS_o_ai 4367vec_vperm(vector signed char __a, vector signed char __b, vector unsigned char __c) 4368{ 4369 return (vector signed char) 4370 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4371} 4372 4373static vector unsigned char __ATTRS_o_ai 4374vec_vperm(vector unsigned char __a, 4375 vector unsigned char __b, 4376 vector unsigned char __c) 4377{ 4378 return (vector unsigned char) 4379 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4380} 4381 4382static vector bool char __ATTRS_o_ai 4383vec_vperm(vector bool char __a, vector bool char __b, vector unsigned char __c) 4384{ 4385 return (vector bool char) 4386 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4387} 4388 4389static vector short __ATTRS_o_ai 4390vec_vperm(vector short __a, vector short __b, vector unsigned char __c) 4391{ 4392 return (vector short) 4393 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4394} 4395 4396static vector unsigned short __ATTRS_o_ai 4397vec_vperm(vector unsigned short __a, 4398 vector unsigned short __b, 4399 vector unsigned char __c) 4400{ 4401 return (vector unsigned short) 4402 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4403} 4404 4405static vector bool short __ATTRS_o_ai 4406vec_vperm(vector bool short __a, vector bool short __b, vector unsigned char __c) 4407{ 4408 return (vector bool short) 4409 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4410} 4411 4412static vector pixel __ATTRS_o_ai 4413vec_vperm(vector pixel __a, vector pixel __b, vector unsigned char __c) 4414{ 4415 return (vector pixel) 4416 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4417} 4418 4419static vector int __ATTRS_o_ai 4420vec_vperm(vector int __a, vector int __b, vector unsigned char __c) 4421{ 4422 return (vector int)__builtin_altivec_vperm_4si(__a, __b, __c); 4423} 4424 4425static vector unsigned int __ATTRS_o_ai 4426vec_vperm(vector unsigned int __a, vector unsigned int __b, vector unsigned char __c) 4427{ 4428 return (vector unsigned int) 4429 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4430} 4431 4432static vector bool int __ATTRS_o_ai 4433vec_vperm(vector bool int __a, vector bool int __b, vector unsigned char __c) 4434{ 4435 return (vector bool int) 4436 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4437} 4438 4439static vector float __ATTRS_o_ai 4440vec_vperm(vector float __a, vector float __b, vector unsigned char __c) 4441{ 4442 return (vector float) 4443 __builtin_altivec_vperm_4si((vector int)__a, (vector int)__b, __c); 4444} 4445 4446/* vec_re */ 4447 4448static vector float __attribute__((__always_inline__)) 4449vec_re(vector float __a) 4450{ 4451 return __builtin_altivec_vrefp(__a); 4452} 4453 4454/* vec_vrefp */ 4455 4456static vector float __attribute__((__always_inline__)) 4457vec_vrefp(vector float __a) 4458{ 4459 return __builtin_altivec_vrefp(__a); 4460} 4461 4462/* vec_rl */ 4463 4464static vector signed char __ATTRS_o_ai 4465vec_rl(vector signed char __a, vector unsigned char __b) 4466{ 4467 return (vector signed char)__builtin_altivec_vrlb((vector char)__a, __b); 4468} 4469 4470static vector unsigned char __ATTRS_o_ai 4471vec_rl(vector unsigned char __a, vector unsigned char __b) 4472{ 4473 return (vector unsigned char)__builtin_altivec_vrlb((vector char)__a, __b); 4474} 4475 4476static vector short __ATTRS_o_ai 4477vec_rl(vector short __a, vector unsigned short __b) 4478{ 4479 return __builtin_altivec_vrlh(__a, __b); 4480} 4481 4482static vector unsigned short __ATTRS_o_ai 4483vec_rl(vector unsigned short __a, vector unsigned short __b) 4484{ 4485 return (vector unsigned short)__builtin_altivec_vrlh((vector short)__a, __b); 4486} 4487 4488static vector int __ATTRS_o_ai 4489vec_rl(vector int __a, vector unsigned int __b) 4490{ 4491 return __builtin_altivec_vrlw(__a, __b); 4492} 4493 4494static vector unsigned int __ATTRS_o_ai 4495vec_rl(vector unsigned int __a, vector unsigned int __b) 4496{ 4497 return (vector unsigned int)__builtin_altivec_vrlw((vector int)__a, __b); 4498} 4499 4500/* vec_vrlb */ 4501 4502static vector signed char __ATTRS_o_ai 4503vec_vrlb(vector signed char __a, vector unsigned char __b) 4504{ 4505 return (vector signed char)__builtin_altivec_vrlb((vector char)__a, __b); 4506} 4507 4508static vector unsigned char __ATTRS_o_ai 4509vec_vrlb(vector unsigned char __a, vector unsigned char __b) 4510{ 4511 return (vector unsigned char)__builtin_altivec_vrlb((vector char)__a, __b); 4512} 4513 4514/* vec_vrlh */ 4515 4516static vector short __ATTRS_o_ai 4517vec_vrlh(vector short __a, vector unsigned short __b) 4518{ 4519 return __builtin_altivec_vrlh(__a, __b); 4520} 4521 4522static vector unsigned short __ATTRS_o_ai 4523vec_vrlh(vector unsigned short __a, vector unsigned short __b) 4524{ 4525 return (vector unsigned short)__builtin_altivec_vrlh((vector short)__a, __b); 4526} 4527 4528/* vec_vrlw */ 4529 4530static vector int __ATTRS_o_ai 4531vec_vrlw(vector int __a, vector unsigned int __b) 4532{ 4533 return __builtin_altivec_vrlw(__a, __b); 4534} 4535 4536static vector unsigned int __ATTRS_o_ai 4537vec_vrlw(vector unsigned int __a, vector unsigned int __b) 4538{ 4539 return (vector unsigned int)__builtin_altivec_vrlw((vector int)__a, __b); 4540} 4541 4542/* vec_round */ 4543 4544static vector float __attribute__((__always_inline__)) 4545vec_round(vector float __a) 4546{ 4547 return __builtin_altivec_vrfin(__a); 4548} 4549 4550/* vec_vrfin */ 4551 4552static vector float __attribute__((__always_inline__)) 4553vec_vrfin(vector float __a) 4554{ 4555 return __builtin_altivec_vrfin(__a); 4556} 4557 4558/* vec_rsqrte */ 4559 4560static __vector float __attribute__((__always_inline__)) 4561vec_rsqrte(vector float __a) 4562{ 4563 return __builtin_altivec_vrsqrtefp(__a); 4564} 4565 4566/* vec_vrsqrtefp */ 4567 4568static __vector float __attribute__((__always_inline__)) 4569vec_vrsqrtefp(vector float __a) 4570{ 4571 return __builtin_altivec_vrsqrtefp(__a); 4572} 4573 4574/* vec_sel */ 4575 4576#define __builtin_altivec_vsel_4si vec_sel 4577 4578static vector signed char __ATTRS_o_ai 4579vec_sel(vector signed char __a, vector signed char __b, vector unsigned char __c) 4580{ 4581 return (__a & ~(vector signed char)__c) | (__b & (vector signed char)__c); 4582} 4583 4584static vector signed char __ATTRS_o_ai 4585vec_sel(vector signed char __a, vector signed char __b, vector bool char __c) 4586{ 4587 return (__a & ~(vector signed char)__c) | (__b & (vector signed char)__c); 4588} 4589 4590static vector unsigned char __ATTRS_o_ai 4591vec_sel(vector unsigned char __a, vector unsigned char __b, vector unsigned char __c) 4592{ 4593 return (__a & ~__c) | (__b & __c); 4594} 4595 4596static vector unsigned char __ATTRS_o_ai 4597vec_sel(vector unsigned char __a, vector unsigned char __b, vector bool char __c) 4598{ 4599 return (__a & ~(vector unsigned char)__c) | (__b & (vector unsigned char)__c); 4600} 4601 4602static vector bool char __ATTRS_o_ai 4603vec_sel(vector bool char __a, vector bool char __b, vector unsigned char __c) 4604{ 4605 return (__a & ~(vector bool char)__c) | (__b & (vector bool char)__c); 4606} 4607 4608static vector bool char __ATTRS_o_ai 4609vec_sel(vector bool char __a, vector bool char __b, vector bool char __c) 4610{ 4611 return (__a & ~__c) | (__b & __c); 4612} 4613 4614static vector short __ATTRS_o_ai 4615vec_sel(vector short __a, vector short __b, vector unsigned short __c) 4616{ 4617 return (__a & ~(vector short)__c) | (__b & (vector short)__c); 4618} 4619 4620static vector short __ATTRS_o_ai 4621vec_sel(vector short __a, vector short __b, vector bool short __c) 4622{ 4623 return (__a & ~(vector short)__c) | (__b & (vector short)__c); 4624} 4625 4626static vector unsigned short __ATTRS_o_ai 4627vec_sel(vector unsigned short __a, 4628 vector unsigned short __b, 4629 vector unsigned short __c) 4630{ 4631 return (__a & ~__c) | (__b & __c); 4632} 4633 4634static vector unsigned short __ATTRS_o_ai 4635vec_sel(vector unsigned short __a, vector unsigned short __b, vector bool short __c) 4636{ 4637 return (__a & ~(vector unsigned short)__c) | (__b & (vector unsigned short)__c); 4638} 4639 4640static vector bool short __ATTRS_o_ai 4641vec_sel(vector bool short __a, vector bool short __b, vector unsigned short __c) 4642{ 4643 return (__a & ~(vector bool short)__c) | (__b & (vector bool short)__c); 4644} 4645 4646static vector bool short __ATTRS_o_ai 4647vec_sel(vector bool short __a, vector bool short __b, vector bool short __c) 4648{ 4649 return (__a & ~__c) | (__b & __c); 4650} 4651 4652static vector int __ATTRS_o_ai 4653vec_sel(vector int __a, vector int __b, vector unsigned int __c) 4654{ 4655 return (__a & ~(vector int)__c) | (__b & (vector int)__c); 4656} 4657 4658static vector int __ATTRS_o_ai 4659vec_sel(vector int __a, vector int __b, vector bool int __c) 4660{ 4661 return (__a & ~(vector int)__c) | (__b & (vector int)__c); 4662} 4663 4664static vector unsigned int __ATTRS_o_ai 4665vec_sel(vector unsigned int __a, vector unsigned int __b, vector unsigned int __c) 4666{ 4667 return (__a & ~__c) | (__b & __c); 4668} 4669 4670static vector unsigned int __ATTRS_o_ai 4671vec_sel(vector unsigned int __a, vector unsigned int __b, vector bool int __c) 4672{ 4673 return (__a & ~(vector unsigned int)__c) | (__b & (vector unsigned int)__c); 4674} 4675 4676static vector bool int __ATTRS_o_ai 4677vec_sel(vector bool int __a, vector bool int __b, vector unsigned int __c) 4678{ 4679 return (__a & ~(vector bool int)__c) | (__b & (vector bool int)__c); 4680} 4681 4682static vector bool int __ATTRS_o_ai 4683vec_sel(vector bool int __a, vector bool int __b, vector bool int __c) 4684{ 4685 return (__a & ~__c) | (__b & __c); 4686} 4687 4688static vector float __ATTRS_o_ai 4689vec_sel(vector float __a, vector float __b, vector unsigned int __c) 4690{ 4691 vector int __res = ((vector int)__a & ~(vector int)__c) 4692 | ((vector int)__b & (vector int)__c); 4693 return (vector float)__res; 4694} 4695 4696static vector float __ATTRS_o_ai 4697vec_sel(vector float __a, vector float __b, vector bool int __c) 4698{ 4699 vector int __res = ((vector int)__a & ~(vector int)__c) 4700 | ((vector int)__b & (vector int)__c); 4701 return (vector float)__res; 4702} 4703 4704/* vec_vsel */ 4705 4706static vector signed char __ATTRS_o_ai 4707vec_vsel(vector signed char __a, vector signed char __b, vector unsigned char __c) 4708{ 4709 return (__a & ~(vector signed char)__c) | (__b & (vector signed char)__c); 4710} 4711 4712static vector signed char __ATTRS_o_ai 4713vec_vsel(vector signed char __a, vector signed char __b, vector bool char __c) 4714{ 4715 return (__a & ~(vector signed char)__c) | (__b & (vector signed char)__c); 4716} 4717 4718static vector unsigned char __ATTRS_o_ai 4719vec_vsel(vector unsigned char __a, vector unsigned char __b, vector unsigned char __c) 4720{ 4721 return (__a & ~__c) | (__b & __c); 4722} 4723 4724static vector unsigned char __ATTRS_o_ai 4725vec_vsel(vector unsigned char __a, vector unsigned char __b, vector bool char __c) 4726{ 4727 return (__a & ~(vector unsigned char)__c) | (__b & (vector unsigned char)__c); 4728} 4729 4730static vector bool char __ATTRS_o_ai 4731vec_vsel(vector bool char __a, vector bool char __b, vector unsigned char __c) 4732{ 4733 return (__a & ~(vector bool char)__c) | (__b & (vector bool char)__c); 4734} 4735 4736static vector bool char __ATTRS_o_ai 4737vec_vsel(vector bool char __a, vector bool char __b, vector bool char __c) 4738{ 4739 return (__a & ~__c) | (__b & __c); 4740} 4741 4742static vector short __ATTRS_o_ai 4743vec_vsel(vector short __a, vector short __b, vector unsigned short __c) 4744{ 4745 return (__a & ~(vector short)__c) | (__b & (vector short)__c); 4746} 4747 4748static vector short __ATTRS_o_ai 4749vec_vsel(vector short __a, vector short __b, vector bool short __c) 4750{ 4751 return (__a & ~(vector short)__c) | (__b & (vector short)__c); 4752} 4753 4754static vector unsigned short __ATTRS_o_ai 4755vec_vsel(vector unsigned short __a, 4756 vector unsigned short __b, 4757 vector unsigned short __c) 4758{ 4759 return (__a & ~__c) | (__b & __c); 4760} 4761 4762static vector unsigned short __ATTRS_o_ai 4763vec_vsel(vector unsigned short __a, vector unsigned short __b, vector bool short __c) 4764{ 4765 return (__a & ~(vector unsigned short)__c) | (__b & (vector unsigned short)__c); 4766} 4767 4768static vector bool short __ATTRS_o_ai 4769vec_vsel(vector bool short __a, vector bool short __b, vector unsigned short __c) 4770{ 4771 return (__a & ~(vector bool short)__c) | (__b & (vector bool short)__c); 4772} 4773 4774static vector bool short __ATTRS_o_ai 4775vec_vsel(vector bool short __a, vector bool short __b, vector bool short __c) 4776{ 4777 return (__a & ~__c) | (__b & __c); 4778} 4779 4780static vector int __ATTRS_o_ai 4781vec_vsel(vector int __a, vector int __b, vector unsigned int __c) 4782{ 4783 return (__a & ~(vector int)__c) | (__b & (vector int)__c); 4784} 4785 4786static vector int __ATTRS_o_ai 4787vec_vsel(vector int __a, vector int __b, vector bool int __c) 4788{ 4789 return (__a & ~(vector int)__c) | (__b & (vector int)__c); 4790} 4791 4792static vector unsigned int __ATTRS_o_ai 4793vec_vsel(vector unsigned int __a, vector unsigned int __b, vector unsigned int __c) 4794{ 4795 return (__a & ~__c) | (__b & __c); 4796} 4797 4798static vector unsigned int __ATTRS_o_ai 4799vec_vsel(vector unsigned int __a, vector unsigned int __b, vector bool int __c) 4800{ 4801 return (__a & ~(vector unsigned int)__c) | (__b & (vector unsigned int)__c); 4802} 4803 4804static vector bool int __ATTRS_o_ai 4805vec_vsel(vector bool int __a, vector bool int __b, vector unsigned int __c) 4806{ 4807 return (__a & ~(vector bool int)__c) | (__b & (vector bool int)__c); 4808} 4809 4810static vector bool int __ATTRS_o_ai 4811vec_vsel(vector bool int __a, vector bool int __b, vector bool int __c) 4812{ 4813 return (__a & ~__c) | (__b & __c); 4814} 4815 4816static vector float __ATTRS_o_ai 4817vec_vsel(vector float __a, vector float __b, vector unsigned int __c) 4818{ 4819 vector int __res = ((vector int)__a & ~(vector int)__c) 4820 | ((vector int)__b & (vector int)__c); 4821 return (vector float)__res; 4822} 4823 4824static vector float __ATTRS_o_ai 4825vec_vsel(vector float __a, vector float __b, vector bool int __c) 4826{ 4827 vector int __res = ((vector int)__a & ~(vector int)__c) 4828 | ((vector int)__b & (vector int)__c); 4829 return (vector float)__res; 4830} 4831 4832/* vec_sl */ 4833 4834static vector signed char __ATTRS_o_ai 4835vec_sl(vector signed char __a, vector unsigned char __b) 4836{ 4837 return __a << (vector signed char)__b; 4838} 4839 4840static vector unsigned char __ATTRS_o_ai 4841vec_sl(vector unsigned char __a, vector unsigned char __b) 4842{ 4843 return __a << __b; 4844} 4845 4846static vector short __ATTRS_o_ai 4847vec_sl(vector short __a, vector unsigned short __b) 4848{ 4849 return __a << (vector short)__b; 4850} 4851 4852static vector unsigned short __ATTRS_o_ai 4853vec_sl(vector unsigned short __a, vector unsigned short __b) 4854{ 4855 return __a << __b; 4856} 4857 4858static vector int __ATTRS_o_ai 4859vec_sl(vector int __a, vector unsigned int __b) 4860{ 4861 return __a << (vector int)__b; 4862} 4863 4864static vector unsigned int __ATTRS_o_ai 4865vec_sl(vector unsigned int __a, vector unsigned int __b) 4866{ 4867 return __a << __b; 4868} 4869 4870/* vec_vslb */ 4871 4872#define __builtin_altivec_vslb vec_vslb 4873 4874static vector signed char __ATTRS_o_ai 4875vec_vslb(vector signed char __a, vector unsigned char __b) 4876{ 4877 return vec_sl(__a, __b); 4878} 4879 4880static vector unsigned char __ATTRS_o_ai 4881vec_vslb(vector unsigned char __a, vector unsigned char __b) 4882{ 4883 return vec_sl(__a, __b); 4884} 4885 4886/* vec_vslh */ 4887 4888#define __builtin_altivec_vslh vec_vslh 4889 4890static vector short __ATTRS_o_ai 4891vec_vslh(vector short __a, vector unsigned short __b) 4892{ 4893 return vec_sl(__a, __b); 4894} 4895 4896static vector unsigned short __ATTRS_o_ai 4897vec_vslh(vector unsigned short __a, vector unsigned short __b) 4898{ 4899 return vec_sl(__a, __b); 4900} 4901 4902/* vec_vslw */ 4903 4904#define __builtin_altivec_vslw vec_vslw 4905 4906static vector int __ATTRS_o_ai 4907vec_vslw(vector int __a, vector unsigned int __b) 4908{ 4909 return vec_sl(__a, __b); 4910} 4911 4912static vector unsigned int __ATTRS_o_ai 4913vec_vslw(vector unsigned int __a, vector unsigned int __b) 4914{ 4915 return vec_sl(__a, __b); 4916} 4917 4918/* vec_sld */ 4919 4920#define __builtin_altivec_vsldoi_4si vec_sld 4921 4922static vector signed char __ATTRS_o_ai 4923vec_sld(vector signed char __a, vector signed char __b, unsigned char __c) 4924{ 4925 return vec_perm(__a, __b, (vector unsigned char) 4926 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 4927 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 4928} 4929 4930static vector unsigned char __ATTRS_o_ai 4931vec_sld(vector unsigned char __a, vector unsigned char __b, unsigned char __c) 4932{ 4933 return vec_perm(__a, __b, (vector unsigned char) 4934 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 4935 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 4936} 4937 4938static vector short __ATTRS_o_ai 4939vec_sld(vector short __a, vector short __b, unsigned char __c) 4940{ 4941 return vec_perm(__a, __b, (vector unsigned char) 4942 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 4943 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 4944} 4945 4946static vector unsigned short __ATTRS_o_ai 4947vec_sld(vector unsigned short __a, vector unsigned short __b, unsigned char __c) 4948{ 4949 return vec_perm(__a, __b, (vector unsigned char) 4950 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 4951 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 4952} 4953 4954static vector pixel __ATTRS_o_ai 4955vec_sld(vector pixel __a, vector pixel __b, unsigned char __c) 4956{ 4957 return vec_perm(__a, __b, (vector unsigned char) 4958 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 4959 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 4960} 4961 4962static vector int __ATTRS_o_ai 4963vec_sld(vector int __a, vector int __b, unsigned char __c) 4964{ 4965 return vec_perm(__a, __b, (vector unsigned char) 4966 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 4967 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 4968} 4969 4970static vector unsigned int __ATTRS_o_ai 4971vec_sld(vector unsigned int __a, vector unsigned int __b, unsigned char __c) 4972{ 4973 return vec_perm(__a, __b, (vector unsigned char) 4974 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 4975 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 4976} 4977 4978static vector float __ATTRS_o_ai 4979vec_sld(vector float __a, vector float __b, unsigned char __c) 4980{ 4981 return vec_perm(__a, __b, (vector unsigned char) 4982 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 4983 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 4984} 4985 4986/* vec_vsldoi */ 4987 4988static vector signed char __ATTRS_o_ai 4989vec_vsldoi(vector signed char __a, vector signed char __b, unsigned char __c) 4990{ 4991 return vec_perm(__a, __b, (vector unsigned char) 4992 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 4993 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 4994} 4995 4996static vector unsigned char __ATTRS_o_ai 4997vec_vsldoi(vector unsigned char __a, vector unsigned char __b, unsigned char __c) 4998{ 4999 return vec_perm(__a, __b, (vector unsigned char) 5000 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 5001 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 5002} 5003 5004static vector short __ATTRS_o_ai 5005vec_vsldoi(vector short __a, vector short __b, unsigned char __c) 5006{ 5007 return vec_perm(__a, __b, (vector unsigned char) 5008 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 5009 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 5010} 5011 5012static vector unsigned short __ATTRS_o_ai 5013vec_vsldoi(vector unsigned short __a, vector unsigned short __b, unsigned char __c) 5014{ 5015 return vec_perm(__a, __b, (vector unsigned char) 5016 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 5017 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 5018} 5019 5020static vector pixel __ATTRS_o_ai 5021vec_vsldoi(vector pixel __a, vector pixel __b, unsigned char __c) 5022{ 5023 return vec_perm(__a, __b, (vector unsigned char) 5024 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 5025 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 5026} 5027 5028static vector int __ATTRS_o_ai 5029vec_vsldoi(vector int __a, vector int __b, unsigned char __c) 5030{ 5031 return vec_perm(__a, __b, (vector unsigned char) 5032 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 5033 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 5034} 5035 5036static vector unsigned int __ATTRS_o_ai 5037vec_vsldoi(vector unsigned int __a, vector unsigned int __b, unsigned char __c) 5038{ 5039 return vec_perm(__a, __b, (vector unsigned char) 5040 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 5041 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 5042} 5043 5044static vector float __ATTRS_o_ai 5045vec_vsldoi(vector float __a, vector float __b, unsigned char __c) 5046{ 5047 return vec_perm(__a, __b, (vector unsigned char) 5048 (__c, __c+1, __c+2, __c+3, __c+4, __c+5, __c+6, __c+7, 5049 __c+8, __c+9, __c+10, __c+11, __c+12, __c+13, __c+14, __c+15)); 5050} 5051 5052/* vec_sll */ 5053 5054static vector signed char __ATTRS_o_ai 5055vec_sll(vector signed char __a, vector unsigned char __b) 5056{ 5057 return (vector signed char) 5058 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5059} 5060 5061static vector signed char __ATTRS_o_ai 5062vec_sll(vector signed char __a, vector unsigned short __b) 5063{ 5064 return (vector signed char) 5065 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5066} 5067 5068static vector signed char __ATTRS_o_ai 5069vec_sll(vector signed char __a, vector unsigned int __b) 5070{ 5071 return (vector signed char) 5072 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5073} 5074 5075static vector unsigned char __ATTRS_o_ai 5076vec_sll(vector unsigned char __a, vector unsigned char __b) 5077{ 5078 return (vector unsigned char) 5079 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5080} 5081 5082static vector unsigned char __ATTRS_o_ai 5083vec_sll(vector unsigned char __a, vector unsigned short __b) 5084{ 5085 return (vector unsigned char) 5086 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5087} 5088 5089static vector unsigned char __ATTRS_o_ai 5090vec_sll(vector unsigned char __a, vector unsigned int __b) 5091{ 5092 return (vector unsigned char) 5093 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5094} 5095 5096static vector bool char __ATTRS_o_ai 5097vec_sll(vector bool char __a, vector unsigned char __b) 5098{ 5099 return (vector bool char)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5100} 5101 5102static vector bool char __ATTRS_o_ai 5103vec_sll(vector bool char __a, vector unsigned short __b) 5104{ 5105 return (vector bool char)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5106} 5107 5108static vector bool char __ATTRS_o_ai 5109vec_sll(vector bool char __a, vector unsigned int __b) 5110{ 5111 return (vector bool char)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5112} 5113 5114static vector short __ATTRS_o_ai 5115vec_sll(vector short __a, vector unsigned char __b) 5116{ 5117 return (vector short)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5118} 5119 5120static vector short __ATTRS_o_ai 5121vec_sll(vector short __a, vector unsigned short __b) 5122{ 5123 return (vector short)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5124} 5125 5126static vector short __ATTRS_o_ai 5127vec_sll(vector short __a, vector unsigned int __b) 5128{ 5129 return (vector short)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5130} 5131 5132static vector unsigned short __ATTRS_o_ai 5133vec_sll(vector unsigned short __a, vector unsigned char __b) 5134{ 5135 return (vector unsigned short) 5136 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5137} 5138 5139static vector unsigned short __ATTRS_o_ai 5140vec_sll(vector unsigned short __a, vector unsigned short __b) 5141{ 5142 return (vector unsigned short) 5143 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5144} 5145 5146static vector unsigned short __ATTRS_o_ai 5147vec_sll(vector unsigned short __a, vector unsigned int __b) 5148{ 5149 return (vector unsigned short) 5150 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5151} 5152 5153static vector bool short __ATTRS_o_ai 5154vec_sll(vector bool short __a, vector unsigned char __b) 5155{ 5156 return (vector bool short)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5157} 5158 5159static vector bool short __ATTRS_o_ai 5160vec_sll(vector bool short __a, vector unsigned short __b) 5161{ 5162 return (vector bool short)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5163} 5164 5165static vector bool short __ATTRS_o_ai 5166vec_sll(vector bool short __a, vector unsigned int __b) 5167{ 5168 return (vector bool short)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5169} 5170 5171static vector pixel __ATTRS_o_ai 5172vec_sll(vector pixel __a, vector unsigned char __b) 5173{ 5174 return (vector pixel)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5175} 5176 5177static vector pixel __ATTRS_o_ai 5178vec_sll(vector pixel __a, vector unsigned short __b) 5179{ 5180 return (vector pixel)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5181} 5182 5183static vector pixel __ATTRS_o_ai 5184vec_sll(vector pixel __a, vector unsigned int __b) 5185{ 5186 return (vector pixel)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5187} 5188 5189static vector int __ATTRS_o_ai 5190vec_sll(vector int __a, vector unsigned char __b) 5191{ 5192 return (vector int)__builtin_altivec_vsl(__a, (vector int)__b); 5193} 5194 5195static vector int __ATTRS_o_ai 5196vec_sll(vector int __a, vector unsigned short __b) 5197{ 5198 return (vector int)__builtin_altivec_vsl(__a, (vector int)__b); 5199} 5200 5201static vector int __ATTRS_o_ai 5202vec_sll(vector int __a, vector unsigned int __b) 5203{ 5204 return (vector int)__builtin_altivec_vsl(__a, (vector int)__b); 5205} 5206 5207static vector unsigned int __ATTRS_o_ai 5208vec_sll(vector unsigned int __a, vector unsigned char __b) 5209{ 5210 return (vector unsigned int) 5211 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5212} 5213 5214static vector unsigned int __ATTRS_o_ai 5215vec_sll(vector unsigned int __a, vector unsigned short __b) 5216{ 5217 return (vector unsigned int) 5218 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5219} 5220 5221static vector unsigned int __ATTRS_o_ai 5222vec_sll(vector unsigned int __a, vector unsigned int __b) 5223{ 5224 return (vector unsigned int) 5225 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5226} 5227 5228static vector bool int __ATTRS_o_ai 5229vec_sll(vector bool int __a, vector unsigned char __b) 5230{ 5231 return (vector bool int)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5232} 5233 5234static vector bool int __ATTRS_o_ai 5235vec_sll(vector bool int __a, vector unsigned short __b) 5236{ 5237 return (vector bool int)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5238} 5239 5240static vector bool int __ATTRS_o_ai 5241vec_sll(vector bool int __a, vector unsigned int __b) 5242{ 5243 return (vector bool int)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5244} 5245 5246/* vec_vsl */ 5247 5248static vector signed char __ATTRS_o_ai 5249vec_vsl(vector signed char __a, vector unsigned char __b) 5250{ 5251 return (vector signed char) 5252 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5253} 5254 5255static vector signed char __ATTRS_o_ai 5256vec_vsl(vector signed char __a, vector unsigned short __b) 5257{ 5258 return (vector signed char) 5259 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5260} 5261 5262static vector signed char __ATTRS_o_ai 5263vec_vsl(vector signed char __a, vector unsigned int __b) 5264{ 5265 return (vector signed char) 5266 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5267} 5268 5269static vector unsigned char __ATTRS_o_ai 5270vec_vsl(vector unsigned char __a, vector unsigned char __b) 5271{ 5272 return (vector unsigned char) 5273 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5274} 5275 5276static vector unsigned char __ATTRS_o_ai 5277vec_vsl(vector unsigned char __a, vector unsigned short __b) 5278{ 5279 return (vector unsigned char) 5280 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5281} 5282 5283static vector unsigned char __ATTRS_o_ai 5284vec_vsl(vector unsigned char __a, vector unsigned int __b) 5285{ 5286 return (vector unsigned char) 5287 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5288} 5289 5290static vector bool char __ATTRS_o_ai 5291vec_vsl(vector bool char __a, vector unsigned char __b) 5292{ 5293 return (vector bool char)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5294} 5295 5296static vector bool char __ATTRS_o_ai 5297vec_vsl(vector bool char __a, vector unsigned short __b) 5298{ 5299 return (vector bool char)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5300} 5301 5302static vector bool char __ATTRS_o_ai 5303vec_vsl(vector bool char __a, vector unsigned int __b) 5304{ 5305 return (vector bool char)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5306} 5307 5308static vector short __ATTRS_o_ai 5309vec_vsl(vector short __a, vector unsigned char __b) 5310{ 5311 return (vector short)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5312} 5313 5314static vector short __ATTRS_o_ai 5315vec_vsl(vector short __a, vector unsigned short __b) 5316{ 5317 return (vector short)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5318} 5319 5320static vector short __ATTRS_o_ai 5321vec_vsl(vector short __a, vector unsigned int __b) 5322{ 5323 return (vector short)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5324} 5325 5326static vector unsigned short __ATTRS_o_ai 5327vec_vsl(vector unsigned short __a, vector unsigned char __b) 5328{ 5329 return (vector unsigned short) 5330 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5331} 5332 5333static vector unsigned short __ATTRS_o_ai 5334vec_vsl(vector unsigned short __a, vector unsigned short __b) 5335{ 5336 return (vector unsigned short) 5337 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5338} 5339 5340static vector unsigned short __ATTRS_o_ai 5341vec_vsl(vector unsigned short __a, vector unsigned int __b) 5342{ 5343 return (vector unsigned short) 5344 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5345} 5346 5347static vector bool short __ATTRS_o_ai 5348vec_vsl(vector bool short __a, vector unsigned char __b) 5349{ 5350 return (vector bool short)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5351} 5352 5353static vector bool short __ATTRS_o_ai 5354vec_vsl(vector bool short __a, vector unsigned short __b) 5355{ 5356 return (vector bool short)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5357} 5358 5359static vector bool short __ATTRS_o_ai 5360vec_vsl(vector bool short __a, vector unsigned int __b) 5361{ 5362 return (vector bool short)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5363} 5364 5365static vector pixel __ATTRS_o_ai 5366vec_vsl(vector pixel __a, vector unsigned char __b) 5367{ 5368 return (vector pixel)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5369} 5370 5371static vector pixel __ATTRS_o_ai 5372vec_vsl(vector pixel __a, vector unsigned short __b) 5373{ 5374 return (vector pixel)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5375} 5376 5377static vector pixel __ATTRS_o_ai 5378vec_vsl(vector pixel __a, vector unsigned int __b) 5379{ 5380 return (vector pixel)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5381} 5382 5383static vector int __ATTRS_o_ai 5384vec_vsl(vector int __a, vector unsigned char __b) 5385{ 5386 return (vector int)__builtin_altivec_vsl(__a, (vector int)__b); 5387} 5388 5389static vector int __ATTRS_o_ai 5390vec_vsl(vector int __a, vector unsigned short __b) 5391{ 5392 return (vector int)__builtin_altivec_vsl(__a, (vector int)__b); 5393} 5394 5395static vector int __ATTRS_o_ai 5396vec_vsl(vector int __a, vector unsigned int __b) 5397{ 5398 return (vector int)__builtin_altivec_vsl(__a, (vector int)__b); 5399} 5400 5401static vector unsigned int __ATTRS_o_ai 5402vec_vsl(vector unsigned int __a, vector unsigned char __b) 5403{ 5404 return (vector unsigned int) 5405 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5406} 5407 5408static vector unsigned int __ATTRS_o_ai 5409vec_vsl(vector unsigned int __a, vector unsigned short __b) 5410{ 5411 return (vector unsigned int) 5412 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5413} 5414 5415static vector unsigned int __ATTRS_o_ai 5416vec_vsl(vector unsigned int __a, vector unsigned int __b) 5417{ 5418 return (vector unsigned int) 5419 __builtin_altivec_vsl((vector int)__a, (vector int)__b); 5420} 5421 5422static vector bool int __ATTRS_o_ai 5423vec_vsl(vector bool int __a, vector unsigned char __b) 5424{ 5425 return (vector bool int)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5426} 5427 5428static vector bool int __ATTRS_o_ai 5429vec_vsl(vector bool int __a, vector unsigned short __b) 5430{ 5431 return (vector bool int)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5432} 5433 5434static vector bool int __ATTRS_o_ai 5435vec_vsl(vector bool int __a, vector unsigned int __b) 5436{ 5437 return (vector bool int)__builtin_altivec_vsl((vector int)__a, (vector int)__b); 5438} 5439 5440/* vec_slo */ 5441 5442static vector signed char __ATTRS_o_ai 5443vec_slo(vector signed char __a, vector signed char __b) 5444{ 5445 return (vector signed char) 5446 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5447} 5448 5449static vector signed char __ATTRS_o_ai 5450vec_slo(vector signed char __a, vector unsigned char __b) 5451{ 5452 return (vector signed char) 5453 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5454} 5455 5456static vector unsigned char __ATTRS_o_ai 5457vec_slo(vector unsigned char __a, vector signed char __b) 5458{ 5459 return (vector unsigned char) 5460 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5461} 5462 5463static vector unsigned char __ATTRS_o_ai 5464vec_slo(vector unsigned char __a, vector unsigned char __b) 5465{ 5466 return (vector unsigned char) 5467 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5468} 5469 5470static vector short __ATTRS_o_ai 5471vec_slo(vector short __a, vector signed char __b) 5472{ 5473 return (vector short)__builtin_altivec_vslo((vector int)__a, (vector int)__b); 5474} 5475 5476static vector short __ATTRS_o_ai 5477vec_slo(vector short __a, vector unsigned char __b) 5478{ 5479 return (vector short)__builtin_altivec_vslo((vector int)__a, (vector int)__b); 5480} 5481 5482static vector unsigned short __ATTRS_o_ai 5483vec_slo(vector unsigned short __a, vector signed char __b) 5484{ 5485 return (vector unsigned short) 5486 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5487} 5488 5489static vector unsigned short __ATTRS_o_ai 5490vec_slo(vector unsigned short __a, vector unsigned char __b) 5491{ 5492 return (vector unsigned short) 5493 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5494} 5495 5496static vector pixel __ATTRS_o_ai 5497vec_slo(vector pixel __a, vector signed char __b) 5498{ 5499 return (vector pixel)__builtin_altivec_vslo((vector int)__a, (vector int)__b); 5500} 5501 5502static vector pixel __ATTRS_o_ai 5503vec_slo(vector pixel __a, vector unsigned char __b) 5504{ 5505 return (vector pixel)__builtin_altivec_vslo((vector int)__a, (vector int)__b); 5506} 5507 5508static vector int __ATTRS_o_ai 5509vec_slo(vector int __a, vector signed char __b) 5510{ 5511 return (vector int)__builtin_altivec_vslo(__a, (vector int)__b); 5512} 5513 5514static vector int __ATTRS_o_ai 5515vec_slo(vector int __a, vector unsigned char __b) 5516{ 5517 return (vector int)__builtin_altivec_vslo(__a, (vector int)__b); 5518} 5519 5520static vector unsigned int __ATTRS_o_ai 5521vec_slo(vector unsigned int __a, vector signed char __b) 5522{ 5523 return (vector unsigned int) 5524 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5525} 5526 5527static vector unsigned int __ATTRS_o_ai 5528vec_slo(vector unsigned int __a, vector unsigned char __b) 5529{ 5530 return (vector unsigned int) 5531 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5532} 5533 5534static vector float __ATTRS_o_ai 5535vec_slo(vector float __a, vector signed char __b) 5536{ 5537 return (vector float)__builtin_altivec_vslo((vector int)__a, (vector int)__b); 5538} 5539 5540static vector float __ATTRS_o_ai 5541vec_slo(vector float __a, vector unsigned char __b) 5542{ 5543 return (vector float)__builtin_altivec_vslo((vector int)__a, (vector int)__b); 5544} 5545 5546/* vec_vslo */ 5547 5548static vector signed char __ATTRS_o_ai 5549vec_vslo(vector signed char __a, vector signed char __b) 5550{ 5551 return (vector signed char) 5552 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5553} 5554 5555static vector signed char __ATTRS_o_ai 5556vec_vslo(vector signed char __a, vector unsigned char __b) 5557{ 5558 return (vector signed char) 5559 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5560} 5561 5562static vector unsigned char __ATTRS_o_ai 5563vec_vslo(vector unsigned char __a, vector signed char __b) 5564{ 5565 return (vector unsigned char) 5566 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5567} 5568 5569static vector unsigned char __ATTRS_o_ai 5570vec_vslo(vector unsigned char __a, vector unsigned char __b) 5571{ 5572 return (vector unsigned char) 5573 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5574} 5575 5576static vector short __ATTRS_o_ai 5577vec_vslo(vector short __a, vector signed char __b) 5578{ 5579 return (vector short)__builtin_altivec_vslo((vector int)__a, (vector int)__b); 5580} 5581 5582static vector short __ATTRS_o_ai 5583vec_vslo(vector short __a, vector unsigned char __b) 5584{ 5585 return (vector short)__builtin_altivec_vslo((vector int)__a, (vector int)__b); 5586} 5587 5588static vector unsigned short __ATTRS_o_ai 5589vec_vslo(vector unsigned short __a, vector signed char __b) 5590{ 5591 return (vector unsigned short) 5592 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5593} 5594 5595static vector unsigned short __ATTRS_o_ai 5596vec_vslo(vector unsigned short __a, vector unsigned char __b) 5597{ 5598 return (vector unsigned short) 5599 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5600} 5601 5602static vector pixel __ATTRS_o_ai 5603vec_vslo(vector pixel __a, vector signed char __b) 5604{ 5605 return (vector pixel)__builtin_altivec_vslo((vector int)__a, (vector int)__b); 5606} 5607 5608static vector pixel __ATTRS_o_ai 5609vec_vslo(vector pixel __a, vector unsigned char __b) 5610{ 5611 return (vector pixel)__builtin_altivec_vslo((vector int)__a, (vector int)__b); 5612} 5613 5614static vector int __ATTRS_o_ai 5615vec_vslo(vector int __a, vector signed char __b) 5616{ 5617 return (vector int)__builtin_altivec_vslo(__a, (vector int)__b); 5618} 5619 5620static vector int __ATTRS_o_ai 5621vec_vslo(vector int __a, vector unsigned char __b) 5622{ 5623 return (vector int)__builtin_altivec_vslo(__a, (vector int)__b); 5624} 5625 5626static vector unsigned int __ATTRS_o_ai 5627vec_vslo(vector unsigned int __a, vector signed char __b) 5628{ 5629 return (vector unsigned int) 5630 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5631} 5632 5633static vector unsigned int __ATTRS_o_ai 5634vec_vslo(vector unsigned int __a, vector unsigned char __b) 5635{ 5636 return (vector unsigned int) 5637 __builtin_altivec_vslo((vector int)__a, (vector int)__b); 5638} 5639 5640static vector float __ATTRS_o_ai 5641vec_vslo(vector float __a, vector signed char __b) 5642{ 5643 return (vector float)__builtin_altivec_vslo((vector int)__a, (vector int)__b); 5644} 5645 5646static vector float __ATTRS_o_ai 5647vec_vslo(vector float __a, vector unsigned char __b) 5648{ 5649 return (vector float)__builtin_altivec_vslo((vector int)__a, (vector int)__b); 5650} 5651 5652/* vec_splat */ 5653 5654static vector signed char __ATTRS_o_ai 5655vec_splat(vector signed char __a, unsigned char __b) 5656{ 5657 return vec_perm(__a, __a, (vector unsigned char)(__b)); 5658} 5659 5660static vector unsigned char __ATTRS_o_ai 5661vec_splat(vector unsigned char __a, unsigned char __b) 5662{ 5663 return vec_perm(__a, __a, (vector unsigned char)(__b)); 5664} 5665 5666static vector bool char __ATTRS_o_ai 5667vec_splat(vector bool char __a, unsigned char __b) 5668{ 5669 return vec_perm(__a, __a, (vector unsigned char)(__b)); 5670} 5671 5672static vector short __ATTRS_o_ai 5673vec_splat(vector short __a, unsigned char __b) 5674{ 5675 __b *= 2; 5676 unsigned char b1=__b+1; 5677 return vec_perm(__a, __a, (vector unsigned char) 5678 (__b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1)); 5679} 5680 5681static vector unsigned short __ATTRS_o_ai 5682vec_splat(vector unsigned short __a, unsigned char __b) 5683{ 5684 __b *= 2; 5685 unsigned char b1=__b+1; 5686 return vec_perm(__a, __a, (vector unsigned char) 5687 (__b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1)); 5688} 5689 5690static vector bool short __ATTRS_o_ai 5691vec_splat(vector bool short __a, unsigned char __b) 5692{ 5693 __b *= 2; 5694 unsigned char b1=__b+1; 5695 return vec_perm(__a, __a, (vector unsigned char) 5696 (__b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1)); 5697} 5698 5699static vector pixel __ATTRS_o_ai 5700vec_splat(vector pixel __a, unsigned char __b) 5701{ 5702 __b *= 2; 5703 unsigned char b1=__b+1; 5704 return vec_perm(__a, __a, (vector unsigned char) 5705 (__b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1)); 5706} 5707 5708static vector int __ATTRS_o_ai 5709vec_splat(vector int __a, unsigned char __b) 5710{ 5711 __b *= 4; 5712 unsigned char b1=__b+1, b2=__b+2, b3=__b+3; 5713 return vec_perm(__a, __a, (vector unsigned char) 5714 (__b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3)); 5715} 5716 5717static vector unsigned int __ATTRS_o_ai 5718vec_splat(vector unsigned int __a, unsigned char __b) 5719{ 5720 __b *= 4; 5721 unsigned char b1=__b+1, b2=__b+2, b3=__b+3; 5722 return vec_perm(__a, __a, (vector unsigned char) 5723 (__b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3)); 5724} 5725 5726static vector bool int __ATTRS_o_ai 5727vec_splat(vector bool int __a, unsigned char __b) 5728{ 5729 __b *= 4; 5730 unsigned char b1=__b+1, b2=__b+2, b3=__b+3; 5731 return vec_perm(__a, __a, (vector unsigned char) 5732 (__b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3)); 5733} 5734 5735static vector float __ATTRS_o_ai 5736vec_splat(vector float __a, unsigned char __b) 5737{ 5738 __b *= 4; 5739 unsigned char b1=__b+1, b2=__b+2, b3=__b+3; 5740 return vec_perm(__a, __a, (vector unsigned char) 5741 (__b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3)); 5742} 5743 5744/* vec_vspltb */ 5745 5746#define __builtin_altivec_vspltb vec_vspltb 5747 5748static vector signed char __ATTRS_o_ai 5749vec_vspltb(vector signed char __a, unsigned char __b) 5750{ 5751 return vec_perm(__a, __a, (vector unsigned char)(__b)); 5752} 5753 5754static vector unsigned char __ATTRS_o_ai 5755vec_vspltb(vector unsigned char __a, unsigned char __b) 5756{ 5757 return vec_perm(__a, __a, (vector unsigned char)(__b)); 5758} 5759 5760static vector bool char __ATTRS_o_ai 5761vec_vspltb(vector bool char __a, unsigned char __b) 5762{ 5763 return vec_perm(__a, __a, (vector unsigned char)(__b)); 5764} 5765 5766/* vec_vsplth */ 5767 5768#define __builtin_altivec_vsplth vec_vsplth 5769 5770static vector short __ATTRS_o_ai 5771vec_vsplth(vector short __a, unsigned char __b) 5772{ 5773 __b *= 2; 5774 unsigned char b1=__b+1; 5775 return vec_perm(__a, __a, (vector unsigned char) 5776 (__b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1)); 5777} 5778 5779static vector unsigned short __ATTRS_o_ai 5780vec_vsplth(vector unsigned short __a, unsigned char __b) 5781{ 5782 __b *= 2; 5783 unsigned char b1=__b+1; 5784 return vec_perm(__a, __a, (vector unsigned char) 5785 (__b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1)); 5786} 5787 5788static vector bool short __ATTRS_o_ai 5789vec_vsplth(vector bool short __a, unsigned char __b) 5790{ 5791 __b *= 2; 5792 unsigned char b1=__b+1; 5793 return vec_perm(__a, __a, (vector unsigned char) 5794 (__b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1)); 5795} 5796 5797static vector pixel __ATTRS_o_ai 5798vec_vsplth(vector pixel __a, unsigned char __b) 5799{ 5800 __b *= 2; 5801 unsigned char b1=__b+1; 5802 return vec_perm(__a, __a, (vector unsigned char) 5803 (__b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1, __b, b1)); 5804} 5805 5806/* vec_vspltw */ 5807 5808#define __builtin_altivec_vspltw vec_vspltw 5809 5810static vector int __ATTRS_o_ai 5811vec_vspltw(vector int __a, unsigned char __b) 5812{ 5813 __b *= 4; 5814 unsigned char b1=__b+1, b2=__b+2, b3=__b+3; 5815 return vec_perm(__a, __a, (vector unsigned char) 5816 (__b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3)); 5817} 5818 5819static vector unsigned int __ATTRS_o_ai 5820vec_vspltw(vector unsigned int __a, unsigned char __b) 5821{ 5822 __b *= 4; 5823 unsigned char b1=__b+1, b2=__b+2, b3=__b+3; 5824 return vec_perm(__a, __a, (vector unsigned char) 5825 (__b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3)); 5826} 5827 5828static vector bool int __ATTRS_o_ai 5829vec_vspltw(vector bool int __a, unsigned char __b) 5830{ 5831 __b *= 4; 5832 unsigned char b1=__b+1, b2=__b+2, b3=__b+3; 5833 return vec_perm(__a, __a, (vector unsigned char) 5834 (__b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3)); 5835} 5836 5837static vector float __ATTRS_o_ai 5838vec_vspltw(vector float __a, unsigned char __b) 5839{ 5840 __b *= 4; 5841 unsigned char b1=__b+1, b2=__b+2, b3=__b+3; 5842 return vec_perm(__a, __a, (vector unsigned char) 5843 (__b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3, __b, b1, b2, b3)); 5844} 5845 5846/* vec_splat_s8 */ 5847 5848#define __builtin_altivec_vspltisb vec_splat_s8 5849 5850// FIXME: parameter should be treated as 5-bit signed literal 5851static vector signed char __ATTRS_o_ai 5852vec_splat_s8(signed char __a) 5853{ 5854 return (vector signed char)(__a); 5855} 5856 5857/* vec_vspltisb */ 5858 5859// FIXME: parameter should be treated as 5-bit signed literal 5860static vector signed char __ATTRS_o_ai 5861vec_vspltisb(signed char __a) 5862{ 5863 return (vector signed char)(__a); 5864} 5865 5866/* vec_splat_s16 */ 5867 5868#define __builtin_altivec_vspltish vec_splat_s16 5869 5870// FIXME: parameter should be treated as 5-bit signed literal 5871static vector short __ATTRS_o_ai 5872vec_splat_s16(signed char __a) 5873{ 5874 return (vector short)(__a); 5875} 5876 5877/* vec_vspltish */ 5878 5879// FIXME: parameter should be treated as 5-bit signed literal 5880static vector short __ATTRS_o_ai 5881vec_vspltish(signed char __a) 5882{ 5883 return (vector short)(__a); 5884} 5885 5886/* vec_splat_s32 */ 5887 5888#define __builtin_altivec_vspltisw vec_splat_s32 5889 5890// FIXME: parameter should be treated as 5-bit signed literal 5891static vector int __ATTRS_o_ai 5892vec_splat_s32(signed char __a) 5893{ 5894 return (vector int)(__a); 5895} 5896 5897/* vec_vspltisw */ 5898 5899// FIXME: parameter should be treated as 5-bit signed literal 5900static vector int __ATTRS_o_ai 5901vec_vspltisw(signed char __a) 5902{ 5903 return (vector int)(__a); 5904} 5905 5906/* vec_splat_u8 */ 5907 5908// FIXME: parameter should be treated as 5-bit signed literal 5909static vector unsigned char __ATTRS_o_ai 5910vec_splat_u8(unsigned char __a) 5911{ 5912 return (vector unsigned char)(__a); 5913} 5914 5915/* vec_splat_u16 */ 5916 5917// FIXME: parameter should be treated as 5-bit signed literal 5918static vector unsigned short __ATTRS_o_ai 5919vec_splat_u16(signed char __a) 5920{ 5921 return (vector unsigned short)(__a); 5922} 5923 5924/* vec_splat_u32 */ 5925 5926// FIXME: parameter should be treated as 5-bit signed literal 5927static vector unsigned int __ATTRS_o_ai 5928vec_splat_u32(signed char __a) 5929{ 5930 return (vector unsigned int)(__a); 5931} 5932 5933/* vec_sr */ 5934 5935static vector signed char __ATTRS_o_ai 5936vec_sr(vector signed char __a, vector unsigned char __b) 5937{ 5938 return __a >> (vector signed char)__b; 5939} 5940 5941static vector unsigned char __ATTRS_o_ai 5942vec_sr(vector unsigned char __a, vector unsigned char __b) 5943{ 5944 return __a >> __b; 5945} 5946 5947static vector short __ATTRS_o_ai 5948vec_sr(vector short __a, vector unsigned short __b) 5949{ 5950 return __a >> (vector short)__b; 5951} 5952 5953static vector unsigned short __ATTRS_o_ai 5954vec_sr(vector unsigned short __a, vector unsigned short __b) 5955{ 5956 return __a >> __b; 5957} 5958 5959static vector int __ATTRS_o_ai 5960vec_sr(vector int __a, vector unsigned int __b) 5961{ 5962 return __a >> (vector int)__b; 5963} 5964 5965static vector unsigned int __ATTRS_o_ai 5966vec_sr(vector unsigned int __a, vector unsigned int __b) 5967{ 5968 return __a >> __b; 5969} 5970 5971/* vec_vsrb */ 5972 5973#define __builtin_altivec_vsrb vec_vsrb 5974 5975static vector signed char __ATTRS_o_ai 5976vec_vsrb(vector signed char __a, vector unsigned char __b) 5977{ 5978 return __a >> (vector signed char)__b; 5979} 5980 5981static vector unsigned char __ATTRS_o_ai 5982vec_vsrb(vector unsigned char __a, vector unsigned char __b) 5983{ 5984 return __a >> __b; 5985} 5986 5987/* vec_vsrh */ 5988 5989#define __builtin_altivec_vsrh vec_vsrh 5990 5991static vector short __ATTRS_o_ai 5992vec_vsrh(vector short __a, vector unsigned short __b) 5993{ 5994 return __a >> (vector short)__b; 5995} 5996 5997static vector unsigned short __ATTRS_o_ai 5998vec_vsrh(vector unsigned short __a, vector unsigned short __b) 5999{ 6000 return __a >> __b; 6001} 6002 6003/* vec_vsrw */ 6004 6005#define __builtin_altivec_vsrw vec_vsrw 6006 6007static vector int __ATTRS_o_ai 6008vec_vsrw(vector int __a, vector unsigned int __b) 6009{ 6010 return __a >> (vector int)__b; 6011} 6012 6013static vector unsigned int __ATTRS_o_ai 6014vec_vsrw(vector unsigned int __a, vector unsigned int __b) 6015{ 6016 return __a >> __b; 6017} 6018 6019/* vec_sra */ 6020 6021static vector signed char __ATTRS_o_ai 6022vec_sra(vector signed char __a, vector unsigned char __b) 6023{ 6024 return (vector signed char)__builtin_altivec_vsrab((vector char)__a, __b); 6025} 6026 6027static vector unsigned char __ATTRS_o_ai 6028vec_sra(vector unsigned char __a, vector unsigned char __b) 6029{ 6030 return (vector unsigned char)__builtin_altivec_vsrab((vector char)__a, __b); 6031} 6032 6033static vector short __ATTRS_o_ai 6034vec_sra(vector short __a, vector unsigned short __b) 6035{ 6036 return __builtin_altivec_vsrah(__a, (vector unsigned short)__b); 6037} 6038 6039static vector unsigned short __ATTRS_o_ai 6040vec_sra(vector unsigned short __a, vector unsigned short __b) 6041{ 6042 return (vector unsigned short)__builtin_altivec_vsrah((vector short)__a, __b); 6043} 6044 6045static vector int __ATTRS_o_ai 6046vec_sra(vector int __a, vector unsigned int __b) 6047{ 6048 return __builtin_altivec_vsraw(__a, __b); 6049} 6050 6051static vector unsigned int __ATTRS_o_ai 6052vec_sra(vector unsigned int __a, vector unsigned int __b) 6053{ 6054 return (vector unsigned int)__builtin_altivec_vsraw((vector int)__a, __b); 6055} 6056 6057/* vec_vsrab */ 6058 6059static vector signed char __ATTRS_o_ai 6060vec_vsrab(vector signed char __a, vector unsigned char __b) 6061{ 6062 return (vector signed char)__builtin_altivec_vsrab((vector char)__a, __b); 6063} 6064 6065static vector unsigned char __ATTRS_o_ai 6066vec_vsrab(vector unsigned char __a, vector unsigned char __b) 6067{ 6068 return (vector unsigned char)__builtin_altivec_vsrab((vector char)__a, __b); 6069} 6070 6071/* vec_vsrah */ 6072 6073static vector short __ATTRS_o_ai 6074vec_vsrah(vector short __a, vector unsigned short __b) 6075{ 6076 return __builtin_altivec_vsrah(__a, (vector unsigned short)__b); 6077} 6078 6079static vector unsigned short __ATTRS_o_ai 6080vec_vsrah(vector unsigned short __a, vector unsigned short __b) 6081{ 6082 return (vector unsigned short)__builtin_altivec_vsrah((vector short)__a, __b); 6083} 6084 6085/* vec_vsraw */ 6086 6087static vector int __ATTRS_o_ai 6088vec_vsraw(vector int __a, vector unsigned int __b) 6089{ 6090 return __builtin_altivec_vsraw(__a, __b); 6091} 6092 6093static vector unsigned int __ATTRS_o_ai 6094vec_vsraw(vector unsigned int __a, vector unsigned int __b) 6095{ 6096 return (vector unsigned int)__builtin_altivec_vsraw((vector int)__a, __b); 6097} 6098 6099/* vec_srl */ 6100 6101static vector signed char __ATTRS_o_ai 6102vec_srl(vector signed char __a, vector unsigned char __b) 6103{ 6104 return (vector signed char) 6105 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6106} 6107 6108static vector signed char __ATTRS_o_ai 6109vec_srl(vector signed char __a, vector unsigned short __b) 6110{ 6111 return (vector signed char) 6112 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6113} 6114 6115static vector signed char __ATTRS_o_ai 6116vec_srl(vector signed char __a, vector unsigned int __b) 6117{ 6118 return (vector signed char) 6119 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6120} 6121 6122static vector unsigned char __ATTRS_o_ai 6123vec_srl(vector unsigned char __a, vector unsigned char __b) 6124{ 6125 return (vector unsigned char) 6126 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6127} 6128 6129static vector unsigned char __ATTRS_o_ai 6130vec_srl(vector unsigned char __a, vector unsigned short __b) 6131{ 6132 return (vector unsigned char) 6133 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6134} 6135 6136static vector unsigned char __ATTRS_o_ai 6137vec_srl(vector unsigned char __a, vector unsigned int __b) 6138{ 6139 return (vector unsigned char) 6140 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6141} 6142 6143static vector bool char __ATTRS_o_ai 6144vec_srl(vector bool char __a, vector unsigned char __b) 6145{ 6146 return (vector bool char)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6147} 6148 6149static vector bool char __ATTRS_o_ai 6150vec_srl(vector bool char __a, vector unsigned short __b) 6151{ 6152 return (vector bool char)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6153} 6154 6155static vector bool char __ATTRS_o_ai 6156vec_srl(vector bool char __a, vector unsigned int __b) 6157{ 6158 return (vector bool char)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6159} 6160 6161static vector short __ATTRS_o_ai 6162vec_srl(vector short __a, vector unsigned char __b) 6163{ 6164 return (vector short)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6165} 6166 6167static vector short __ATTRS_o_ai 6168vec_srl(vector short __a, vector unsigned short __b) 6169{ 6170 return (vector short)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6171} 6172 6173static vector short __ATTRS_o_ai 6174vec_srl(vector short __a, vector unsigned int __b) 6175{ 6176 return (vector short)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6177} 6178 6179static vector unsigned short __ATTRS_o_ai 6180vec_srl(vector unsigned short __a, vector unsigned char __b) 6181{ 6182 return (vector unsigned short) 6183 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6184} 6185 6186static vector unsigned short __ATTRS_o_ai 6187vec_srl(vector unsigned short __a, vector unsigned short __b) 6188{ 6189 return (vector unsigned short) 6190 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6191} 6192 6193static vector unsigned short __ATTRS_o_ai 6194vec_srl(vector unsigned short __a, vector unsigned int __b) 6195{ 6196 return (vector unsigned short) 6197 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6198} 6199 6200static vector bool short __ATTRS_o_ai 6201vec_srl(vector bool short __a, vector unsigned char __b) 6202{ 6203 return (vector bool short)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6204} 6205 6206static vector bool short __ATTRS_o_ai 6207vec_srl(vector bool short __a, vector unsigned short __b) 6208{ 6209 return (vector bool short)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6210} 6211 6212static vector bool short __ATTRS_o_ai 6213vec_srl(vector bool short __a, vector unsigned int __b) 6214{ 6215 return (vector bool short)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6216} 6217 6218static vector pixel __ATTRS_o_ai 6219vec_srl(vector pixel __a, vector unsigned char __b) 6220{ 6221 return (vector pixel)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6222} 6223 6224static vector pixel __ATTRS_o_ai 6225vec_srl(vector pixel __a, vector unsigned short __b) 6226{ 6227 return (vector pixel)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6228} 6229 6230static vector pixel __ATTRS_o_ai 6231vec_srl(vector pixel __a, vector unsigned int __b) 6232{ 6233 return (vector pixel)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6234} 6235 6236static vector int __ATTRS_o_ai 6237vec_srl(vector int __a, vector unsigned char __b) 6238{ 6239 return (vector int)__builtin_altivec_vsr(__a, (vector int)__b); 6240} 6241 6242static vector int __ATTRS_o_ai 6243vec_srl(vector int __a, vector unsigned short __b) 6244{ 6245 return (vector int)__builtin_altivec_vsr(__a, (vector int)__b); 6246} 6247 6248static vector int __ATTRS_o_ai 6249vec_srl(vector int __a, vector unsigned int __b) 6250{ 6251 return (vector int)__builtin_altivec_vsr(__a, (vector int)__b); 6252} 6253 6254static vector unsigned int __ATTRS_o_ai 6255vec_srl(vector unsigned int __a, vector unsigned char __b) 6256{ 6257 return (vector unsigned int) 6258 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6259} 6260 6261static vector unsigned int __ATTRS_o_ai 6262vec_srl(vector unsigned int __a, vector unsigned short __b) 6263{ 6264 return (vector unsigned int) 6265 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6266} 6267 6268static vector unsigned int __ATTRS_o_ai 6269vec_srl(vector unsigned int __a, vector unsigned int __b) 6270{ 6271 return (vector unsigned int) 6272 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6273} 6274 6275static vector bool int __ATTRS_o_ai 6276vec_srl(vector bool int __a, vector unsigned char __b) 6277{ 6278 return (vector bool int)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6279} 6280 6281static vector bool int __ATTRS_o_ai 6282vec_srl(vector bool int __a, vector unsigned short __b) 6283{ 6284 return (vector bool int)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6285} 6286 6287static vector bool int __ATTRS_o_ai 6288vec_srl(vector bool int __a, vector unsigned int __b) 6289{ 6290 return (vector bool int)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6291} 6292 6293/* vec_vsr */ 6294 6295static vector signed char __ATTRS_o_ai 6296vec_vsr(vector signed char __a, vector unsigned char __b) 6297{ 6298 return (vector signed char) 6299 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6300} 6301 6302static vector signed char __ATTRS_o_ai 6303vec_vsr(vector signed char __a, vector unsigned short __b) 6304{ 6305 return (vector signed char) 6306 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6307} 6308 6309static vector signed char __ATTRS_o_ai 6310vec_vsr(vector signed char __a, vector unsigned int __b) 6311{ 6312 return (vector signed char) 6313 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6314} 6315 6316static vector unsigned char __ATTRS_o_ai 6317vec_vsr(vector unsigned char __a, vector unsigned char __b) 6318{ 6319 return (vector unsigned char) 6320 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6321} 6322 6323static vector unsigned char __ATTRS_o_ai 6324vec_vsr(vector unsigned char __a, vector unsigned short __b) 6325{ 6326 return (vector unsigned char) 6327 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6328} 6329 6330static vector unsigned char __ATTRS_o_ai 6331vec_vsr(vector unsigned char __a, vector unsigned int __b) 6332{ 6333 return (vector unsigned char) 6334 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6335} 6336 6337static vector bool char __ATTRS_o_ai 6338vec_vsr(vector bool char __a, vector unsigned char __b) 6339{ 6340 return (vector bool char)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6341} 6342 6343static vector bool char __ATTRS_o_ai 6344vec_vsr(vector bool char __a, vector unsigned short __b) 6345{ 6346 return (vector bool char)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6347} 6348 6349static vector bool char __ATTRS_o_ai 6350vec_vsr(vector bool char __a, vector unsigned int __b) 6351{ 6352 return (vector bool char)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6353} 6354 6355static vector short __ATTRS_o_ai 6356vec_vsr(vector short __a, vector unsigned char __b) 6357{ 6358 return (vector short)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6359} 6360 6361static vector short __ATTRS_o_ai 6362vec_vsr(vector short __a, vector unsigned short __b) 6363{ 6364 return (vector short)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6365} 6366 6367static vector short __ATTRS_o_ai 6368vec_vsr(vector short __a, vector unsigned int __b) 6369{ 6370 return (vector short)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6371} 6372 6373static vector unsigned short __ATTRS_o_ai 6374vec_vsr(vector unsigned short __a, vector unsigned char __b) 6375{ 6376 return (vector unsigned short) 6377 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6378} 6379 6380static vector unsigned short __ATTRS_o_ai 6381vec_vsr(vector unsigned short __a, vector unsigned short __b) 6382{ 6383 return (vector unsigned short) 6384 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6385} 6386 6387static vector unsigned short __ATTRS_o_ai 6388vec_vsr(vector unsigned short __a, vector unsigned int __b) 6389{ 6390 return (vector unsigned short) 6391 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6392} 6393 6394static vector bool short __ATTRS_o_ai 6395vec_vsr(vector bool short __a, vector unsigned char __b) 6396{ 6397 return (vector bool short)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6398} 6399 6400static vector bool short __ATTRS_o_ai 6401vec_vsr(vector bool short __a, vector unsigned short __b) 6402{ 6403 return (vector bool short)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6404} 6405 6406static vector bool short __ATTRS_o_ai 6407vec_vsr(vector bool short __a, vector unsigned int __b) 6408{ 6409 return (vector bool short)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6410} 6411 6412static vector pixel __ATTRS_o_ai 6413vec_vsr(vector pixel __a, vector unsigned char __b) 6414{ 6415 return (vector pixel)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6416} 6417 6418static vector pixel __ATTRS_o_ai 6419vec_vsr(vector pixel __a, vector unsigned short __b) 6420{ 6421 return (vector pixel)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6422} 6423 6424static vector pixel __ATTRS_o_ai 6425vec_vsr(vector pixel __a, vector unsigned int __b) 6426{ 6427 return (vector pixel)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6428} 6429 6430static vector int __ATTRS_o_ai 6431vec_vsr(vector int __a, vector unsigned char __b) 6432{ 6433 return (vector int)__builtin_altivec_vsr(__a, (vector int)__b); 6434} 6435 6436static vector int __ATTRS_o_ai 6437vec_vsr(vector int __a, vector unsigned short __b) 6438{ 6439 return (vector int)__builtin_altivec_vsr(__a, (vector int)__b); 6440} 6441 6442static vector int __ATTRS_o_ai 6443vec_vsr(vector int __a, vector unsigned int __b) 6444{ 6445 return (vector int)__builtin_altivec_vsr(__a, (vector int)__b); 6446} 6447 6448static vector unsigned int __ATTRS_o_ai 6449vec_vsr(vector unsigned int __a, vector unsigned char __b) 6450{ 6451 return (vector unsigned int) 6452 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6453} 6454 6455static vector unsigned int __ATTRS_o_ai 6456vec_vsr(vector unsigned int __a, vector unsigned short __b) 6457{ 6458 return (vector unsigned int) 6459 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6460} 6461 6462static vector unsigned int __ATTRS_o_ai 6463vec_vsr(vector unsigned int __a, vector unsigned int __b) 6464{ 6465 return (vector unsigned int) 6466 __builtin_altivec_vsr((vector int)__a, (vector int)__b); 6467} 6468 6469static vector bool int __ATTRS_o_ai 6470vec_vsr(vector bool int __a, vector unsigned char __b) 6471{ 6472 return (vector bool int)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6473} 6474 6475static vector bool int __ATTRS_o_ai 6476vec_vsr(vector bool int __a, vector unsigned short __b) 6477{ 6478 return (vector bool int)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6479} 6480 6481static vector bool int __ATTRS_o_ai 6482vec_vsr(vector bool int __a, vector unsigned int __b) 6483{ 6484 return (vector bool int)__builtin_altivec_vsr((vector int)__a, (vector int)__b); 6485} 6486 6487/* vec_sro */ 6488 6489static vector signed char __ATTRS_o_ai 6490vec_sro(vector signed char __a, vector signed char __b) 6491{ 6492 return (vector signed char) 6493 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6494} 6495 6496static vector signed char __ATTRS_o_ai 6497vec_sro(vector signed char __a, vector unsigned char __b) 6498{ 6499 return (vector signed char) 6500 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6501} 6502 6503static vector unsigned char __ATTRS_o_ai 6504vec_sro(vector unsigned char __a, vector signed char __b) 6505{ 6506 return (vector unsigned char) 6507 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6508} 6509 6510static vector unsigned char __ATTRS_o_ai 6511vec_sro(vector unsigned char __a, vector unsigned char __b) 6512{ 6513 return (vector unsigned char) 6514 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6515} 6516 6517static vector short __ATTRS_o_ai 6518vec_sro(vector short __a, vector signed char __b) 6519{ 6520 return (vector short)__builtin_altivec_vsro((vector int)__a, (vector int)__b); 6521} 6522 6523static vector short __ATTRS_o_ai 6524vec_sro(vector short __a, vector unsigned char __b) 6525{ 6526 return (vector short)__builtin_altivec_vsro((vector int)__a, (vector int)__b); 6527} 6528 6529static vector unsigned short __ATTRS_o_ai 6530vec_sro(vector unsigned short __a, vector signed char __b) 6531{ 6532 return (vector unsigned short) 6533 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6534} 6535 6536static vector unsigned short __ATTRS_o_ai 6537vec_sro(vector unsigned short __a, vector unsigned char __b) 6538{ 6539 return (vector unsigned short) 6540 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6541} 6542 6543static vector pixel __ATTRS_o_ai 6544vec_sro(vector pixel __a, vector signed char __b) 6545{ 6546 return (vector pixel)__builtin_altivec_vsro((vector int)__a, (vector int)__b); 6547} 6548 6549static vector pixel __ATTRS_o_ai 6550vec_sro(vector pixel __a, vector unsigned char __b) 6551{ 6552 return (vector pixel)__builtin_altivec_vsro((vector int)__a, (vector int)__b); 6553} 6554 6555static vector int __ATTRS_o_ai 6556vec_sro(vector int __a, vector signed char __b) 6557{ 6558 return (vector int)__builtin_altivec_vsro(__a, (vector int)__b); 6559} 6560 6561static vector int __ATTRS_o_ai 6562vec_sro(vector int __a, vector unsigned char __b) 6563{ 6564 return (vector int)__builtin_altivec_vsro(__a, (vector int)__b); 6565} 6566 6567static vector unsigned int __ATTRS_o_ai 6568vec_sro(vector unsigned int __a, vector signed char __b) 6569{ 6570 return (vector unsigned int) 6571 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6572} 6573 6574static vector unsigned int __ATTRS_o_ai 6575vec_sro(vector unsigned int __a, vector unsigned char __b) 6576{ 6577 return (vector unsigned int) 6578 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6579} 6580 6581static vector float __ATTRS_o_ai 6582vec_sro(vector float __a, vector signed char __b) 6583{ 6584 return (vector float)__builtin_altivec_vsro((vector int)__a, (vector int)__b); 6585} 6586 6587static vector float __ATTRS_o_ai 6588vec_sro(vector float __a, vector unsigned char __b) 6589{ 6590 return (vector float)__builtin_altivec_vsro((vector int)__a, (vector int)__b); 6591} 6592 6593/* vec_vsro */ 6594 6595static vector signed char __ATTRS_o_ai 6596vec_vsro(vector signed char __a, vector signed char __b) 6597{ 6598 return (vector signed char) 6599 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6600} 6601 6602static vector signed char __ATTRS_o_ai 6603vec_vsro(vector signed char __a, vector unsigned char __b) 6604{ 6605 return (vector signed char) 6606 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6607} 6608 6609static vector unsigned char __ATTRS_o_ai 6610vec_vsro(vector unsigned char __a, vector signed char __b) 6611{ 6612 return (vector unsigned char) 6613 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6614} 6615 6616static vector unsigned char __ATTRS_o_ai 6617vec_vsro(vector unsigned char __a, vector unsigned char __b) 6618{ 6619 return (vector unsigned char) 6620 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6621} 6622 6623static vector short __ATTRS_o_ai 6624vec_vsro(vector short __a, vector signed char __b) 6625{ 6626 return (vector short)__builtin_altivec_vsro((vector int)__a, (vector int)__b); 6627} 6628 6629static vector short __ATTRS_o_ai 6630vec_vsro(vector short __a, vector unsigned char __b) 6631{ 6632 return (vector short)__builtin_altivec_vsro((vector int)__a, (vector int)__b); 6633} 6634 6635static vector unsigned short __ATTRS_o_ai 6636vec_vsro(vector unsigned short __a, vector signed char __b) 6637{ 6638 return (vector unsigned short) 6639 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6640} 6641 6642static vector unsigned short __ATTRS_o_ai 6643vec_vsro(vector unsigned short __a, vector unsigned char __b) 6644{ 6645 return (vector unsigned short) 6646 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6647} 6648 6649static vector pixel __ATTRS_o_ai 6650vec_vsro(vector pixel __a, vector signed char __b) 6651{ 6652 return (vector pixel)__builtin_altivec_vsro((vector int)__a, (vector int)__b); 6653} 6654 6655static vector pixel __ATTRS_o_ai 6656vec_vsro(vector pixel __a, vector unsigned char __b) 6657{ 6658 return (vector pixel)__builtin_altivec_vsro((vector int)__a, (vector int)__b); 6659} 6660 6661static vector int __ATTRS_o_ai 6662vec_vsro(vector int __a, vector signed char __b) 6663{ 6664 return (vector int)__builtin_altivec_vsro(__a, (vector int)__b); 6665} 6666 6667static vector int __ATTRS_o_ai 6668vec_vsro(vector int __a, vector unsigned char __b) 6669{ 6670 return (vector int)__builtin_altivec_vsro(__a, (vector int)__b); 6671} 6672 6673static vector unsigned int __ATTRS_o_ai 6674vec_vsro(vector unsigned int __a, vector signed char __b) 6675{ 6676 return (vector unsigned int) 6677 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6678} 6679 6680static vector unsigned int __ATTRS_o_ai 6681vec_vsro(vector unsigned int __a, vector unsigned char __b) 6682{ 6683 return (vector unsigned int) 6684 __builtin_altivec_vsro((vector int)__a, (vector int)__b); 6685} 6686 6687static vector float __ATTRS_o_ai 6688vec_vsro(vector float __a, vector signed char __b) 6689{ 6690 return (vector float)__builtin_altivec_vsro((vector int)__a, (vector int)__b); 6691} 6692 6693static vector float __ATTRS_o_ai 6694vec_vsro(vector float __a, vector unsigned char __b) 6695{ 6696 return (vector float)__builtin_altivec_vsro((vector int)__a, (vector int)__b); 6697} 6698 6699/* vec_st */ 6700 6701static void __ATTRS_o_ai 6702vec_st(vector signed char __a, int __b, vector signed char *__c) 6703{ 6704 __builtin_altivec_stvx((vector int)__a, __b, __c); 6705} 6706 6707static void __ATTRS_o_ai 6708vec_st(vector signed char __a, int __b, signed char *__c) 6709{ 6710 __builtin_altivec_stvx((vector int)__a, __b, __c); 6711} 6712 6713static void __ATTRS_o_ai 6714vec_st(vector unsigned char __a, int __b, vector unsigned char *__c) 6715{ 6716 __builtin_altivec_stvx((vector int)__a, __b, __c); 6717} 6718 6719static void __ATTRS_o_ai 6720vec_st(vector unsigned char __a, int __b, unsigned char *__c) 6721{ 6722 __builtin_altivec_stvx((vector int)__a, __b, __c); 6723} 6724 6725static void __ATTRS_o_ai 6726vec_st(vector bool char __a, int __b, signed char *__c) 6727{ 6728 __builtin_altivec_stvx((vector int)__a, __b, __c); 6729} 6730 6731static void __ATTRS_o_ai 6732vec_st(vector bool char __a, int __b, unsigned char *__c) 6733{ 6734 __builtin_altivec_stvx((vector int)__a, __b, __c); 6735} 6736 6737static void __ATTRS_o_ai 6738vec_st(vector bool char __a, int __b, vector bool char *__c) 6739{ 6740 __builtin_altivec_stvx((vector int)__a, __b, __c); 6741} 6742 6743static void __ATTRS_o_ai 6744vec_st(vector short __a, int __b, vector short *__c) 6745{ 6746 __builtin_altivec_stvx((vector int)__a, __b, __c); 6747} 6748 6749static void __ATTRS_o_ai 6750vec_st(vector short __a, int __b, short *__c) 6751{ 6752 __builtin_altivec_stvx((vector int)__a, __b, __c); 6753} 6754 6755static void __ATTRS_o_ai 6756vec_st(vector unsigned short __a, int __b, vector unsigned short *__c) 6757{ 6758 __builtin_altivec_stvx((vector int)__a, __b, __c); 6759} 6760 6761static void __ATTRS_o_ai 6762vec_st(vector unsigned short __a, int __b, unsigned short *__c) 6763{ 6764 __builtin_altivec_stvx((vector int)__a, __b, __c); 6765} 6766 6767static void __ATTRS_o_ai 6768vec_st(vector bool short __a, int __b, short *__c) 6769{ 6770 __builtin_altivec_stvx((vector int)__a, __b, __c); 6771} 6772 6773static void __ATTRS_o_ai 6774vec_st(vector bool short __a, int __b, unsigned short *__c) 6775{ 6776 __builtin_altivec_stvx((vector int)__a, __b, __c); 6777} 6778 6779static void __ATTRS_o_ai 6780vec_st(vector bool short __a, int __b, vector bool short *__c) 6781{ 6782 __builtin_altivec_stvx((vector int)__a, __b, __c); 6783} 6784 6785static void __ATTRS_o_ai 6786vec_st(vector pixel __a, int __b, short *__c) 6787{ 6788 __builtin_altivec_stvx((vector int)__a, __b, __c); 6789} 6790 6791static void __ATTRS_o_ai 6792vec_st(vector pixel __a, int __b, unsigned short *__c) 6793{ 6794 __builtin_altivec_stvx((vector int)__a, __b, __c); 6795} 6796 6797static void __ATTRS_o_ai 6798vec_st(vector pixel __a, int __b, vector pixel *__c) 6799{ 6800 __builtin_altivec_stvx((vector int)__a, __b, __c); 6801} 6802 6803static void __ATTRS_o_ai 6804vec_st(vector int __a, int __b, vector int *__c) 6805{ 6806 __builtin_altivec_stvx(__a, __b, __c); 6807} 6808 6809static void __ATTRS_o_ai 6810vec_st(vector int __a, int __b, int *__c) 6811{ 6812 __builtin_altivec_stvx(__a, __b, __c); 6813} 6814 6815static void __ATTRS_o_ai 6816vec_st(vector unsigned int __a, int __b, vector unsigned int *__c) 6817{ 6818 __builtin_altivec_stvx((vector int)__a, __b, __c); 6819} 6820 6821static void __ATTRS_o_ai 6822vec_st(vector unsigned int __a, int __b, unsigned int *__c) 6823{ 6824 __builtin_altivec_stvx((vector int)__a, __b, __c); 6825} 6826 6827static void __ATTRS_o_ai 6828vec_st(vector bool int __a, int __b, int *__c) 6829{ 6830 __builtin_altivec_stvx((vector int)__a, __b, __c); 6831} 6832 6833static void __ATTRS_o_ai 6834vec_st(vector bool int __a, int __b, unsigned int *__c) 6835{ 6836 __builtin_altivec_stvx((vector int)__a, __b, __c); 6837} 6838 6839static void __ATTRS_o_ai 6840vec_st(vector bool int __a, int __b, vector bool int *__c) 6841{ 6842 __builtin_altivec_stvx((vector int)__a, __b, __c); 6843} 6844 6845static void __ATTRS_o_ai 6846vec_st(vector float __a, int __b, vector float *__c) 6847{ 6848 __builtin_altivec_stvx((vector int)__a, __b, __c); 6849} 6850 6851static void __ATTRS_o_ai 6852vec_st(vector float __a, int __b, float *__c) 6853{ 6854 __builtin_altivec_stvx((vector int)__a, __b, __c); 6855} 6856 6857/* vec_stvx */ 6858 6859static void __ATTRS_o_ai 6860vec_stvx(vector signed char __a, int __b, vector signed char *__c) 6861{ 6862 __builtin_altivec_stvx((vector int)__a, __b, __c); 6863} 6864 6865static void __ATTRS_o_ai 6866vec_stvx(vector signed char __a, int __b, signed char *__c) 6867{ 6868 __builtin_altivec_stvx((vector int)__a, __b, __c); 6869} 6870 6871static void __ATTRS_o_ai 6872vec_stvx(vector unsigned char __a, int __b, vector unsigned char *__c) 6873{ 6874 __builtin_altivec_stvx((vector int)__a, __b, __c); 6875} 6876 6877static void __ATTRS_o_ai 6878vec_stvx(vector unsigned char __a, int __b, unsigned char *__c) 6879{ 6880 __builtin_altivec_stvx((vector int)__a, __b, __c); 6881} 6882 6883static void __ATTRS_o_ai 6884vec_stvx(vector bool char __a, int __b, signed char *__c) 6885{ 6886 __builtin_altivec_stvx((vector int)__a, __b, __c); 6887} 6888 6889static void __ATTRS_o_ai 6890vec_stvx(vector bool char __a, int __b, unsigned char *__c) 6891{ 6892 __builtin_altivec_stvx((vector int)__a, __b, __c); 6893} 6894 6895static void __ATTRS_o_ai 6896vec_stvx(vector bool char __a, int __b, vector bool char *__c) 6897{ 6898 __builtin_altivec_stvx((vector int)__a, __b, __c); 6899} 6900 6901static void __ATTRS_o_ai 6902vec_stvx(vector short __a, int __b, vector short *__c) 6903{ 6904 __builtin_altivec_stvx((vector int)__a, __b, __c); 6905} 6906 6907static void __ATTRS_o_ai 6908vec_stvx(vector short __a, int __b, short *__c) 6909{ 6910 __builtin_altivec_stvx((vector int)__a, __b, __c); 6911} 6912 6913static void __ATTRS_o_ai 6914vec_stvx(vector unsigned short __a, int __b, vector unsigned short *__c) 6915{ 6916 __builtin_altivec_stvx((vector int)__a, __b, __c); 6917} 6918 6919static void __ATTRS_o_ai 6920vec_stvx(vector unsigned short __a, int __b, unsigned short *__c) 6921{ 6922 __builtin_altivec_stvx((vector int)__a, __b, __c); 6923} 6924 6925static void __ATTRS_o_ai 6926vec_stvx(vector bool short __a, int __b, short *__c) 6927{ 6928 __builtin_altivec_stvx((vector int)__a, __b, __c); 6929} 6930 6931static void __ATTRS_o_ai 6932vec_stvx(vector bool short __a, int __b, unsigned short *__c) 6933{ 6934 __builtin_altivec_stvx((vector int)__a, __b, __c); 6935} 6936 6937static void __ATTRS_o_ai 6938vec_stvx(vector bool short __a, int __b, vector bool short *__c) 6939{ 6940 __builtin_altivec_stvx((vector int)__a, __b, __c); 6941} 6942 6943static void __ATTRS_o_ai 6944vec_stvx(vector pixel __a, int __b, short *__c) 6945{ 6946 __builtin_altivec_stvx((vector int)__a, __b, __c); 6947} 6948 6949static void __ATTRS_o_ai 6950vec_stvx(vector pixel __a, int __b, unsigned short *__c) 6951{ 6952 __builtin_altivec_stvx((vector int)__a, __b, __c); 6953} 6954 6955static void __ATTRS_o_ai 6956vec_stvx(vector pixel __a, int __b, vector pixel *__c) 6957{ 6958 __builtin_altivec_stvx((vector int)__a, __b, __c); 6959} 6960 6961static void __ATTRS_o_ai 6962vec_stvx(vector int __a, int __b, vector int *__c) 6963{ 6964 __builtin_altivec_stvx(__a, __b, __c); 6965} 6966 6967static void __ATTRS_o_ai 6968vec_stvx(vector int __a, int __b, int *__c) 6969{ 6970 __builtin_altivec_stvx(__a, __b, __c); 6971} 6972 6973static void __ATTRS_o_ai 6974vec_stvx(vector unsigned int __a, int __b, vector unsigned int *__c) 6975{ 6976 __builtin_altivec_stvx((vector int)__a, __b, __c); 6977} 6978 6979static void __ATTRS_o_ai 6980vec_stvx(vector unsigned int __a, int __b, unsigned int *__c) 6981{ 6982 __builtin_altivec_stvx((vector int)__a, __b, __c); 6983} 6984 6985static void __ATTRS_o_ai 6986vec_stvx(vector bool int __a, int __b, int *__c) 6987{ 6988 __builtin_altivec_stvx((vector int)__a, __b, __c); 6989} 6990 6991static void __ATTRS_o_ai 6992vec_stvx(vector bool int __a, int __b, unsigned int *__c) 6993{ 6994 __builtin_altivec_stvx((vector int)__a, __b, __c); 6995} 6996 6997static void __ATTRS_o_ai 6998vec_stvx(vector bool int __a, int __b, vector bool int *__c) 6999{ 7000 __builtin_altivec_stvx((vector int)__a, __b, __c); 7001} 7002 7003static void __ATTRS_o_ai 7004vec_stvx(vector float __a, int __b, vector float *__c) 7005{ 7006 __builtin_altivec_stvx((vector int)__a, __b, __c); 7007} 7008 7009static void __ATTRS_o_ai 7010vec_stvx(vector float __a, int __b, float *__c) 7011{ 7012 __builtin_altivec_stvx((vector int)__a, __b, __c); 7013} 7014 7015/* vec_ste */ 7016 7017static void __ATTRS_o_ai 7018vec_ste(vector signed char __a, int __b, signed char *__c) 7019{ 7020 __builtin_altivec_stvebx((vector char)__a, __b, __c); 7021} 7022 7023static void __ATTRS_o_ai 7024vec_ste(vector unsigned char __a, int __b, unsigned char *__c) 7025{ 7026 __builtin_altivec_stvebx((vector char)__a, __b, __c); 7027} 7028 7029static void __ATTRS_o_ai 7030vec_ste(vector bool char __a, int __b, signed char *__c) 7031{ 7032 __builtin_altivec_stvebx((vector char)__a, __b, __c); 7033} 7034 7035static void __ATTRS_o_ai 7036vec_ste(vector bool char __a, int __b, unsigned char *__c) 7037{ 7038 __builtin_altivec_stvebx((vector char)__a, __b, __c); 7039} 7040 7041static void __ATTRS_o_ai 7042vec_ste(vector short __a, int __b, short *__c) 7043{ 7044 __builtin_altivec_stvehx(__a, __b, __c); 7045} 7046 7047static void __ATTRS_o_ai 7048vec_ste(vector unsigned short __a, int __b, unsigned short *__c) 7049{ 7050 __builtin_altivec_stvehx((vector short)__a, __b, __c); 7051} 7052 7053static void __ATTRS_o_ai 7054vec_ste(vector bool short __a, int __b, short *__c) 7055{ 7056 __builtin_altivec_stvehx((vector short)__a, __b, __c); 7057} 7058 7059static void __ATTRS_o_ai 7060vec_ste(vector bool short __a, int __b, unsigned short *__c) 7061{ 7062 __builtin_altivec_stvehx((vector short)__a, __b, __c); 7063} 7064 7065static void __ATTRS_o_ai 7066vec_ste(vector pixel __a, int __b, short *__c) 7067{ 7068 __builtin_altivec_stvehx((vector short)__a, __b, __c); 7069} 7070 7071static void __ATTRS_o_ai 7072vec_ste(vector pixel __a, int __b, unsigned short *__c) 7073{ 7074 __builtin_altivec_stvehx((vector short)__a, __b, __c); 7075} 7076 7077static void __ATTRS_o_ai 7078vec_ste(vector int __a, int __b, int *__c) 7079{ 7080 __builtin_altivec_stvewx(__a, __b, __c); 7081} 7082 7083static void __ATTRS_o_ai 7084vec_ste(vector unsigned int __a, int __b, unsigned int *__c) 7085{ 7086 __builtin_altivec_stvewx((vector int)__a, __b, __c); 7087} 7088 7089static void __ATTRS_o_ai 7090vec_ste(vector bool int __a, int __b, int *__c) 7091{ 7092 __builtin_altivec_stvewx((vector int)__a, __b, __c); 7093} 7094 7095static void __ATTRS_o_ai 7096vec_ste(vector bool int __a, int __b, unsigned int *__c) 7097{ 7098 __builtin_altivec_stvewx((vector int)__a, __b, __c); 7099} 7100 7101static void __ATTRS_o_ai 7102vec_ste(vector float __a, int __b, float *__c) 7103{ 7104 __builtin_altivec_stvewx((vector int)__a, __b, __c); 7105} 7106 7107/* vec_stvebx */ 7108 7109static void __ATTRS_o_ai 7110vec_stvebx(vector signed char __a, int __b, signed char *__c) 7111{ 7112 __builtin_altivec_stvebx((vector char)__a, __b, __c); 7113} 7114 7115static void __ATTRS_o_ai 7116vec_stvebx(vector unsigned char __a, int __b, unsigned char *__c) 7117{ 7118 __builtin_altivec_stvebx((vector char)__a, __b, __c); 7119} 7120 7121static void __ATTRS_o_ai 7122vec_stvebx(vector bool char __a, int __b, signed char *__c) 7123{ 7124 __builtin_altivec_stvebx((vector char)__a, __b, __c); 7125} 7126 7127static void __ATTRS_o_ai 7128vec_stvebx(vector bool char __a, int __b, unsigned char *__c) 7129{ 7130 __builtin_altivec_stvebx((vector char)__a, __b, __c); 7131} 7132 7133/* vec_stvehx */ 7134 7135static void __ATTRS_o_ai 7136vec_stvehx(vector short __a, int __b, short *__c) 7137{ 7138 __builtin_altivec_stvehx(__a, __b, __c); 7139} 7140 7141static void __ATTRS_o_ai 7142vec_stvehx(vector unsigned short __a, int __b, unsigned short *__c) 7143{ 7144 __builtin_altivec_stvehx((vector short)__a, __b, __c); 7145} 7146 7147static void __ATTRS_o_ai 7148vec_stvehx(vector bool short __a, int __b, short *__c) 7149{ 7150 __builtin_altivec_stvehx((vector short)__a, __b, __c); 7151} 7152 7153static void __ATTRS_o_ai 7154vec_stvehx(vector bool short __a, int __b, unsigned short *__c) 7155{ 7156 __builtin_altivec_stvehx((vector short)__a, __b, __c); 7157} 7158 7159static void __ATTRS_o_ai 7160vec_stvehx(vector pixel __a, int __b, short *__c) 7161{ 7162 __builtin_altivec_stvehx((vector short)__a, __b, __c); 7163} 7164 7165static void __ATTRS_o_ai 7166vec_stvehx(vector pixel __a, int __b, unsigned short *__c) 7167{ 7168 __builtin_altivec_stvehx((vector short)__a, __b, __c); 7169} 7170 7171/* vec_stvewx */ 7172 7173static void __ATTRS_o_ai 7174vec_stvewx(vector int __a, int __b, int *__c) 7175{ 7176 __builtin_altivec_stvewx(__a, __b, __c); 7177} 7178 7179static void __ATTRS_o_ai 7180vec_stvewx(vector unsigned int __a, int __b, unsigned int *__c) 7181{ 7182 __builtin_altivec_stvewx((vector int)__a, __b, __c); 7183} 7184 7185static void __ATTRS_o_ai 7186vec_stvewx(vector bool int __a, int __b, int *__c) 7187{ 7188 __builtin_altivec_stvewx((vector int)__a, __b, __c); 7189} 7190 7191static void __ATTRS_o_ai 7192vec_stvewx(vector bool int __a, int __b, unsigned int *__c) 7193{ 7194 __builtin_altivec_stvewx((vector int)__a, __b, __c); 7195} 7196 7197static void __ATTRS_o_ai 7198vec_stvewx(vector float __a, int __b, float *__c) 7199{ 7200 __builtin_altivec_stvewx((vector int)__a, __b, __c); 7201} 7202 7203/* vec_stl */ 7204 7205static void __ATTRS_o_ai 7206vec_stl(vector signed char __a, int __b, vector signed char *__c) 7207{ 7208 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7209} 7210 7211static void __ATTRS_o_ai 7212vec_stl(vector signed char __a, int __b, signed char *__c) 7213{ 7214 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7215} 7216 7217static void __ATTRS_o_ai 7218vec_stl(vector unsigned char __a, int __b, vector unsigned char *__c) 7219{ 7220 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7221} 7222 7223static void __ATTRS_o_ai 7224vec_stl(vector unsigned char __a, int __b, unsigned char *__c) 7225{ 7226 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7227} 7228 7229static void __ATTRS_o_ai 7230vec_stl(vector bool char __a, int __b, signed char *__c) 7231{ 7232 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7233} 7234 7235static void __ATTRS_o_ai 7236vec_stl(vector bool char __a, int __b, unsigned char *__c) 7237{ 7238 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7239} 7240 7241static void __ATTRS_o_ai 7242vec_stl(vector bool char __a, int __b, vector bool char *__c) 7243{ 7244 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7245} 7246 7247static void __ATTRS_o_ai 7248vec_stl(vector short __a, int __b, vector short *__c) 7249{ 7250 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7251} 7252 7253static void __ATTRS_o_ai 7254vec_stl(vector short __a, int __b, short *__c) 7255{ 7256 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7257} 7258 7259static void __ATTRS_o_ai 7260vec_stl(vector unsigned short __a, int __b, vector unsigned short *__c) 7261{ 7262 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7263} 7264 7265static void __ATTRS_o_ai 7266vec_stl(vector unsigned short __a, int __b, unsigned short *__c) 7267{ 7268 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7269} 7270 7271static void __ATTRS_o_ai 7272vec_stl(vector bool short __a, int __b, short *__c) 7273{ 7274 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7275} 7276 7277static void __ATTRS_o_ai 7278vec_stl(vector bool short __a, int __b, unsigned short *__c) 7279{ 7280 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7281} 7282 7283static void __ATTRS_o_ai 7284vec_stl(vector bool short __a, int __b, vector bool short *__c) 7285{ 7286 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7287} 7288 7289static void __ATTRS_o_ai 7290vec_stl(vector pixel __a, int __b, short *__c) 7291{ 7292 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7293} 7294 7295static void __ATTRS_o_ai 7296vec_stl(vector pixel __a, int __b, unsigned short *__c) 7297{ 7298 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7299} 7300 7301static void __ATTRS_o_ai 7302vec_stl(vector pixel __a, int __b, vector pixel *__c) 7303{ 7304 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7305} 7306 7307static void __ATTRS_o_ai 7308vec_stl(vector int __a, int __b, vector int *__c) 7309{ 7310 __builtin_altivec_stvxl(__a, __b, __c); 7311} 7312 7313static void __ATTRS_o_ai 7314vec_stl(vector int __a, int __b, int *__c) 7315{ 7316 __builtin_altivec_stvxl(__a, __b, __c); 7317} 7318 7319static void __ATTRS_o_ai 7320vec_stl(vector unsigned int __a, int __b, vector unsigned int *__c) 7321{ 7322 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7323} 7324 7325static void __ATTRS_o_ai 7326vec_stl(vector unsigned int __a, int __b, unsigned int *__c) 7327{ 7328 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7329} 7330 7331static void __ATTRS_o_ai 7332vec_stl(vector bool int __a, int __b, int *__c) 7333{ 7334 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7335} 7336 7337static void __ATTRS_o_ai 7338vec_stl(vector bool int __a, int __b, unsigned int *__c) 7339{ 7340 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7341} 7342 7343static void __ATTRS_o_ai 7344vec_stl(vector bool int __a, int __b, vector bool int *__c) 7345{ 7346 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7347} 7348 7349static void __ATTRS_o_ai 7350vec_stl(vector float __a, int __b, vector float *__c) 7351{ 7352 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7353} 7354 7355static void __ATTRS_o_ai 7356vec_stl(vector float __a, int __b, float *__c) 7357{ 7358 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7359} 7360 7361/* vec_stvxl */ 7362 7363static void __ATTRS_o_ai 7364vec_stvxl(vector signed char __a, int __b, vector signed char *__c) 7365{ 7366 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7367} 7368 7369static void __ATTRS_o_ai 7370vec_stvxl(vector signed char __a, int __b, signed char *__c) 7371{ 7372 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7373} 7374 7375static void __ATTRS_o_ai 7376vec_stvxl(vector unsigned char __a, int __b, vector unsigned char *__c) 7377{ 7378 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7379} 7380 7381static void __ATTRS_o_ai 7382vec_stvxl(vector unsigned char __a, int __b, unsigned char *__c) 7383{ 7384 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7385} 7386 7387static void __ATTRS_o_ai 7388vec_stvxl(vector bool char __a, int __b, signed char *__c) 7389{ 7390 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7391} 7392 7393static void __ATTRS_o_ai 7394vec_stvxl(vector bool char __a, int __b, unsigned char *__c) 7395{ 7396 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7397} 7398 7399static void __ATTRS_o_ai 7400vec_stvxl(vector bool char __a, int __b, vector bool char *__c) 7401{ 7402 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7403} 7404 7405static void __ATTRS_o_ai 7406vec_stvxl(vector short __a, int __b, vector short *__c) 7407{ 7408 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7409} 7410 7411static void __ATTRS_o_ai 7412vec_stvxl(vector short __a, int __b, short *__c) 7413{ 7414 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7415} 7416 7417static void __ATTRS_o_ai 7418vec_stvxl(vector unsigned short __a, int __b, vector unsigned short *__c) 7419{ 7420 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7421} 7422 7423static void __ATTRS_o_ai 7424vec_stvxl(vector unsigned short __a, int __b, unsigned short *__c) 7425{ 7426 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7427} 7428 7429static void __ATTRS_o_ai 7430vec_stvxl(vector bool short __a, int __b, short *__c) 7431{ 7432 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7433} 7434 7435static void __ATTRS_o_ai 7436vec_stvxl(vector bool short __a, int __b, unsigned short *__c) 7437{ 7438 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7439} 7440 7441static void __ATTRS_o_ai 7442vec_stvxl(vector bool short __a, int __b, vector bool short *__c) 7443{ 7444 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7445} 7446 7447static void __ATTRS_o_ai 7448vec_stvxl(vector pixel __a, int __b, short *__c) 7449{ 7450 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7451} 7452 7453static void __ATTRS_o_ai 7454vec_stvxl(vector pixel __a, int __b, unsigned short *__c) 7455{ 7456 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7457} 7458 7459static void __ATTRS_o_ai 7460vec_stvxl(vector pixel __a, int __b, vector pixel *__c) 7461{ 7462 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7463} 7464 7465static void __ATTRS_o_ai 7466vec_stvxl(vector int __a, int __b, vector int *__c) 7467{ 7468 __builtin_altivec_stvxl(__a, __b, __c); 7469} 7470 7471static void __ATTRS_o_ai 7472vec_stvxl(vector int __a, int __b, int *__c) 7473{ 7474 __builtin_altivec_stvxl(__a, __b, __c); 7475} 7476 7477static void __ATTRS_o_ai 7478vec_stvxl(vector unsigned int __a, int __b, vector unsigned int *__c) 7479{ 7480 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7481} 7482 7483static void __ATTRS_o_ai 7484vec_stvxl(vector unsigned int __a, int __b, unsigned int *__c) 7485{ 7486 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7487} 7488 7489static void __ATTRS_o_ai 7490vec_stvxl(vector bool int __a, int __b, int *__c) 7491{ 7492 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7493} 7494 7495static void __ATTRS_o_ai 7496vec_stvxl(vector bool int __a, int __b, unsigned int *__c) 7497{ 7498 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7499} 7500 7501static void __ATTRS_o_ai 7502vec_stvxl(vector bool int __a, int __b, vector bool int *__c) 7503{ 7504 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7505} 7506 7507static void __ATTRS_o_ai 7508vec_stvxl(vector float __a, int __b, vector float *__c) 7509{ 7510 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7511} 7512 7513static void __ATTRS_o_ai 7514vec_stvxl(vector float __a, int __b, float *__c) 7515{ 7516 __builtin_altivec_stvxl((vector int)__a, __b, __c); 7517} 7518 7519/* vec_sub */ 7520 7521static vector signed char __ATTRS_o_ai 7522vec_sub(vector signed char __a, vector signed char __b) 7523{ 7524 return __a - __b; 7525} 7526 7527static vector signed char __ATTRS_o_ai 7528vec_sub(vector bool char __a, vector signed char __b) 7529{ 7530 return (vector signed char)__a - __b; 7531} 7532 7533static vector signed char __ATTRS_o_ai 7534vec_sub(vector signed char __a, vector bool char __b) 7535{ 7536 return __a - (vector signed char)__b; 7537} 7538 7539static vector unsigned char __ATTRS_o_ai 7540vec_sub(vector unsigned char __a, vector unsigned char __b) 7541{ 7542 return __a - __b; 7543} 7544 7545static vector unsigned char __ATTRS_o_ai 7546vec_sub(vector bool char __a, vector unsigned char __b) 7547{ 7548 return (vector unsigned char)__a - __b; 7549} 7550 7551static vector unsigned char __ATTRS_o_ai 7552vec_sub(vector unsigned char __a, vector bool char __b) 7553{ 7554 return __a - (vector unsigned char)__b; 7555} 7556 7557static vector short __ATTRS_o_ai 7558vec_sub(vector short __a, vector short __b) 7559{ 7560 return __a - __b; 7561} 7562 7563static vector short __ATTRS_o_ai 7564vec_sub(vector bool short __a, vector short __b) 7565{ 7566 return (vector short)__a - __b; 7567} 7568 7569static vector short __ATTRS_o_ai 7570vec_sub(vector short __a, vector bool short __b) 7571{ 7572 return __a - (vector short)__b; 7573} 7574 7575static vector unsigned short __ATTRS_o_ai 7576vec_sub(vector unsigned short __a, vector unsigned short __b) 7577{ 7578 return __a - __b; 7579} 7580 7581static vector unsigned short __ATTRS_o_ai 7582vec_sub(vector bool short __a, vector unsigned short __b) 7583{ 7584 return (vector unsigned short)__a - __b; 7585} 7586 7587static vector unsigned short __ATTRS_o_ai 7588vec_sub(vector unsigned short __a, vector bool short __b) 7589{ 7590 return __a - (vector unsigned short)__b; 7591} 7592 7593static vector int __ATTRS_o_ai 7594vec_sub(vector int __a, vector int __b) 7595{ 7596 return __a - __b; 7597} 7598 7599static vector int __ATTRS_o_ai 7600vec_sub(vector bool int __a, vector int __b) 7601{ 7602 return (vector int)__a - __b; 7603} 7604 7605static vector int __ATTRS_o_ai 7606vec_sub(vector int __a, vector bool int __b) 7607{ 7608 return __a - (vector int)__b; 7609} 7610 7611static vector unsigned int __ATTRS_o_ai 7612vec_sub(vector unsigned int __a, vector unsigned int __b) 7613{ 7614 return __a - __b; 7615} 7616 7617static vector unsigned int __ATTRS_o_ai 7618vec_sub(vector bool int __a, vector unsigned int __b) 7619{ 7620 return (vector unsigned int)__a - __b; 7621} 7622 7623static vector unsigned int __ATTRS_o_ai 7624vec_sub(vector unsigned int __a, vector bool int __b) 7625{ 7626 return __a - (vector unsigned int)__b; 7627} 7628 7629static vector float __ATTRS_o_ai 7630vec_sub(vector float __a, vector float __b) 7631{ 7632 return __a - __b; 7633} 7634 7635/* vec_vsububm */ 7636 7637#define __builtin_altivec_vsububm vec_vsububm 7638 7639static vector signed char __ATTRS_o_ai 7640vec_vsububm(vector signed char __a, vector signed char __b) 7641{ 7642 return __a - __b; 7643} 7644 7645static vector signed char __ATTRS_o_ai 7646vec_vsububm(vector bool char __a, vector signed char __b) 7647{ 7648 return (vector signed char)__a - __b; 7649} 7650 7651static vector signed char __ATTRS_o_ai 7652vec_vsububm(vector signed char __a, vector bool char __b) 7653{ 7654 return __a - (vector signed char)__b; 7655} 7656 7657static vector unsigned char __ATTRS_o_ai 7658vec_vsububm(vector unsigned char __a, vector unsigned char __b) 7659{ 7660 return __a - __b; 7661} 7662 7663static vector unsigned char __ATTRS_o_ai 7664vec_vsububm(vector bool char __a, vector unsigned char __b) 7665{ 7666 return (vector unsigned char)__a - __b; 7667} 7668 7669static vector unsigned char __ATTRS_o_ai 7670vec_vsububm(vector unsigned char __a, vector bool char __b) 7671{ 7672 return __a - (vector unsigned char)__b; 7673} 7674 7675/* vec_vsubuhm */ 7676 7677#define __builtin_altivec_vsubuhm vec_vsubuhm 7678 7679static vector short __ATTRS_o_ai 7680vec_vsubuhm(vector short __a, vector short __b) 7681{ 7682 return __a - __b; 7683} 7684 7685static vector short __ATTRS_o_ai 7686vec_vsubuhm(vector bool short __a, vector short __b) 7687{ 7688 return (vector short)__a - __b; 7689} 7690 7691static vector short __ATTRS_o_ai 7692vec_vsubuhm(vector short __a, vector bool short __b) 7693{ 7694 return __a - (vector short)__b; 7695} 7696 7697static vector unsigned short __ATTRS_o_ai 7698vec_vsubuhm(vector unsigned short __a, vector unsigned short __b) 7699{ 7700 return __a - __b; 7701} 7702 7703static vector unsigned short __ATTRS_o_ai 7704vec_vsubuhm(vector bool short __a, vector unsigned short __b) 7705{ 7706 return (vector unsigned short)__a - __b; 7707} 7708 7709static vector unsigned short __ATTRS_o_ai 7710vec_vsubuhm(vector unsigned short __a, vector bool short __b) 7711{ 7712 return __a - (vector unsigned short)__b; 7713} 7714 7715/* vec_vsubuwm */ 7716 7717#define __builtin_altivec_vsubuwm vec_vsubuwm 7718 7719static vector int __ATTRS_o_ai 7720vec_vsubuwm(vector int __a, vector int __b) 7721{ 7722 return __a - __b; 7723} 7724 7725static vector int __ATTRS_o_ai 7726vec_vsubuwm(vector bool int __a, vector int __b) 7727{ 7728 return (vector int)__a - __b; 7729} 7730 7731static vector int __ATTRS_o_ai 7732vec_vsubuwm(vector int __a, vector bool int __b) 7733{ 7734 return __a - (vector int)__b; 7735} 7736 7737static vector unsigned int __ATTRS_o_ai 7738vec_vsubuwm(vector unsigned int __a, vector unsigned int __b) 7739{ 7740 return __a - __b; 7741} 7742 7743static vector unsigned int __ATTRS_o_ai 7744vec_vsubuwm(vector bool int __a, vector unsigned int __b) 7745{ 7746 return (vector unsigned int)__a - __b; 7747} 7748 7749static vector unsigned int __ATTRS_o_ai 7750vec_vsubuwm(vector unsigned int __a, vector bool int __b) 7751{ 7752 return __a - (vector unsigned int)__b; 7753} 7754 7755/* vec_vsubfp */ 7756 7757#define __builtin_altivec_vsubfp vec_vsubfp 7758 7759static vector float __attribute__((__always_inline__)) 7760vec_vsubfp(vector float __a, vector float __b) 7761{ 7762 return __a - __b; 7763} 7764 7765/* vec_subc */ 7766 7767static vector unsigned int __attribute__((__always_inline__)) 7768vec_subc(vector unsigned int __a, vector unsigned int __b) 7769{ 7770 return __builtin_altivec_vsubcuw(__a, __b); 7771} 7772 7773/* vec_vsubcuw */ 7774 7775static vector unsigned int __attribute__((__always_inline__)) 7776vec_vsubcuw(vector unsigned int __a, vector unsigned int __b) 7777{ 7778 return __builtin_altivec_vsubcuw(__a, __b); 7779} 7780 7781/* vec_subs */ 7782 7783static vector signed char __ATTRS_o_ai 7784vec_subs(vector signed char __a, vector signed char __b) 7785{ 7786 return __builtin_altivec_vsubsbs(__a, __b); 7787} 7788 7789static vector signed char __ATTRS_o_ai 7790vec_subs(vector bool char __a, vector signed char __b) 7791{ 7792 return __builtin_altivec_vsubsbs((vector signed char)__a, __b); 7793} 7794 7795static vector signed char __ATTRS_o_ai 7796vec_subs(vector signed char __a, vector bool char __b) 7797{ 7798 return __builtin_altivec_vsubsbs(__a, (vector signed char)__b); 7799} 7800 7801static vector unsigned char __ATTRS_o_ai 7802vec_subs(vector unsigned char __a, vector unsigned char __b) 7803{ 7804 return __builtin_altivec_vsububs(__a, __b); 7805} 7806 7807static vector unsigned char __ATTRS_o_ai 7808vec_subs(vector bool char __a, vector unsigned char __b) 7809{ 7810 return __builtin_altivec_vsububs((vector unsigned char)__a, __b); 7811} 7812 7813static vector unsigned char __ATTRS_o_ai 7814vec_subs(vector unsigned char __a, vector bool char __b) 7815{ 7816 return __builtin_altivec_vsububs(__a, (vector unsigned char)__b); 7817} 7818 7819static vector short __ATTRS_o_ai 7820vec_subs(vector short __a, vector short __b) 7821{ 7822 return __builtin_altivec_vsubshs(__a, __b); 7823} 7824 7825static vector short __ATTRS_o_ai 7826vec_subs(vector bool short __a, vector short __b) 7827{ 7828 return __builtin_altivec_vsubshs((vector short)__a, __b); 7829} 7830 7831static vector short __ATTRS_o_ai 7832vec_subs(vector short __a, vector bool short __b) 7833{ 7834 return __builtin_altivec_vsubshs(__a, (vector short)__b); 7835} 7836 7837static vector unsigned short __ATTRS_o_ai 7838vec_subs(vector unsigned short __a, vector unsigned short __b) 7839{ 7840 return __builtin_altivec_vsubuhs(__a, __b); 7841} 7842 7843static vector unsigned short __ATTRS_o_ai 7844vec_subs(vector bool short __a, vector unsigned short __b) 7845{ 7846 return __builtin_altivec_vsubuhs((vector unsigned short)__a, __b); 7847} 7848 7849static vector unsigned short __ATTRS_o_ai 7850vec_subs(vector unsigned short __a, vector bool short __b) 7851{ 7852 return __builtin_altivec_vsubuhs(__a, (vector unsigned short)__b); 7853} 7854 7855static vector int __ATTRS_o_ai 7856vec_subs(vector int __a, vector int __b) 7857{ 7858 return __builtin_altivec_vsubsws(__a, __b); 7859} 7860 7861static vector int __ATTRS_o_ai 7862vec_subs(vector bool int __a, vector int __b) 7863{ 7864 return __builtin_altivec_vsubsws((vector int)__a, __b); 7865} 7866 7867static vector int __ATTRS_o_ai 7868vec_subs(vector int __a, vector bool int __b) 7869{ 7870 return __builtin_altivec_vsubsws(__a, (vector int)__b); 7871} 7872 7873static vector unsigned int __ATTRS_o_ai 7874vec_subs(vector unsigned int __a, vector unsigned int __b) 7875{ 7876 return __builtin_altivec_vsubuws(__a, __b); 7877} 7878 7879static vector unsigned int __ATTRS_o_ai 7880vec_subs(vector bool int __a, vector unsigned int __b) 7881{ 7882 return __builtin_altivec_vsubuws((vector unsigned int)__a, __b); 7883} 7884 7885static vector unsigned int __ATTRS_o_ai 7886vec_subs(vector unsigned int __a, vector bool int __b) 7887{ 7888 return __builtin_altivec_vsubuws(__a, (vector unsigned int)__b); 7889} 7890 7891/* vec_vsubsbs */ 7892 7893static vector signed char __ATTRS_o_ai 7894vec_vsubsbs(vector signed char __a, vector signed char __b) 7895{ 7896 return __builtin_altivec_vsubsbs(__a, __b); 7897} 7898 7899static vector signed char __ATTRS_o_ai 7900vec_vsubsbs(vector bool char __a, vector signed char __b) 7901{ 7902 return __builtin_altivec_vsubsbs((vector signed char)__a, __b); 7903} 7904 7905static vector signed char __ATTRS_o_ai 7906vec_vsubsbs(vector signed char __a, vector bool char __b) 7907{ 7908 return __builtin_altivec_vsubsbs(__a, (vector signed char)__b); 7909} 7910 7911/* vec_vsububs */ 7912 7913static vector unsigned char __ATTRS_o_ai 7914vec_vsububs(vector unsigned char __a, vector unsigned char __b) 7915{ 7916 return __builtin_altivec_vsububs(__a, __b); 7917} 7918 7919static vector unsigned char __ATTRS_o_ai 7920vec_vsububs(vector bool char __a, vector unsigned char __b) 7921{ 7922 return __builtin_altivec_vsububs((vector unsigned char)__a, __b); 7923} 7924 7925static vector unsigned char __ATTRS_o_ai 7926vec_vsububs(vector unsigned char __a, vector bool char __b) 7927{ 7928 return __builtin_altivec_vsububs(__a, (vector unsigned char)__b); 7929} 7930 7931/* vec_vsubshs */ 7932 7933static vector short __ATTRS_o_ai 7934vec_vsubshs(vector short __a, vector short __b) 7935{ 7936 return __builtin_altivec_vsubshs(__a, __b); 7937} 7938 7939static vector short __ATTRS_o_ai 7940vec_vsubshs(vector bool short __a, vector short __b) 7941{ 7942 return __builtin_altivec_vsubshs((vector short)__a, __b); 7943} 7944 7945static vector short __ATTRS_o_ai 7946vec_vsubshs(vector short __a, vector bool short __b) 7947{ 7948 return __builtin_altivec_vsubshs(__a, (vector short)__b); 7949} 7950 7951/* vec_vsubuhs */ 7952 7953static vector unsigned short __ATTRS_o_ai 7954vec_vsubuhs(vector unsigned short __a, vector unsigned short __b) 7955{ 7956 return __builtin_altivec_vsubuhs(__a, __b); 7957} 7958 7959static vector unsigned short __ATTRS_o_ai 7960vec_vsubuhs(vector bool short __a, vector unsigned short __b) 7961{ 7962 return __builtin_altivec_vsubuhs((vector unsigned short)__a, __b); 7963} 7964 7965static vector unsigned short __ATTRS_o_ai 7966vec_vsubuhs(vector unsigned short __a, vector bool short __b) 7967{ 7968 return __builtin_altivec_vsubuhs(__a, (vector unsigned short)__b); 7969} 7970 7971/* vec_vsubsws */ 7972 7973static vector int __ATTRS_o_ai 7974vec_vsubsws(vector int __a, vector int __b) 7975{ 7976 return __builtin_altivec_vsubsws(__a, __b); 7977} 7978 7979static vector int __ATTRS_o_ai 7980vec_vsubsws(vector bool int __a, vector int __b) 7981{ 7982 return __builtin_altivec_vsubsws((vector int)__a, __b); 7983} 7984 7985static vector int __ATTRS_o_ai 7986vec_vsubsws(vector int __a, vector bool int __b) 7987{ 7988 return __builtin_altivec_vsubsws(__a, (vector int)__b); 7989} 7990 7991/* vec_vsubuws */ 7992 7993static vector unsigned int __ATTRS_o_ai 7994vec_vsubuws(vector unsigned int __a, vector unsigned int __b) 7995{ 7996 return __builtin_altivec_vsubuws(__a, __b); 7997} 7998 7999static vector unsigned int __ATTRS_o_ai 8000vec_vsubuws(vector bool int __a, vector unsigned int __b) 8001{ 8002 return __builtin_altivec_vsubuws((vector unsigned int)__a, __b); 8003} 8004 8005static vector unsigned int __ATTRS_o_ai 8006vec_vsubuws(vector unsigned int __a, vector bool int __b) 8007{ 8008 return __builtin_altivec_vsubuws(__a, (vector unsigned int)__b); 8009} 8010 8011/* vec_sum4s */ 8012 8013static vector int __ATTRS_o_ai 8014vec_sum4s(vector signed char __a, vector int __b) 8015{ 8016 return __builtin_altivec_vsum4sbs(__a, __b); 8017} 8018 8019static vector unsigned int __ATTRS_o_ai 8020vec_sum4s(vector unsigned char __a, vector unsigned int __b) 8021{ 8022 return __builtin_altivec_vsum4ubs(__a, __b); 8023} 8024 8025static vector int __ATTRS_o_ai 8026vec_sum4s(vector signed short __a, vector int __b) 8027{ 8028 return __builtin_altivec_vsum4shs(__a, __b); 8029} 8030 8031/* vec_vsum4sbs */ 8032 8033static vector int __attribute__((__always_inline__)) 8034vec_vsum4sbs(vector signed char __a, vector int __b) 8035{ 8036 return __builtin_altivec_vsum4sbs(__a, __b); 8037} 8038 8039/* vec_vsum4ubs */ 8040 8041static vector unsigned int __attribute__((__always_inline__)) 8042vec_vsum4ubs(vector unsigned char __a, vector unsigned int __b) 8043{ 8044 return __builtin_altivec_vsum4ubs(__a, __b); 8045} 8046 8047/* vec_vsum4shs */ 8048 8049static vector int __attribute__((__always_inline__)) 8050vec_vsum4shs(vector signed short __a, vector int __b) 8051{ 8052 return __builtin_altivec_vsum4shs(__a, __b); 8053} 8054 8055/* vec_sum2s */ 8056 8057static vector signed int __attribute__((__always_inline__)) 8058vec_sum2s(vector int __a, vector int __b) 8059{ 8060 return __builtin_altivec_vsum2sws(__a, __b); 8061} 8062 8063/* vec_vsum2sws */ 8064 8065static vector signed int __attribute__((__always_inline__)) 8066vec_vsum2sws(vector int __a, vector int __b) 8067{ 8068 return __builtin_altivec_vsum2sws(__a, __b); 8069} 8070 8071/* vec_sums */ 8072 8073static vector signed int __attribute__((__always_inline__)) 8074vec_sums(vector signed int __a, vector signed int __b) 8075{ 8076 return __builtin_altivec_vsumsws(__a, __b); 8077} 8078 8079/* vec_vsumsws */ 8080 8081static vector signed int __attribute__((__always_inline__)) 8082vec_vsumsws(vector signed int __a, vector signed int __b) 8083{ 8084 return __builtin_altivec_vsumsws(__a, __b); 8085} 8086 8087/* vec_trunc */ 8088 8089static vector float __attribute__((__always_inline__)) 8090vec_trunc(vector float __a) 8091{ 8092 return __builtin_altivec_vrfiz(__a); 8093} 8094 8095/* vec_vrfiz */ 8096 8097static vector float __attribute__((__always_inline__)) 8098vec_vrfiz(vector float __a) 8099{ 8100 return __builtin_altivec_vrfiz(__a); 8101} 8102 8103/* vec_unpackh */ 8104 8105static vector short __ATTRS_o_ai 8106vec_unpackh(vector signed char __a) 8107{ 8108 return __builtin_altivec_vupkhsb((vector char)__a); 8109} 8110 8111static vector bool short __ATTRS_o_ai 8112vec_unpackh(vector bool char __a) 8113{ 8114 return (vector bool short)__builtin_altivec_vupkhsb((vector char)__a); 8115} 8116 8117static vector int __ATTRS_o_ai 8118vec_unpackh(vector short __a) 8119{ 8120 return __builtin_altivec_vupkhsh(__a); 8121} 8122 8123static vector bool int __ATTRS_o_ai 8124vec_unpackh(vector bool short __a) 8125{ 8126 return (vector bool int)__builtin_altivec_vupkhsh((vector short)__a); 8127} 8128 8129static vector unsigned int __ATTRS_o_ai 8130vec_unpackh(vector pixel __a) 8131{ 8132 return (vector unsigned int)__builtin_altivec_vupkhsh((vector short)__a); 8133} 8134 8135/* vec_vupkhsb */ 8136 8137static vector short __ATTRS_o_ai 8138vec_vupkhsb(vector signed char __a) 8139{ 8140 return __builtin_altivec_vupkhsb((vector char)__a); 8141} 8142 8143static vector bool short __ATTRS_o_ai 8144vec_vupkhsb(vector bool char __a) 8145{ 8146 return (vector bool short)__builtin_altivec_vupkhsb((vector char)__a); 8147} 8148 8149/* vec_vupkhsh */ 8150 8151static vector int __ATTRS_o_ai 8152vec_vupkhsh(vector short __a) 8153{ 8154 return __builtin_altivec_vupkhsh(__a); 8155} 8156 8157static vector bool int __ATTRS_o_ai 8158vec_vupkhsh(vector bool short __a) 8159{ 8160 return (vector bool int)__builtin_altivec_vupkhsh((vector short)__a); 8161} 8162 8163static vector unsigned int __ATTRS_o_ai 8164vec_vupkhsh(vector pixel __a) 8165{ 8166 return (vector unsigned int)__builtin_altivec_vupkhsh((vector short)__a); 8167} 8168 8169/* vec_unpackl */ 8170 8171static vector short __ATTRS_o_ai 8172vec_unpackl(vector signed char __a) 8173{ 8174 return __builtin_altivec_vupklsb((vector char)__a); 8175} 8176 8177static vector bool short __ATTRS_o_ai 8178vec_unpackl(vector bool char __a) 8179{ 8180 return (vector bool short)__builtin_altivec_vupklsb((vector char)__a); 8181} 8182 8183static vector int __ATTRS_o_ai 8184vec_unpackl(vector short __a) 8185{ 8186 return __builtin_altivec_vupklsh(__a); 8187} 8188 8189static vector bool int __ATTRS_o_ai 8190vec_unpackl(vector bool short __a) 8191{ 8192 return (vector bool int)__builtin_altivec_vupklsh((vector short)__a); 8193} 8194 8195static vector unsigned int __ATTRS_o_ai 8196vec_unpackl(vector pixel __a) 8197{ 8198 return (vector unsigned int)__builtin_altivec_vupklsh((vector short)__a); 8199} 8200 8201/* vec_vupklsb */ 8202 8203static vector short __ATTRS_o_ai 8204vec_vupklsb(vector signed char __a) 8205{ 8206 return __builtin_altivec_vupklsb((vector char)__a); 8207} 8208 8209static vector bool short __ATTRS_o_ai 8210vec_vupklsb(vector bool char __a) 8211{ 8212 return (vector bool short)__builtin_altivec_vupklsb((vector char)__a); 8213} 8214 8215/* vec_vupklsh */ 8216 8217static vector int __ATTRS_o_ai 8218vec_vupklsh(vector short __a) 8219{ 8220 return __builtin_altivec_vupklsh(__a); 8221} 8222 8223static vector bool int __ATTRS_o_ai 8224vec_vupklsh(vector bool short __a) 8225{ 8226 return (vector bool int)__builtin_altivec_vupklsh((vector short)__a); 8227} 8228 8229static vector unsigned int __ATTRS_o_ai 8230vec_vupklsh(vector pixel __a) 8231{ 8232 return (vector unsigned int)__builtin_altivec_vupklsh((vector short)__a); 8233} 8234 8235/* vec_xor */ 8236 8237#define __builtin_altivec_vxor vec_xor 8238 8239static vector signed char __ATTRS_o_ai 8240vec_xor(vector signed char __a, vector signed char __b) 8241{ 8242 return __a ^ __b; 8243} 8244 8245static vector signed char __ATTRS_o_ai 8246vec_xor(vector bool char __a, vector signed char __b) 8247{ 8248 return (vector signed char)__a ^ __b; 8249} 8250 8251static vector signed char __ATTRS_o_ai 8252vec_xor(vector signed char __a, vector bool char __b) 8253{ 8254 return __a ^ (vector signed char)__b; 8255} 8256 8257static vector unsigned char __ATTRS_o_ai 8258vec_xor(vector unsigned char __a, vector unsigned char __b) 8259{ 8260 return __a ^ __b; 8261} 8262 8263static vector unsigned char __ATTRS_o_ai 8264vec_xor(vector bool char __a, vector unsigned char __b) 8265{ 8266 return (vector unsigned char)__a ^ __b; 8267} 8268 8269static vector unsigned char __ATTRS_o_ai 8270vec_xor(vector unsigned char __a, vector bool char __b) 8271{ 8272 return __a ^ (vector unsigned char)__b; 8273} 8274 8275static vector bool char __ATTRS_o_ai 8276vec_xor(vector bool char __a, vector bool char __b) 8277{ 8278 return __a ^ __b; 8279} 8280 8281static vector short __ATTRS_o_ai 8282vec_xor(vector short __a, vector short __b) 8283{ 8284 return __a ^ __b; 8285} 8286 8287static vector short __ATTRS_o_ai 8288vec_xor(vector bool short __a, vector short __b) 8289{ 8290 return (vector short)__a ^ __b; 8291} 8292 8293static vector short __ATTRS_o_ai 8294vec_xor(vector short __a, vector bool short __b) 8295{ 8296 return __a ^ (vector short)__b; 8297} 8298 8299static vector unsigned short __ATTRS_o_ai 8300vec_xor(vector unsigned short __a, vector unsigned short __b) 8301{ 8302 return __a ^ __b; 8303} 8304 8305static vector unsigned short __ATTRS_o_ai 8306vec_xor(vector bool short __a, vector unsigned short __b) 8307{ 8308 return (vector unsigned short)__a ^ __b; 8309} 8310 8311static vector unsigned short __ATTRS_o_ai 8312vec_xor(vector unsigned short __a, vector bool short __b) 8313{ 8314 return __a ^ (vector unsigned short)__b; 8315} 8316 8317static vector bool short __ATTRS_o_ai 8318vec_xor(vector bool short __a, vector bool short __b) 8319{ 8320 return __a ^ __b; 8321} 8322 8323static vector int __ATTRS_o_ai 8324vec_xor(vector int __a, vector int __b) 8325{ 8326 return __a ^ __b; 8327} 8328 8329static vector int __ATTRS_o_ai 8330vec_xor(vector bool int __a, vector int __b) 8331{ 8332 return (vector int)__a ^ __b; 8333} 8334 8335static vector int __ATTRS_o_ai 8336vec_xor(vector int __a, vector bool int __b) 8337{ 8338 return __a ^ (vector int)__b; 8339} 8340 8341static vector unsigned int __ATTRS_o_ai 8342vec_xor(vector unsigned int __a, vector unsigned int __b) 8343{ 8344 return __a ^ __b; 8345} 8346 8347static vector unsigned int __ATTRS_o_ai 8348vec_xor(vector bool int __a, vector unsigned int __b) 8349{ 8350 return (vector unsigned int)__a ^ __b; 8351} 8352 8353static vector unsigned int __ATTRS_o_ai 8354vec_xor(vector unsigned int __a, vector bool int __b) 8355{ 8356 return __a ^ (vector unsigned int)__b; 8357} 8358 8359static vector bool int __ATTRS_o_ai 8360vec_xor(vector bool int __a, vector bool int __b) 8361{ 8362 return __a ^ __b; 8363} 8364 8365static vector float __ATTRS_o_ai 8366vec_xor(vector float __a, vector float __b) 8367{ 8368 vector unsigned int __res = (vector unsigned int)__a ^ (vector unsigned int)__b; 8369 return (vector float)__res; 8370} 8371 8372static vector float __ATTRS_o_ai 8373vec_xor(vector bool int __a, vector float __b) 8374{ 8375 vector unsigned int __res = (vector unsigned int)__a ^ (vector unsigned int)__b; 8376 return (vector float)__res; 8377} 8378 8379static vector float __ATTRS_o_ai 8380vec_xor(vector float __a, vector bool int __b) 8381{ 8382 vector unsigned int __res = (vector unsigned int)__a ^ (vector unsigned int)__b; 8383 return (vector float)__res; 8384} 8385 8386/* vec_vxor */ 8387 8388static vector signed char __ATTRS_o_ai 8389vec_vxor(vector signed char __a, vector signed char __b) 8390{ 8391 return __a ^ __b; 8392} 8393 8394static vector signed char __ATTRS_o_ai 8395vec_vxor(vector bool char __a, vector signed char __b) 8396{ 8397 return (vector signed char)__a ^ __b; 8398} 8399 8400static vector signed char __ATTRS_o_ai 8401vec_vxor(vector signed char __a, vector bool char __b) 8402{ 8403 return __a ^ (vector signed char)__b; 8404} 8405 8406static vector unsigned char __ATTRS_o_ai 8407vec_vxor(vector unsigned char __a, vector unsigned char __b) 8408{ 8409 return __a ^ __b; 8410} 8411 8412static vector unsigned char __ATTRS_o_ai 8413vec_vxor(vector bool char __a, vector unsigned char __b) 8414{ 8415 return (vector unsigned char)__a ^ __b; 8416} 8417 8418static vector unsigned char __ATTRS_o_ai 8419vec_vxor(vector unsigned char __a, vector bool char __b) 8420{ 8421 return __a ^ (vector unsigned char)__b; 8422} 8423 8424static vector bool char __ATTRS_o_ai 8425vec_vxor(vector bool char __a, vector bool char __b) 8426{ 8427 return __a ^ __b; 8428} 8429 8430static vector short __ATTRS_o_ai 8431vec_vxor(vector short __a, vector short __b) 8432{ 8433 return __a ^ __b; 8434} 8435 8436static vector short __ATTRS_o_ai 8437vec_vxor(vector bool short __a, vector short __b) 8438{ 8439 return (vector short)__a ^ __b; 8440} 8441 8442static vector short __ATTRS_o_ai 8443vec_vxor(vector short __a, vector bool short __b) 8444{ 8445 return __a ^ (vector short)__b; 8446} 8447 8448static vector unsigned short __ATTRS_o_ai 8449vec_vxor(vector unsigned short __a, vector unsigned short __b) 8450{ 8451 return __a ^ __b; 8452} 8453 8454static vector unsigned short __ATTRS_o_ai 8455vec_vxor(vector bool short __a, vector unsigned short __b) 8456{ 8457 return (vector unsigned short)__a ^ __b; 8458} 8459 8460static vector unsigned short __ATTRS_o_ai 8461vec_vxor(vector unsigned short __a, vector bool short __b) 8462{ 8463 return __a ^ (vector unsigned short)__b; 8464} 8465 8466static vector bool short __ATTRS_o_ai 8467vec_vxor(vector bool short __a, vector bool short __b) 8468{ 8469 return __a ^ __b; 8470} 8471 8472static vector int __ATTRS_o_ai 8473vec_vxor(vector int __a, vector int __b) 8474{ 8475 return __a ^ __b; 8476} 8477 8478static vector int __ATTRS_o_ai 8479vec_vxor(vector bool int __a, vector int __b) 8480{ 8481 return (vector int)__a ^ __b; 8482} 8483 8484static vector int __ATTRS_o_ai 8485vec_vxor(vector int __a, vector bool int __b) 8486{ 8487 return __a ^ (vector int)__b; 8488} 8489 8490static vector unsigned int __ATTRS_o_ai 8491vec_vxor(vector unsigned int __a, vector unsigned int __b) 8492{ 8493 return __a ^ __b; 8494} 8495 8496static vector unsigned int __ATTRS_o_ai 8497vec_vxor(vector bool int __a, vector unsigned int __b) 8498{ 8499 return (vector unsigned int)__a ^ __b; 8500} 8501 8502static vector unsigned int __ATTRS_o_ai 8503vec_vxor(vector unsigned int __a, vector bool int __b) 8504{ 8505 return __a ^ (vector unsigned int)__b; 8506} 8507 8508static vector bool int __ATTRS_o_ai 8509vec_vxor(vector bool int __a, vector bool int __b) 8510{ 8511 return __a ^ __b; 8512} 8513 8514static vector float __ATTRS_o_ai 8515vec_vxor(vector float __a, vector float __b) 8516{ 8517 vector unsigned int __res = (vector unsigned int)__a ^ (vector unsigned int)__b; 8518 return (vector float)__res; 8519} 8520 8521static vector float __ATTRS_o_ai 8522vec_vxor(vector bool int __a, vector float __b) 8523{ 8524 vector unsigned int __res = (vector unsigned int)__a ^ (vector unsigned int)__b; 8525 return (vector float)__res; 8526} 8527 8528static vector float __ATTRS_o_ai 8529vec_vxor(vector float __a, vector bool int __b) 8530{ 8531 vector unsigned int __res = (vector unsigned int)__a ^ (vector unsigned int)__b; 8532 return (vector float)__res; 8533} 8534 8535/* ------------------------ extensions for CBEA ----------------------------- */ 8536 8537/* vec_extract */ 8538 8539static signed char __ATTRS_o_ai 8540vec_extract(vector signed char __a, int __b) 8541{ 8542 return __a[__b]; 8543} 8544 8545static unsigned char __ATTRS_o_ai 8546vec_extract(vector unsigned char __a, int __b) 8547{ 8548 return __a[__b]; 8549} 8550 8551static short __ATTRS_o_ai 8552vec_extract(vector short __a, int __b) 8553{ 8554 return __a[__b]; 8555} 8556 8557static unsigned short __ATTRS_o_ai 8558vec_extract(vector unsigned short __a, int __b) 8559{ 8560 return __a[__b]; 8561} 8562 8563static int __ATTRS_o_ai 8564vec_extract(vector int __a, int __b) 8565{ 8566 return __a[__b]; 8567} 8568 8569static unsigned int __ATTRS_o_ai 8570vec_extract(vector unsigned int __a, int __b) 8571{ 8572 return __a[__b]; 8573} 8574 8575static float __ATTRS_o_ai 8576vec_extract(vector float __a, int __b) 8577{ 8578 return __a[__b]; 8579} 8580 8581/* vec_insert */ 8582 8583static vector signed char __ATTRS_o_ai 8584vec_insert(signed char __a, vector signed char __b, int __c) 8585{ 8586 __b[__c] = __a; 8587 return __b; 8588} 8589 8590static vector unsigned char __ATTRS_o_ai 8591vec_insert(unsigned char __a, vector unsigned char __b, int __c) 8592{ 8593 __b[__c] = __a; 8594 return __b; 8595} 8596 8597static vector short __ATTRS_o_ai 8598vec_insert(short __a, vector short __b, int __c) 8599{ 8600 __b[__c] = __a; 8601 return __b; 8602} 8603 8604static vector unsigned short __ATTRS_o_ai 8605vec_insert(unsigned short __a, vector unsigned short __b, int __c) 8606{ 8607 __b[__c] = __a; 8608 return __b; 8609} 8610 8611static vector int __ATTRS_o_ai 8612vec_insert(int __a, vector int __b, int __c) 8613{ 8614 __b[__c] = __a; 8615 return __b; 8616} 8617 8618static vector unsigned int __ATTRS_o_ai 8619vec_insert(unsigned int __a, vector unsigned int __b, int __c) 8620{ 8621 __b[__c] = __a; 8622 return __b; 8623} 8624 8625static vector float __ATTRS_o_ai 8626vec_insert(float __a, vector float __b, int __c) 8627{ 8628 __b[__c] = __a; 8629 return __b; 8630} 8631 8632/* vec_lvlx */ 8633 8634static vector signed char __ATTRS_o_ai 8635vec_lvlx(int __a, const signed char *__b) 8636{ 8637 return vec_perm(vec_ld(__a, __b), 8638 (vector signed char)(0), 8639 vec_lvsl(__a, __b)); 8640} 8641 8642static vector signed char __ATTRS_o_ai 8643vec_lvlx(int __a, const vector signed char *__b) 8644{ 8645 return vec_perm(vec_ld(__a, __b), 8646 (vector signed char)(0), 8647 vec_lvsl(__a, (unsigned char *)__b)); 8648} 8649 8650static vector unsigned char __ATTRS_o_ai 8651vec_lvlx(int __a, const unsigned char *__b) 8652{ 8653 return vec_perm(vec_ld(__a, __b), 8654 (vector unsigned char)(0), 8655 vec_lvsl(__a, __b)); 8656} 8657 8658static vector unsigned char __ATTRS_o_ai 8659vec_lvlx(int __a, const vector unsigned char *__b) 8660{ 8661 return vec_perm(vec_ld(__a, __b), 8662 (vector unsigned char)(0), 8663 vec_lvsl(__a, (unsigned char *)__b)); 8664} 8665 8666static vector bool char __ATTRS_o_ai 8667vec_lvlx(int __a, const vector bool char *__b) 8668{ 8669 return vec_perm(vec_ld(__a, __b), 8670 (vector bool char)(0), 8671 vec_lvsl(__a, (unsigned char *)__b)); 8672} 8673 8674static vector short __ATTRS_o_ai 8675vec_lvlx(int __a, const short *__b) 8676{ 8677 return vec_perm(vec_ld(__a, __b), 8678 (vector short)(0), 8679 vec_lvsl(__a, __b)); 8680} 8681 8682static vector short __ATTRS_o_ai 8683vec_lvlx(int __a, const vector short *__b) 8684{ 8685 return vec_perm(vec_ld(__a, __b), 8686 (vector short)(0), 8687 vec_lvsl(__a, (unsigned char *)__b)); 8688} 8689 8690static vector unsigned short __ATTRS_o_ai 8691vec_lvlx(int __a, const unsigned short *__b) 8692{ 8693 return vec_perm(vec_ld(__a, __b), 8694 (vector unsigned short)(0), 8695 vec_lvsl(__a, __b)); 8696} 8697 8698static vector unsigned short __ATTRS_o_ai 8699vec_lvlx(int __a, const vector unsigned short *__b) 8700{ 8701 return vec_perm(vec_ld(__a, __b), 8702 (vector unsigned short)(0), 8703 vec_lvsl(__a, (unsigned char *)__b)); 8704} 8705 8706static vector bool short __ATTRS_o_ai 8707vec_lvlx(int __a, const vector bool short *__b) 8708{ 8709 return vec_perm(vec_ld(__a, __b), 8710 (vector bool short)(0), 8711 vec_lvsl(__a, (unsigned char *)__b)); 8712} 8713 8714static vector pixel __ATTRS_o_ai 8715vec_lvlx(int __a, const vector pixel *__b) 8716{ 8717 return vec_perm(vec_ld(__a, __b), 8718 (vector pixel)(0), 8719 vec_lvsl(__a, (unsigned char *)__b)); 8720} 8721 8722static vector int __ATTRS_o_ai 8723vec_lvlx(int __a, const int *__b) 8724{ 8725 return vec_perm(vec_ld(__a, __b), 8726 (vector int)(0), 8727 vec_lvsl(__a, __b)); 8728} 8729 8730static vector int __ATTRS_o_ai 8731vec_lvlx(int __a, const vector int *__b) 8732{ 8733 return vec_perm(vec_ld(__a, __b), 8734 (vector int)(0), 8735 vec_lvsl(__a, (unsigned char *)__b)); 8736} 8737 8738static vector unsigned int __ATTRS_o_ai 8739vec_lvlx(int __a, const unsigned int *__b) 8740{ 8741 return vec_perm(vec_ld(__a, __b), 8742 (vector unsigned int)(0), 8743 vec_lvsl(__a, __b)); 8744} 8745 8746static vector unsigned int __ATTRS_o_ai 8747vec_lvlx(int __a, const vector unsigned int *__b) 8748{ 8749 return vec_perm(vec_ld(__a, __b), 8750 (vector unsigned int)(0), 8751 vec_lvsl(__a, (unsigned char *)__b)); 8752} 8753 8754static vector bool int __ATTRS_o_ai 8755vec_lvlx(int __a, const vector bool int *__b) 8756{ 8757 return vec_perm(vec_ld(__a, __b), 8758 (vector bool int)(0), 8759 vec_lvsl(__a, (unsigned char *)__b)); 8760} 8761 8762static vector float __ATTRS_o_ai 8763vec_lvlx(int __a, const float *__b) 8764{ 8765 return vec_perm(vec_ld(__a, __b), 8766 (vector float)(0), 8767 vec_lvsl(__a, __b)); 8768} 8769 8770static vector float __ATTRS_o_ai 8771vec_lvlx(int __a, const vector float *__b) 8772{ 8773 return vec_perm(vec_ld(__a, __b), 8774 (vector float)(0), 8775 vec_lvsl(__a, (unsigned char *)__b)); 8776} 8777 8778/* vec_lvlxl */ 8779 8780static vector signed char __ATTRS_o_ai 8781vec_lvlxl(int __a, const signed char *__b) 8782{ 8783 return vec_perm(vec_ldl(__a, __b), 8784 (vector signed char)(0), 8785 vec_lvsl(__a, __b)); 8786} 8787 8788static vector signed char __ATTRS_o_ai 8789vec_lvlxl(int __a, const vector signed char *__b) 8790{ 8791 return vec_perm(vec_ldl(__a, __b), 8792 (vector signed char)(0), 8793 vec_lvsl(__a, (unsigned char *)__b)); 8794} 8795 8796static vector unsigned char __ATTRS_o_ai 8797vec_lvlxl(int __a, const unsigned char *__b) 8798{ 8799 return vec_perm(vec_ldl(__a, __b), 8800 (vector unsigned char)(0), 8801 vec_lvsl(__a, __b)); 8802} 8803 8804static vector unsigned char __ATTRS_o_ai 8805vec_lvlxl(int __a, const vector unsigned char *__b) 8806{ 8807 return vec_perm(vec_ldl(__a, __b), 8808 (vector unsigned char)(0), 8809 vec_lvsl(__a, (unsigned char *)__b)); 8810} 8811 8812static vector bool char __ATTRS_o_ai 8813vec_lvlxl(int __a, const vector bool char *__b) 8814{ 8815 return vec_perm(vec_ldl(__a, __b), 8816 (vector bool char)(0), 8817 vec_lvsl(__a, (unsigned char *)__b)); 8818} 8819 8820static vector short __ATTRS_o_ai 8821vec_lvlxl(int __a, const short *__b) 8822{ 8823 return vec_perm(vec_ldl(__a, __b), 8824 (vector short)(0), 8825 vec_lvsl(__a, __b)); 8826} 8827 8828static vector short __ATTRS_o_ai 8829vec_lvlxl(int __a, const vector short *__b) 8830{ 8831 return vec_perm(vec_ldl(__a, __b), 8832 (vector short)(0), 8833 vec_lvsl(__a, (unsigned char *)__b)); 8834} 8835 8836static vector unsigned short __ATTRS_o_ai 8837vec_lvlxl(int __a, const unsigned short *__b) 8838{ 8839 return vec_perm(vec_ldl(__a, __b), 8840 (vector unsigned short)(0), 8841 vec_lvsl(__a, __b)); 8842} 8843 8844static vector unsigned short __ATTRS_o_ai 8845vec_lvlxl(int __a, const vector unsigned short *__b) 8846{ 8847 return vec_perm(vec_ldl(__a, __b), 8848 (vector unsigned short)(0), 8849 vec_lvsl(__a, (unsigned char *)__b)); 8850} 8851 8852static vector bool short __ATTRS_o_ai 8853vec_lvlxl(int __a, const vector bool short *__b) 8854{ 8855 return vec_perm(vec_ldl(__a, __b), 8856 (vector bool short)(0), 8857 vec_lvsl(__a, (unsigned char *)__b)); 8858} 8859 8860static vector pixel __ATTRS_o_ai 8861vec_lvlxl(int __a, const vector pixel *__b) 8862{ 8863 return vec_perm(vec_ldl(__a, __b), 8864 (vector pixel)(0), 8865 vec_lvsl(__a, (unsigned char *)__b)); 8866} 8867 8868static vector int __ATTRS_o_ai 8869vec_lvlxl(int __a, const int *__b) 8870{ 8871 return vec_perm(vec_ldl(__a, __b), 8872 (vector int)(0), 8873 vec_lvsl(__a, __b)); 8874} 8875 8876static vector int __ATTRS_o_ai 8877vec_lvlxl(int __a, const vector int *__b) 8878{ 8879 return vec_perm(vec_ldl(__a, __b), 8880 (vector int)(0), 8881 vec_lvsl(__a, (unsigned char *)__b)); 8882} 8883 8884static vector unsigned int __ATTRS_o_ai 8885vec_lvlxl(int __a, const unsigned int *__b) 8886{ 8887 return vec_perm(vec_ldl(__a, __b), 8888 (vector unsigned int)(0), 8889 vec_lvsl(__a, __b)); 8890} 8891 8892static vector unsigned int __ATTRS_o_ai 8893vec_lvlxl(int __a, const vector unsigned int *__b) 8894{ 8895 return vec_perm(vec_ldl(__a, __b), 8896 (vector unsigned int)(0), 8897 vec_lvsl(__a, (unsigned char *)__b)); 8898} 8899 8900static vector bool int __ATTRS_o_ai 8901vec_lvlxl(int __a, const vector bool int *__b) 8902{ 8903 return vec_perm(vec_ldl(__a, __b), 8904 (vector bool int)(0), 8905 vec_lvsl(__a, (unsigned char *)__b)); 8906} 8907 8908static vector float __ATTRS_o_ai 8909vec_lvlxl(int __a, const float *__b) 8910{ 8911 return vec_perm(vec_ldl(__a, __b), 8912 (vector float)(0), 8913 vec_lvsl(__a, __b)); 8914} 8915 8916static vector float __ATTRS_o_ai 8917vec_lvlxl(int __a, vector float *__b) 8918{ 8919 return vec_perm(vec_ldl(__a, __b), 8920 (vector float)(0), 8921 vec_lvsl(__a, (unsigned char *)__b)); 8922} 8923 8924/* vec_lvrx */ 8925 8926static vector signed char __ATTRS_o_ai 8927vec_lvrx(int __a, const signed char *__b) 8928{ 8929 return vec_perm((vector signed char)(0), 8930 vec_ld(__a, __b), 8931 vec_lvsl(__a, __b)); 8932} 8933 8934static vector signed char __ATTRS_o_ai 8935vec_lvrx(int __a, const vector signed char *__b) 8936{ 8937 return vec_perm((vector signed char)(0), 8938 vec_ld(__a, __b), 8939 vec_lvsl(__a, (unsigned char *)__b)); 8940} 8941 8942static vector unsigned char __ATTRS_o_ai 8943vec_lvrx(int __a, const unsigned char *__b) 8944{ 8945 return vec_perm((vector unsigned char)(0), 8946 vec_ld(__a, __b), 8947 vec_lvsl(__a, __b)); 8948} 8949 8950static vector unsigned char __ATTRS_o_ai 8951vec_lvrx(int __a, const vector unsigned char *__b) 8952{ 8953 return vec_perm((vector unsigned char)(0), 8954 vec_ld(__a, __b), 8955 vec_lvsl(__a, (unsigned char *)__b)); 8956} 8957 8958static vector bool char __ATTRS_o_ai 8959vec_lvrx(int __a, const vector bool char *__b) 8960{ 8961 return vec_perm((vector bool char)(0), 8962 vec_ld(__a, __b), 8963 vec_lvsl(__a, (unsigned char *)__b)); 8964} 8965 8966static vector short __ATTRS_o_ai 8967vec_lvrx(int __a, const short *__b) 8968{ 8969 return vec_perm((vector short)(0), 8970 vec_ld(__a, __b), 8971 vec_lvsl(__a, __b)); 8972} 8973 8974static vector short __ATTRS_o_ai 8975vec_lvrx(int __a, const vector short *__b) 8976{ 8977 return vec_perm((vector short)(0), 8978 vec_ld(__a, __b), 8979 vec_lvsl(__a, (unsigned char *)__b)); 8980} 8981 8982static vector unsigned short __ATTRS_o_ai 8983vec_lvrx(int __a, const unsigned short *__b) 8984{ 8985 return vec_perm((vector unsigned short)(0), 8986 vec_ld(__a, __b), 8987 vec_lvsl(__a, __b)); 8988} 8989 8990static vector unsigned short __ATTRS_o_ai 8991vec_lvrx(int __a, const vector unsigned short *__b) 8992{ 8993 return vec_perm((vector unsigned short)(0), 8994 vec_ld(__a, __b), 8995 vec_lvsl(__a, (unsigned char *)__b)); 8996} 8997 8998static vector bool short __ATTRS_o_ai 8999vec_lvrx(int __a, const vector bool short *__b) 9000{ 9001 return vec_perm((vector bool short)(0), 9002 vec_ld(__a, __b), 9003 vec_lvsl(__a, (unsigned char *)__b)); 9004} 9005 9006static vector pixel __ATTRS_o_ai 9007vec_lvrx(int __a, const vector pixel *__b) 9008{ 9009 return vec_perm((vector pixel)(0), 9010 vec_ld(__a, __b), 9011 vec_lvsl(__a, (unsigned char *)__b)); 9012} 9013 9014static vector int __ATTRS_o_ai 9015vec_lvrx(int __a, const int *__b) 9016{ 9017 return vec_perm((vector int)(0), 9018 vec_ld(__a, __b), 9019 vec_lvsl(__a, __b)); 9020} 9021 9022static vector int __ATTRS_o_ai 9023vec_lvrx(int __a, const vector int *__b) 9024{ 9025 return vec_perm((vector int)(0), 9026 vec_ld(__a, __b), 9027 vec_lvsl(__a, (unsigned char *)__b)); 9028} 9029 9030static vector unsigned int __ATTRS_o_ai 9031vec_lvrx(int __a, const unsigned int *__b) 9032{ 9033 return vec_perm((vector unsigned int)(0), 9034 vec_ld(__a, __b), 9035 vec_lvsl(__a, __b)); 9036} 9037 9038static vector unsigned int __ATTRS_o_ai 9039vec_lvrx(int __a, const vector unsigned int *__b) 9040{ 9041 return vec_perm((vector unsigned int)(0), 9042 vec_ld(__a, __b), 9043 vec_lvsl(__a, (unsigned char *)__b)); 9044} 9045 9046static vector bool int __ATTRS_o_ai 9047vec_lvrx(int __a, const vector bool int *__b) 9048{ 9049 return vec_perm((vector bool int)(0), 9050 vec_ld(__a, __b), 9051 vec_lvsl(__a, (unsigned char *)__b)); 9052} 9053 9054static vector float __ATTRS_o_ai 9055vec_lvrx(int __a, const float *__b) 9056{ 9057 return vec_perm((vector float)(0), 9058 vec_ld(__a, __b), 9059 vec_lvsl(__a, __b)); 9060} 9061 9062static vector float __ATTRS_o_ai 9063vec_lvrx(int __a, const vector float *__b) 9064{ 9065 return vec_perm((vector float)(0), 9066 vec_ld(__a, __b), 9067 vec_lvsl(__a, (unsigned char *)__b)); 9068} 9069 9070/* vec_lvrxl */ 9071 9072static vector signed char __ATTRS_o_ai 9073vec_lvrxl(int __a, const signed char *__b) 9074{ 9075 return vec_perm((vector signed char)(0), 9076 vec_ldl(__a, __b), 9077 vec_lvsl(__a, __b)); 9078} 9079 9080static vector signed char __ATTRS_o_ai 9081vec_lvrxl(int __a, const vector signed char *__b) 9082{ 9083 return vec_perm((vector signed char)(0), 9084 vec_ldl(__a, __b), 9085 vec_lvsl(__a, (unsigned char *)__b)); 9086} 9087 9088static vector unsigned char __ATTRS_o_ai 9089vec_lvrxl(int __a, const unsigned char *__b) 9090{ 9091 return vec_perm((vector unsigned char)(0), 9092 vec_ldl(__a, __b), 9093 vec_lvsl(__a, __b)); 9094} 9095 9096static vector unsigned char __ATTRS_o_ai 9097vec_lvrxl(int __a, const vector unsigned char *__b) 9098{ 9099 return vec_perm((vector unsigned char)(0), 9100 vec_ldl(__a, __b), 9101 vec_lvsl(__a, (unsigned char *)__b)); 9102} 9103 9104static vector bool char __ATTRS_o_ai 9105vec_lvrxl(int __a, const vector bool char *__b) 9106{ 9107 return vec_perm((vector bool char)(0), 9108 vec_ldl(__a, __b), 9109 vec_lvsl(__a, (unsigned char *)__b)); 9110} 9111 9112static vector short __ATTRS_o_ai 9113vec_lvrxl(int __a, const short *__b) 9114{ 9115 return vec_perm((vector short)(0), 9116 vec_ldl(__a, __b), 9117 vec_lvsl(__a, __b)); 9118} 9119 9120static vector short __ATTRS_o_ai 9121vec_lvrxl(int __a, const vector short *__b) 9122{ 9123 return vec_perm((vector short)(0), 9124 vec_ldl(__a, __b), 9125 vec_lvsl(__a, (unsigned char *)__b)); 9126} 9127 9128static vector unsigned short __ATTRS_o_ai 9129vec_lvrxl(int __a, const unsigned short *__b) 9130{ 9131 return vec_perm((vector unsigned short)(0), 9132 vec_ldl(__a, __b), 9133 vec_lvsl(__a, __b)); 9134} 9135 9136static vector unsigned short __ATTRS_o_ai 9137vec_lvrxl(int __a, const vector unsigned short *__b) 9138{ 9139 return vec_perm((vector unsigned short)(0), 9140 vec_ldl(__a, __b), 9141 vec_lvsl(__a, (unsigned char *)__b)); 9142} 9143 9144static vector bool short __ATTRS_o_ai 9145vec_lvrxl(int __a, const vector bool short *__b) 9146{ 9147 return vec_perm((vector bool short)(0), 9148 vec_ldl(__a, __b), 9149 vec_lvsl(__a, (unsigned char *)__b)); 9150} 9151 9152static vector pixel __ATTRS_o_ai 9153vec_lvrxl(int __a, const vector pixel *__b) 9154{ 9155 return vec_perm((vector pixel)(0), 9156 vec_ldl(__a, __b), 9157 vec_lvsl(__a, (unsigned char *)__b)); 9158} 9159 9160static vector int __ATTRS_o_ai 9161vec_lvrxl(int __a, const int *__b) 9162{ 9163 return vec_perm((vector int)(0), 9164 vec_ldl(__a, __b), 9165 vec_lvsl(__a, __b)); 9166} 9167 9168static vector int __ATTRS_o_ai 9169vec_lvrxl(int __a, const vector int *__b) 9170{ 9171 return vec_perm((vector int)(0), 9172 vec_ldl(__a, __b), 9173 vec_lvsl(__a, (unsigned char *)__b)); 9174} 9175 9176static vector unsigned int __ATTRS_o_ai 9177vec_lvrxl(int __a, const unsigned int *__b) 9178{ 9179 return vec_perm((vector unsigned int)(0), 9180 vec_ldl(__a, __b), 9181 vec_lvsl(__a, __b)); 9182} 9183 9184static vector unsigned int __ATTRS_o_ai 9185vec_lvrxl(int __a, const vector unsigned int *__b) 9186{ 9187 return vec_perm((vector unsigned int)(0), 9188 vec_ldl(__a, __b), 9189 vec_lvsl(__a, (unsigned char *)__b)); 9190} 9191 9192static vector bool int __ATTRS_o_ai 9193vec_lvrxl(int __a, const vector bool int *__b) 9194{ 9195 return vec_perm((vector bool int)(0), 9196 vec_ldl(__a, __b), 9197 vec_lvsl(__a, (unsigned char *)__b)); 9198} 9199 9200static vector float __ATTRS_o_ai 9201vec_lvrxl(int __a, const float *__b) 9202{ 9203 return vec_perm((vector float)(0), 9204 vec_ldl(__a, __b), 9205 vec_lvsl(__a, __b)); 9206} 9207 9208static vector float __ATTRS_o_ai 9209vec_lvrxl(int __a, const vector float *__b) 9210{ 9211 return vec_perm((vector float)(0), 9212 vec_ldl(__a, __b), 9213 vec_lvsl(__a, (unsigned char *)__b)); 9214} 9215 9216/* vec_stvlx */ 9217 9218static void __ATTRS_o_ai 9219vec_stvlx(vector signed char __a, int __b, signed char *__c) 9220{ 9221 return vec_st(vec_perm(vec_lvrx(__b, __c), 9222 __a, 9223 vec_lvsr(__b, __c)), 9224 __b, __c); 9225} 9226 9227static void __ATTRS_o_ai 9228vec_stvlx(vector signed char __a, int __b, vector signed char *__c) 9229{ 9230 return vec_st(vec_perm(vec_lvrx(__b, __c), 9231 __a, 9232 vec_lvsr(__b, (unsigned char *)__c)), 9233 __b, __c); 9234} 9235 9236static void __ATTRS_o_ai 9237vec_stvlx(vector unsigned char __a, int __b, unsigned char *__c) 9238{ 9239 return vec_st(vec_perm(vec_lvrx(__b, __c), 9240 __a, 9241 vec_lvsr(__b, __c)), 9242 __b, __c); 9243} 9244 9245static void __ATTRS_o_ai 9246vec_stvlx(vector unsigned char __a, int __b, vector unsigned char *__c) 9247{ 9248 return vec_st(vec_perm(vec_lvrx(__b, __c), 9249 __a, 9250 vec_lvsr(__b, (unsigned char *)__c)), 9251 __b, __c); 9252} 9253 9254static void __ATTRS_o_ai 9255vec_stvlx(vector bool char __a, int __b, vector bool char *__c) 9256{ 9257 return vec_st(vec_perm(vec_lvrx(__b, __c), 9258 __a, 9259 vec_lvsr(__b, (unsigned char *)__c)), 9260 __b, __c); 9261} 9262 9263static void __ATTRS_o_ai 9264vec_stvlx(vector short __a, int __b, short *__c) 9265{ 9266 return vec_st(vec_perm(vec_lvrx(__b, __c), 9267 __a, 9268 vec_lvsr(__b, __c)), 9269 __b, __c); 9270} 9271 9272static void __ATTRS_o_ai 9273vec_stvlx(vector short __a, int __b, vector short *__c) 9274{ 9275 return vec_st(vec_perm(vec_lvrx(__b, __c), 9276 __a, 9277 vec_lvsr(__b, (unsigned char *)__c)), 9278 __b, __c); 9279} 9280 9281static void __ATTRS_o_ai 9282vec_stvlx(vector unsigned short __a, int __b, unsigned short *__c) 9283{ 9284 return vec_st(vec_perm(vec_lvrx(__b, __c), 9285 __a, 9286 vec_lvsr(__b, __c)), 9287 __b, __c); 9288} 9289 9290static void __ATTRS_o_ai 9291vec_stvlx(vector unsigned short __a, int __b, vector unsigned short *__c) 9292{ 9293 return vec_st(vec_perm(vec_lvrx(__b, __c), 9294 __a, 9295 vec_lvsr(__b, (unsigned char *)__c)), 9296 __b, __c); 9297} 9298 9299static void __ATTRS_o_ai 9300vec_stvlx(vector bool short __a, int __b, vector bool short *__c) 9301{ 9302 return vec_st(vec_perm(vec_lvrx(__b, __c), 9303 __a, 9304 vec_lvsr(__b, (unsigned char *)__c)), 9305 __b, __c); 9306} 9307 9308static void __ATTRS_o_ai 9309vec_stvlx(vector pixel __a, int __b, vector pixel *__c) 9310{ 9311 return vec_st(vec_perm(vec_lvrx(__b, __c), 9312 __a, 9313 vec_lvsr(__b, (unsigned char *)__c)), 9314 __b, __c); 9315} 9316 9317static void __ATTRS_o_ai 9318vec_stvlx(vector int __a, int __b, int *__c) 9319{ 9320 return vec_st(vec_perm(vec_lvrx(__b, __c), 9321 __a, 9322 vec_lvsr(__b, __c)), 9323 __b, __c); 9324} 9325 9326static void __ATTRS_o_ai 9327vec_stvlx(vector int __a, int __b, vector int *__c) 9328{ 9329 return vec_st(vec_perm(vec_lvrx(__b, __c), 9330 __a, 9331 vec_lvsr(__b, (unsigned char *)__c)), 9332 __b, __c); 9333} 9334 9335static void __ATTRS_o_ai 9336vec_stvlx(vector unsigned int __a, int __b, unsigned int *__c) 9337{ 9338 return vec_st(vec_perm(vec_lvrx(__b, __c), 9339 __a, 9340 vec_lvsr(__b, __c)), 9341 __b, __c); 9342} 9343 9344static void __ATTRS_o_ai 9345vec_stvlx(vector unsigned int __a, int __b, vector unsigned int *__c) 9346{ 9347 return vec_st(vec_perm(vec_lvrx(__b, __c), 9348 __a, 9349 vec_lvsr(__b, (unsigned char *)__c)), 9350 __b, __c); 9351} 9352 9353static void __ATTRS_o_ai 9354vec_stvlx(vector bool int __a, int __b, vector bool int *__c) 9355{ 9356 return vec_st(vec_perm(vec_lvrx(__b, __c), 9357 __a, 9358 vec_lvsr(__b, (unsigned char *)__c)), 9359 __b, __c); 9360} 9361 9362static void __ATTRS_o_ai 9363vec_stvlx(vector float __a, int __b, vector float *__c) 9364{ 9365 return vec_st(vec_perm(vec_lvrx(__b, __c), 9366 __a, 9367 vec_lvsr(__b, (unsigned char *)__c)), 9368 __b, __c); 9369} 9370 9371/* vec_stvlxl */ 9372 9373static void __ATTRS_o_ai 9374vec_stvlxl(vector signed char __a, int __b, signed char *__c) 9375{ 9376 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9377 __a, 9378 vec_lvsr(__b, __c)), 9379 __b, __c); 9380} 9381 9382static void __ATTRS_o_ai 9383vec_stvlxl(vector signed char __a, int __b, vector signed char *__c) 9384{ 9385 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9386 __a, 9387 vec_lvsr(__b, (unsigned char *)__c)), 9388 __b, __c); 9389} 9390 9391static void __ATTRS_o_ai 9392vec_stvlxl(vector unsigned char __a, int __b, unsigned char *__c) 9393{ 9394 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9395 __a, 9396 vec_lvsr(__b, __c)), 9397 __b, __c); 9398} 9399 9400static void __ATTRS_o_ai 9401vec_stvlxl(vector unsigned char __a, int __b, vector unsigned char *__c) 9402{ 9403 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9404 __a, 9405 vec_lvsr(__b, (unsigned char *)__c)), 9406 __b, __c); 9407} 9408 9409static void __ATTRS_o_ai 9410vec_stvlxl(vector bool char __a, int __b, vector bool char *__c) 9411{ 9412 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9413 __a, 9414 vec_lvsr(__b, (unsigned char *)__c)), 9415 __b, __c); 9416} 9417 9418static void __ATTRS_o_ai 9419vec_stvlxl(vector short __a, int __b, short *__c) 9420{ 9421 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9422 __a, 9423 vec_lvsr(__b, __c)), 9424 __b, __c); 9425} 9426 9427static void __ATTRS_o_ai 9428vec_stvlxl(vector short __a, int __b, vector short *__c) 9429{ 9430 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9431 __a, 9432 vec_lvsr(__b, (unsigned char *)__c)), 9433 __b, __c); 9434} 9435 9436static void __ATTRS_o_ai 9437vec_stvlxl(vector unsigned short __a, int __b, unsigned short *__c) 9438{ 9439 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9440 __a, 9441 vec_lvsr(__b, __c)), 9442 __b, __c); 9443} 9444 9445static void __ATTRS_o_ai 9446vec_stvlxl(vector unsigned short __a, int __b, vector unsigned short *__c) 9447{ 9448 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9449 __a, 9450 vec_lvsr(__b, (unsigned char *)__c)), 9451 __b, __c); 9452} 9453 9454static void __ATTRS_o_ai 9455vec_stvlxl(vector bool short __a, int __b, vector bool short *__c) 9456{ 9457 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9458 __a, 9459 vec_lvsr(__b, (unsigned char *)__c)), 9460 __b, __c); 9461} 9462 9463static void __ATTRS_o_ai 9464vec_stvlxl(vector pixel __a, int __b, vector pixel *__c) 9465{ 9466 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9467 __a, 9468 vec_lvsr(__b, (unsigned char *)__c)), 9469 __b, __c); 9470} 9471 9472static void __ATTRS_o_ai 9473vec_stvlxl(vector int __a, int __b, int *__c) 9474{ 9475 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9476 __a, 9477 vec_lvsr(__b, __c)), 9478 __b, __c); 9479} 9480 9481static void __ATTRS_o_ai 9482vec_stvlxl(vector int __a, int __b, vector int *__c) 9483{ 9484 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9485 __a, 9486 vec_lvsr(__b, (unsigned char *)__c)), 9487 __b, __c); 9488} 9489 9490static void __ATTRS_o_ai 9491vec_stvlxl(vector unsigned int __a, int __b, unsigned int *__c) 9492{ 9493 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9494 __a, 9495 vec_lvsr(__b, __c)), 9496 __b, __c); 9497} 9498 9499static void __ATTRS_o_ai 9500vec_stvlxl(vector unsigned int __a, int __b, vector unsigned int *__c) 9501{ 9502 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9503 __a, 9504 vec_lvsr(__b, (unsigned char *)__c)), 9505 __b, __c); 9506} 9507 9508static void __ATTRS_o_ai 9509vec_stvlxl(vector bool int __a, int __b, vector bool int *__c) 9510{ 9511 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9512 __a, 9513 vec_lvsr(__b, (unsigned char *)__c)), 9514 __b, __c); 9515} 9516 9517static void __ATTRS_o_ai 9518vec_stvlxl(vector float __a, int __b, vector float *__c) 9519{ 9520 return vec_stl(vec_perm(vec_lvrx(__b, __c), 9521 __a, 9522 vec_lvsr(__b, (unsigned char *)__c)), 9523 __b, __c); 9524} 9525 9526/* vec_stvrx */ 9527 9528static void __ATTRS_o_ai 9529vec_stvrx(vector signed char __a, int __b, signed char *__c) 9530{ 9531 return vec_st(vec_perm(__a, 9532 vec_lvlx(__b, __c), 9533 vec_lvsr(__b, __c)), 9534 __b, __c); 9535} 9536 9537static void __ATTRS_o_ai 9538vec_stvrx(vector signed char __a, int __b, vector signed char *__c) 9539{ 9540 return vec_st(vec_perm(__a, 9541 vec_lvlx(__b, __c), 9542 vec_lvsr(__b, (unsigned char *)__c)), 9543 __b, __c); 9544} 9545 9546static void __ATTRS_o_ai 9547vec_stvrx(vector unsigned char __a, int __b, unsigned char *__c) 9548{ 9549 return vec_st(vec_perm(__a, 9550 vec_lvlx(__b, __c), 9551 vec_lvsr(__b, __c)), 9552 __b, __c); 9553} 9554 9555static void __ATTRS_o_ai 9556vec_stvrx(vector unsigned char __a, int __b, vector unsigned char *__c) 9557{ 9558 return vec_st(vec_perm(__a, 9559 vec_lvlx(__b, __c), 9560 vec_lvsr(__b, (unsigned char *)__c)), 9561 __b, __c); 9562} 9563 9564static void __ATTRS_o_ai 9565vec_stvrx(vector bool char __a, int __b, vector bool char *__c) 9566{ 9567 return vec_st(vec_perm(__a, 9568 vec_lvlx(__b, __c), 9569 vec_lvsr(__b, (unsigned char *)__c)), 9570 __b, __c); 9571} 9572 9573static void __ATTRS_o_ai 9574vec_stvrx(vector short __a, int __b, short *__c) 9575{ 9576 return vec_st(vec_perm(__a, 9577 vec_lvlx(__b, __c), 9578 vec_lvsr(__b, __c)), 9579 __b, __c); 9580} 9581 9582static void __ATTRS_o_ai 9583vec_stvrx(vector short __a, int __b, vector short *__c) 9584{ 9585 return vec_st(vec_perm(__a, 9586 vec_lvlx(__b, __c), 9587 vec_lvsr(__b, (unsigned char *)__c)), 9588 __b, __c); 9589} 9590 9591static void __ATTRS_o_ai 9592vec_stvrx(vector unsigned short __a, int __b, unsigned short *__c) 9593{ 9594 return vec_st(vec_perm(__a, 9595 vec_lvlx(__b, __c), 9596 vec_lvsr(__b, __c)), 9597 __b, __c); 9598} 9599 9600static void __ATTRS_o_ai 9601vec_stvrx(vector unsigned short __a, int __b, vector unsigned short *__c) 9602{ 9603 return vec_st(vec_perm(__a, 9604 vec_lvlx(__b, __c), 9605 vec_lvsr(__b, (unsigned char *)__c)), 9606 __b, __c); 9607} 9608 9609static void __ATTRS_o_ai 9610vec_stvrx(vector bool short __a, int __b, vector bool short *__c) 9611{ 9612 return vec_st(vec_perm(__a, 9613 vec_lvlx(__b, __c), 9614 vec_lvsr(__b, (unsigned char *)__c)), 9615 __b, __c); 9616} 9617 9618static void __ATTRS_o_ai 9619vec_stvrx(vector pixel __a, int __b, vector pixel *__c) 9620{ 9621 return vec_st(vec_perm(__a, 9622 vec_lvlx(__b, __c), 9623 vec_lvsr(__b, (unsigned char *)__c)), 9624 __b, __c); 9625} 9626 9627static void __ATTRS_o_ai 9628vec_stvrx(vector int __a, int __b, int *__c) 9629{ 9630 return vec_st(vec_perm(__a, 9631 vec_lvlx(__b, __c), 9632 vec_lvsr(__b, __c)), 9633 __b, __c); 9634} 9635 9636static void __ATTRS_o_ai 9637vec_stvrx(vector int __a, int __b, vector int *__c) 9638{ 9639 return vec_st(vec_perm(__a, 9640 vec_lvlx(__b, __c), 9641 vec_lvsr(__b, (unsigned char *)__c)), 9642 __b, __c); 9643} 9644 9645static void __ATTRS_o_ai 9646vec_stvrx(vector unsigned int __a, int __b, unsigned int *__c) 9647{ 9648 return vec_st(vec_perm(__a, 9649 vec_lvlx(__b, __c), 9650 vec_lvsr(__b, __c)), 9651 __b, __c); 9652} 9653 9654static void __ATTRS_o_ai 9655vec_stvrx(vector unsigned int __a, int __b, vector unsigned int *__c) 9656{ 9657 return vec_st(vec_perm(__a, 9658 vec_lvlx(__b, __c), 9659 vec_lvsr(__b, (unsigned char *)__c)), 9660 __b, __c); 9661} 9662 9663static void __ATTRS_o_ai 9664vec_stvrx(vector bool int __a, int __b, vector bool int *__c) 9665{ 9666 return vec_st(vec_perm(__a, 9667 vec_lvlx(__b, __c), 9668 vec_lvsr(__b, (unsigned char *)__c)), 9669 __b, __c); 9670} 9671 9672static void __ATTRS_o_ai 9673vec_stvrx(vector float __a, int __b, vector float *__c) 9674{ 9675 return vec_st(vec_perm(__a, 9676 vec_lvlx(__b, __c), 9677 vec_lvsr(__b, (unsigned char *)__c)), 9678 __b, __c); 9679} 9680 9681/* vec_stvrxl */ 9682 9683static void __ATTRS_o_ai 9684vec_stvrxl(vector signed char __a, int __b, signed char *__c) 9685{ 9686 return vec_stl(vec_perm(__a, 9687 vec_lvlx(__b, __c), 9688 vec_lvsr(__b, __c)), 9689 __b, __c); 9690} 9691 9692static void __ATTRS_o_ai 9693vec_stvrxl(vector signed char __a, int __b, vector signed char *__c) 9694{ 9695 return vec_stl(vec_perm(__a, 9696 vec_lvlx(__b, __c), 9697 vec_lvsr(__b, (unsigned char *)__c)), 9698 __b, __c); 9699} 9700 9701static void __ATTRS_o_ai 9702vec_stvrxl(vector unsigned char __a, int __b, unsigned char *__c) 9703{ 9704 return vec_stl(vec_perm(__a, 9705 vec_lvlx(__b, __c), 9706 vec_lvsr(__b, __c)), 9707 __b, __c); 9708} 9709 9710static void __ATTRS_o_ai 9711vec_stvrxl(vector unsigned char __a, int __b, vector unsigned char *__c) 9712{ 9713 return vec_stl(vec_perm(__a, 9714 vec_lvlx(__b, __c), 9715 vec_lvsr(__b, (unsigned char *)__c)), 9716 __b, __c); 9717} 9718 9719static void __ATTRS_o_ai 9720vec_stvrxl(vector bool char __a, int __b, vector bool char *__c) 9721{ 9722 return vec_stl(vec_perm(__a, 9723 vec_lvlx(__b, __c), 9724 vec_lvsr(__b, (unsigned char *)__c)), 9725 __b, __c); 9726} 9727 9728static void __ATTRS_o_ai 9729vec_stvrxl(vector short __a, int __b, short *__c) 9730{ 9731 return vec_stl(vec_perm(__a, 9732 vec_lvlx(__b, __c), 9733 vec_lvsr(__b, __c)), 9734 __b, __c); 9735} 9736 9737static void __ATTRS_o_ai 9738vec_stvrxl(vector short __a, int __b, vector short *__c) 9739{ 9740 return vec_stl(vec_perm(__a, 9741 vec_lvlx(__b, __c), 9742 vec_lvsr(__b, (unsigned char *)__c)), 9743 __b, __c); 9744} 9745 9746static void __ATTRS_o_ai 9747vec_stvrxl(vector unsigned short __a, int __b, unsigned short *__c) 9748{ 9749 return vec_stl(vec_perm(__a, 9750 vec_lvlx(__b, __c), 9751 vec_lvsr(__b, __c)), 9752 __b, __c); 9753} 9754 9755static void __ATTRS_o_ai 9756vec_stvrxl(vector unsigned short __a, int __b, vector unsigned short *__c) 9757{ 9758 return vec_stl(vec_perm(__a, 9759 vec_lvlx(__b, __c), 9760 vec_lvsr(__b, (unsigned char *)__c)), 9761 __b, __c); 9762} 9763 9764static void __ATTRS_o_ai 9765vec_stvrxl(vector bool short __a, int __b, vector bool short *__c) 9766{ 9767 return vec_stl(vec_perm(__a, 9768 vec_lvlx(__b, __c), 9769 vec_lvsr(__b, (unsigned char *)__c)), 9770 __b, __c); 9771} 9772 9773static void __ATTRS_o_ai 9774vec_stvrxl(vector pixel __a, int __b, vector pixel *__c) 9775{ 9776 return vec_stl(vec_perm(__a, 9777 vec_lvlx(__b, __c), 9778 vec_lvsr(__b, (unsigned char *)__c)), 9779 __b, __c); 9780} 9781 9782static void __ATTRS_o_ai 9783vec_stvrxl(vector int __a, int __b, int *__c) 9784{ 9785 return vec_stl(vec_perm(__a, 9786 vec_lvlx(__b, __c), 9787 vec_lvsr(__b, __c)), 9788 __b, __c); 9789} 9790 9791static void __ATTRS_o_ai 9792vec_stvrxl(vector int __a, int __b, vector int *__c) 9793{ 9794 return vec_stl(vec_perm(__a, 9795 vec_lvlx(__b, __c), 9796 vec_lvsr(__b, (unsigned char *)__c)), 9797 __b, __c); 9798} 9799 9800static void __ATTRS_o_ai 9801vec_stvrxl(vector unsigned int __a, int __b, unsigned int *__c) 9802{ 9803 return vec_stl(vec_perm(__a, 9804 vec_lvlx(__b, __c), 9805 vec_lvsr(__b, __c)), 9806 __b, __c); 9807} 9808 9809static void __ATTRS_o_ai 9810vec_stvrxl(vector unsigned int __a, int __b, vector unsigned int *__c) 9811{ 9812 return vec_stl(vec_perm(__a, 9813 vec_lvlx(__b, __c), 9814 vec_lvsr(__b, (unsigned char *)__c)), 9815 __b, __c); 9816} 9817 9818static void __ATTRS_o_ai 9819vec_stvrxl(vector bool int __a, int __b, vector bool int *__c) 9820{ 9821 return vec_stl(vec_perm(__a, 9822 vec_lvlx(__b, __c), 9823 vec_lvsr(__b, (unsigned char *)__c)), 9824 __b, __c); 9825} 9826 9827static void __ATTRS_o_ai 9828vec_stvrxl(vector float __a, int __b, vector float *__c) 9829{ 9830 return vec_stl(vec_perm(__a, 9831 vec_lvlx(__b, __c), 9832 vec_lvsr(__b, (unsigned char *)__c)), 9833 __b, __c); 9834} 9835 9836/* vec_promote */ 9837 9838static vector signed char __ATTRS_o_ai 9839vec_promote(signed char __a, int __b) 9840{ 9841 vector signed char __res = (vector signed char)(0); 9842 __res[__b] = __a; 9843 return __res; 9844} 9845 9846static vector unsigned char __ATTRS_o_ai 9847vec_promote(unsigned char __a, int __b) 9848{ 9849 vector unsigned char __res = (vector unsigned char)(0); 9850 __res[__b] = __a; 9851 return __res; 9852} 9853 9854static vector short __ATTRS_o_ai 9855vec_promote(short __a, int __b) 9856{ 9857 vector short __res = (vector short)(0); 9858 __res[__b] = __a; 9859 return __res; 9860} 9861 9862static vector unsigned short __ATTRS_o_ai 9863vec_promote(unsigned short __a, int __b) 9864{ 9865 vector unsigned short __res = (vector unsigned short)(0); 9866 __res[__b] = __a; 9867 return __res; 9868} 9869 9870static vector int __ATTRS_o_ai 9871vec_promote(int __a, int __b) 9872{ 9873 vector int __res = (vector int)(0); 9874 __res[__b] = __a; 9875 return __res; 9876} 9877 9878static vector unsigned int __ATTRS_o_ai 9879vec_promote(unsigned int __a, int __b) 9880{ 9881 vector unsigned int __res = (vector unsigned int)(0); 9882 __res[__b] = __a; 9883 return __res; 9884} 9885 9886static vector float __ATTRS_o_ai 9887vec_promote(float __a, int __b) 9888{ 9889 vector float __res = (vector float)(0); 9890 __res[__b] = __a; 9891 return __res; 9892} 9893 9894/* vec_splats */ 9895 9896static vector signed char __ATTRS_o_ai 9897vec_splats(signed char __a) 9898{ 9899 return (vector signed char)(__a); 9900} 9901 9902static vector unsigned char __ATTRS_o_ai 9903vec_splats(unsigned char __a) 9904{ 9905 return (vector unsigned char)(__a); 9906} 9907 9908static vector short __ATTRS_o_ai 9909vec_splats(short __a) 9910{ 9911 return (vector short)(__a); 9912} 9913 9914static vector unsigned short __ATTRS_o_ai 9915vec_splats(unsigned short __a) 9916{ 9917 return (vector unsigned short)(__a); 9918} 9919 9920static vector int __ATTRS_o_ai 9921vec_splats(int __a) 9922{ 9923 return (vector int)(__a); 9924} 9925 9926static vector unsigned int __ATTRS_o_ai 9927vec_splats(unsigned int __a) 9928{ 9929 return (vector unsigned int)(__a); 9930} 9931 9932static vector float __ATTRS_o_ai 9933vec_splats(float __a) 9934{ 9935 return (vector float)(__a); 9936} 9937 9938/* ----------------------------- predicates --------------------------------- */ 9939 9940/* vec_all_eq */ 9941 9942static int __ATTRS_o_ai 9943vec_all_eq(vector signed char __a, vector signed char __b) 9944{ 9945 return __builtin_altivec_vcmpequb_p(__CR6_LT, (vector char)__a, (vector char)__b); 9946} 9947 9948static int __ATTRS_o_ai 9949vec_all_eq(vector signed char __a, vector bool char __b) 9950{ 9951 return __builtin_altivec_vcmpequb_p(__CR6_LT, (vector char)__a, (vector char)__b); 9952} 9953 9954static int __ATTRS_o_ai 9955vec_all_eq(vector unsigned char __a, vector unsigned char __b) 9956{ 9957 return __builtin_altivec_vcmpequb_p(__CR6_LT, (vector char)__a, (vector char)__b); 9958} 9959 9960static int __ATTRS_o_ai 9961vec_all_eq(vector unsigned char __a, vector bool char __b) 9962{ 9963 return __builtin_altivec_vcmpequb_p(__CR6_LT, (vector char)__a, (vector char)__b); 9964} 9965 9966static int __ATTRS_o_ai 9967vec_all_eq(vector bool char __a, vector signed char __b) 9968{ 9969 return __builtin_altivec_vcmpequb_p(__CR6_LT, (vector char)__a, (vector char)__b); 9970} 9971 9972static int __ATTRS_o_ai 9973vec_all_eq(vector bool char __a, vector unsigned char __b) 9974{ 9975 return __builtin_altivec_vcmpequb_p(__CR6_LT, (vector char)__a, (vector char)__b); 9976} 9977 9978static int __ATTRS_o_ai 9979vec_all_eq(vector bool char __a, vector bool char __b) 9980{ 9981 return __builtin_altivec_vcmpequb_p(__CR6_LT, (vector char)__a, (vector char)__b); 9982} 9983 9984static int __ATTRS_o_ai 9985vec_all_eq(vector short __a, vector short __b) 9986{ 9987 return __builtin_altivec_vcmpequh_p(__CR6_LT, __a, __b); 9988} 9989 9990static int __ATTRS_o_ai 9991vec_all_eq(vector short __a, vector bool short __b) 9992{ 9993 return __builtin_altivec_vcmpequh_p(__CR6_LT, __a, (vector short)__b); 9994} 9995 9996static int __ATTRS_o_ai 9997vec_all_eq(vector unsigned short __a, vector unsigned short __b) 9998{ 9999 return 10000 __builtin_altivec_vcmpequh_p(__CR6_LT, (vector short)__a, (vector short)__b); 10001} 10002 10003static int __ATTRS_o_ai 10004vec_all_eq(vector unsigned short __a, vector bool short __b) 10005{ 10006 return 10007 __builtin_altivec_vcmpequh_p(__CR6_LT, (vector short)__a, (vector short)__b); 10008} 10009 10010static int __ATTRS_o_ai 10011vec_all_eq(vector bool short __a, vector short __b) 10012{ 10013 return 10014 __builtin_altivec_vcmpequh_p(__CR6_LT, (vector short)__a, (vector short)__b); 10015} 10016 10017static int __ATTRS_o_ai 10018vec_all_eq(vector bool short __a, vector unsigned short __b) 10019{ 10020 return 10021 __builtin_altivec_vcmpequh_p(__CR6_LT, (vector short)__a, (vector short)__b); 10022} 10023 10024static int __ATTRS_o_ai 10025vec_all_eq(vector bool short __a, vector bool short __b) 10026{ 10027 return 10028 __builtin_altivec_vcmpequh_p(__CR6_LT, (vector short)__a, (vector short)__b); 10029} 10030 10031static int __ATTRS_o_ai 10032vec_all_eq(vector pixel __a, vector pixel __b) 10033{ 10034 return 10035 __builtin_altivec_vcmpequh_p(__CR6_LT, (vector short)__a, (vector short)__b); 10036} 10037 10038static int __ATTRS_o_ai 10039vec_all_eq(vector int __a, vector int __b) 10040{ 10041 return __builtin_altivec_vcmpequw_p(__CR6_LT, __a, __b); 10042} 10043 10044static int __ATTRS_o_ai 10045vec_all_eq(vector int __a, vector bool int __b) 10046{ 10047 return __builtin_altivec_vcmpequw_p(__CR6_LT, __a, (vector int)__b); 10048} 10049 10050static int __ATTRS_o_ai 10051vec_all_eq(vector unsigned int __a, vector unsigned int __b) 10052{ 10053 return __builtin_altivec_vcmpequw_p(__CR6_LT, (vector int)__a, (vector int)__b); 10054} 10055 10056static int __ATTRS_o_ai 10057vec_all_eq(vector unsigned int __a, vector bool int __b) 10058{ 10059 return __builtin_altivec_vcmpequw_p(__CR6_LT, (vector int)__a, (vector int)__b); 10060} 10061 10062static int __ATTRS_o_ai 10063vec_all_eq(vector bool int __a, vector int __b) 10064{ 10065 return __builtin_altivec_vcmpequw_p(__CR6_LT, (vector int)__a, (vector int)__b); 10066} 10067 10068static int __ATTRS_o_ai 10069vec_all_eq(vector bool int __a, vector unsigned int __b) 10070{ 10071 return __builtin_altivec_vcmpequw_p(__CR6_LT, (vector int)__a, (vector int)__b); 10072} 10073 10074static int __ATTRS_o_ai 10075vec_all_eq(vector bool int __a, vector bool int __b) 10076{ 10077 return __builtin_altivec_vcmpequw_p(__CR6_LT, (vector int)__a, (vector int)__b); 10078} 10079 10080static int __ATTRS_o_ai 10081vec_all_eq(vector float __a, vector float __b) 10082{ 10083 return __builtin_altivec_vcmpeqfp_p(__CR6_LT, __a, __b); 10084} 10085 10086/* vec_all_ge */ 10087 10088static int __ATTRS_o_ai 10089vec_all_ge(vector signed char __a, vector signed char __b) 10090{ 10091 return __builtin_altivec_vcmpgtsb_p(__CR6_EQ, __b, __a); 10092} 10093 10094static int __ATTRS_o_ai 10095vec_all_ge(vector signed char __a, vector bool char __b) 10096{ 10097 return __builtin_altivec_vcmpgtsb_p(__CR6_EQ, (vector signed char)__b, __a); 10098} 10099 10100static int __ATTRS_o_ai 10101vec_all_ge(vector unsigned char __a, vector unsigned char __b) 10102{ 10103 return __builtin_altivec_vcmpgtub_p(__CR6_EQ, __b, __a); 10104} 10105 10106static int __ATTRS_o_ai 10107vec_all_ge(vector unsigned char __a, vector bool char __b) 10108{ 10109 return __builtin_altivec_vcmpgtub_p(__CR6_EQ, (vector unsigned char)__b, __a); 10110} 10111 10112static int __ATTRS_o_ai 10113vec_all_ge(vector bool char __a, vector signed char __b) 10114{ 10115 return __builtin_altivec_vcmpgtub_p(__CR6_EQ, 10116 (vector unsigned char)__b, 10117 (vector unsigned char)__a); 10118} 10119 10120static int __ATTRS_o_ai 10121vec_all_ge(vector bool char __a, vector unsigned char __b) 10122{ 10123 return __builtin_altivec_vcmpgtub_p(__CR6_EQ, __b, (vector unsigned char)__a); 10124} 10125 10126static int __ATTRS_o_ai 10127vec_all_ge(vector bool char __a, vector bool char __b) 10128{ 10129 return __builtin_altivec_vcmpgtub_p(__CR6_EQ, 10130 (vector unsigned char)__b, 10131 (vector unsigned char)__a); 10132} 10133 10134static int __ATTRS_o_ai 10135vec_all_ge(vector short __a, vector short __b) 10136{ 10137 return __builtin_altivec_vcmpgtsh_p(__CR6_EQ, __b, __a); 10138} 10139 10140static int __ATTRS_o_ai 10141vec_all_ge(vector short __a, vector bool short __b) 10142{ 10143 return __builtin_altivec_vcmpgtsh_p(__CR6_EQ, (vector short)__b, __a); 10144} 10145 10146static int __ATTRS_o_ai 10147vec_all_ge(vector unsigned short __a, vector unsigned short __b) 10148{ 10149 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ, __b, __a); 10150} 10151 10152static int __ATTRS_o_ai 10153vec_all_ge(vector unsigned short __a, vector bool short __b) 10154{ 10155 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ, (vector unsigned short)__b, __a); 10156} 10157 10158static int __ATTRS_o_ai 10159vec_all_ge(vector bool short __a, vector short __b) 10160{ 10161 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ, 10162 (vector unsigned short)__b, 10163 (vector unsigned short)__a); 10164} 10165 10166static int __ATTRS_o_ai 10167vec_all_ge(vector bool short __a, vector unsigned short __b) 10168{ 10169 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ, __b, (vector unsigned short)__a); 10170} 10171 10172static int __ATTRS_o_ai 10173vec_all_ge(vector bool short __a, vector bool short __b) 10174{ 10175 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ, 10176 (vector unsigned short)__b, 10177 (vector unsigned short)__a); 10178} 10179 10180static int __ATTRS_o_ai 10181vec_all_ge(vector int __a, vector int __b) 10182{ 10183 return __builtin_altivec_vcmpgtsw_p(__CR6_EQ, __b, __a); 10184} 10185 10186static int __ATTRS_o_ai 10187vec_all_ge(vector int __a, vector bool int __b) 10188{ 10189 return __builtin_altivec_vcmpgtsw_p(__CR6_EQ, (vector int)__b, __a); 10190} 10191 10192static int __ATTRS_o_ai 10193vec_all_ge(vector unsigned int __a, vector unsigned int __b) 10194{ 10195 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ, __b, __a); 10196} 10197 10198static int __ATTRS_o_ai 10199vec_all_ge(vector unsigned int __a, vector bool int __b) 10200{ 10201 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ, (vector unsigned int)__b, __a); 10202} 10203 10204static int __ATTRS_o_ai 10205vec_all_ge(vector bool int __a, vector int __b) 10206{ 10207 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ, 10208 (vector unsigned int)__b, 10209 (vector unsigned int)__a); 10210} 10211 10212static int __ATTRS_o_ai 10213vec_all_ge(vector bool int __a, vector unsigned int __b) 10214{ 10215 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ, __b, (vector unsigned int)__a); 10216} 10217 10218static int __ATTRS_o_ai 10219vec_all_ge(vector bool int __a, vector bool int __b) 10220{ 10221 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ, 10222 (vector unsigned int)__b, 10223 (vector unsigned int)__a); 10224} 10225 10226static int __ATTRS_o_ai 10227vec_all_ge(vector float __a, vector float __b) 10228{ 10229 return __builtin_altivec_vcmpgefp_p(__CR6_LT, __a, __b); 10230} 10231 10232/* vec_all_gt */ 10233 10234static int __ATTRS_o_ai 10235vec_all_gt(vector signed char __a, vector signed char __b) 10236{ 10237 return __builtin_altivec_vcmpgtsb_p(__CR6_LT, __a, __b); 10238} 10239 10240static int __ATTRS_o_ai 10241vec_all_gt(vector signed char __a, vector bool char __b) 10242{ 10243 return __builtin_altivec_vcmpgtsb_p(__CR6_LT, __a, (vector signed char)__b); 10244} 10245 10246static int __ATTRS_o_ai 10247vec_all_gt(vector unsigned char __a, vector unsigned char __b) 10248{ 10249 return __builtin_altivec_vcmpgtub_p(__CR6_LT, __a, __b); 10250} 10251 10252static int __ATTRS_o_ai 10253vec_all_gt(vector unsigned char __a, vector bool char __b) 10254{ 10255 return __builtin_altivec_vcmpgtub_p(__CR6_LT, __a, (vector unsigned char)__b); 10256} 10257 10258static int __ATTRS_o_ai 10259vec_all_gt(vector bool char __a, vector signed char __b) 10260{ 10261 return __builtin_altivec_vcmpgtub_p(__CR6_LT, 10262 (vector unsigned char)__a, 10263 (vector unsigned char)__b); 10264} 10265 10266static int __ATTRS_o_ai 10267vec_all_gt(vector bool char __a, vector unsigned char __b) 10268{ 10269 return __builtin_altivec_vcmpgtub_p(__CR6_LT, (vector unsigned char)__a, __b); 10270} 10271 10272static int __ATTRS_o_ai 10273vec_all_gt(vector bool char __a, vector bool char __b) 10274{ 10275 return __builtin_altivec_vcmpgtub_p(__CR6_LT, 10276 (vector unsigned char)__a, 10277 (vector unsigned char)__b); 10278} 10279 10280static int __ATTRS_o_ai 10281vec_all_gt(vector short __a, vector short __b) 10282{ 10283 return __builtin_altivec_vcmpgtsh_p(__CR6_LT, __a, __b); 10284} 10285 10286static int __ATTRS_o_ai 10287vec_all_gt(vector short __a, vector bool short __b) 10288{ 10289 return __builtin_altivec_vcmpgtsh_p(__CR6_LT, __a, (vector short)__b); 10290} 10291 10292static int __ATTRS_o_ai 10293vec_all_gt(vector unsigned short __a, vector unsigned short __b) 10294{ 10295 return __builtin_altivec_vcmpgtuh_p(__CR6_LT, __a, __b); 10296} 10297 10298static int __ATTRS_o_ai 10299vec_all_gt(vector unsigned short __a, vector bool short __b) 10300{ 10301 return __builtin_altivec_vcmpgtuh_p(__CR6_LT, __a, (vector unsigned short)__b); 10302} 10303 10304static int __ATTRS_o_ai 10305vec_all_gt(vector bool short __a, vector short __b) 10306{ 10307 return __builtin_altivec_vcmpgtuh_p(__CR6_LT, 10308 (vector unsigned short)__a, 10309 (vector unsigned short)__b); 10310} 10311 10312static int __ATTRS_o_ai 10313vec_all_gt(vector bool short __a, vector unsigned short __b) 10314{ 10315 return __builtin_altivec_vcmpgtuh_p(__CR6_LT, (vector unsigned short)__a, __b); 10316} 10317 10318static int __ATTRS_o_ai 10319vec_all_gt(vector bool short __a, vector bool short __b) 10320{ 10321 return __builtin_altivec_vcmpgtuh_p(__CR6_LT, 10322 (vector unsigned short)__a, 10323 (vector unsigned short)__b); 10324} 10325 10326static int __ATTRS_o_ai 10327vec_all_gt(vector int __a, vector int __b) 10328{ 10329 return __builtin_altivec_vcmpgtsw_p(__CR6_LT, __a, __b); 10330} 10331 10332static int __ATTRS_o_ai 10333vec_all_gt(vector int __a, vector bool int __b) 10334{ 10335 return __builtin_altivec_vcmpgtsw_p(__CR6_LT, __a, (vector int)__b); 10336} 10337 10338static int __ATTRS_o_ai 10339vec_all_gt(vector unsigned int __a, vector unsigned int __b) 10340{ 10341 return __builtin_altivec_vcmpgtuw_p(__CR6_LT, __a, __b); 10342} 10343 10344static int __ATTRS_o_ai 10345vec_all_gt(vector unsigned int __a, vector bool int __b) 10346{ 10347 return __builtin_altivec_vcmpgtuw_p(__CR6_LT, __a, (vector unsigned int)__b); 10348} 10349 10350static int __ATTRS_o_ai 10351vec_all_gt(vector bool int __a, vector int __b) 10352{ 10353 return __builtin_altivec_vcmpgtuw_p(__CR6_LT, 10354 (vector unsigned int)__a, 10355 (vector unsigned int)__b); 10356} 10357 10358static int __ATTRS_o_ai 10359vec_all_gt(vector bool int __a, vector unsigned int __b) 10360{ 10361 return __builtin_altivec_vcmpgtuw_p(__CR6_LT, (vector unsigned int)__a, __b); 10362} 10363 10364static int __ATTRS_o_ai 10365vec_all_gt(vector bool int __a, vector bool int __b) 10366{ 10367 return __builtin_altivec_vcmpgtuw_p(__CR6_LT, 10368 (vector unsigned int)__a, 10369 (vector unsigned int)__b); 10370} 10371 10372static int __ATTRS_o_ai 10373vec_all_gt(vector float __a, vector float __b) 10374{ 10375 return __builtin_altivec_vcmpgtfp_p(__CR6_LT, __a, __b); 10376} 10377 10378/* vec_all_in */ 10379 10380static int __attribute__((__always_inline__)) 10381vec_all_in(vector float __a, vector float __b) 10382{ 10383 return __builtin_altivec_vcmpbfp_p(__CR6_EQ, __a, __b); 10384} 10385 10386/* vec_all_le */ 10387 10388static int __ATTRS_o_ai 10389vec_all_le(vector signed char __a, vector signed char __b) 10390{ 10391 return __builtin_altivec_vcmpgtsb_p(__CR6_EQ, __a, __b); 10392} 10393 10394static int __ATTRS_o_ai 10395vec_all_le(vector signed char __a, vector bool char __b) 10396{ 10397 return __builtin_altivec_vcmpgtsb_p(__CR6_EQ, __a, (vector signed char)__b); 10398} 10399 10400static int __ATTRS_o_ai 10401vec_all_le(vector unsigned char __a, vector unsigned char __b) 10402{ 10403 return __builtin_altivec_vcmpgtub_p(__CR6_EQ, __a, __b); 10404} 10405 10406static int __ATTRS_o_ai 10407vec_all_le(vector unsigned char __a, vector bool char __b) 10408{ 10409 return __builtin_altivec_vcmpgtub_p(__CR6_EQ, __a, (vector unsigned char)__b); 10410} 10411 10412static int __ATTRS_o_ai 10413vec_all_le(vector bool char __a, vector signed char __b) 10414{ 10415 return __builtin_altivec_vcmpgtub_p(__CR6_EQ, 10416 (vector unsigned char)__a, 10417 (vector unsigned char)__b); 10418} 10419 10420static int __ATTRS_o_ai 10421vec_all_le(vector bool char __a, vector unsigned char __b) 10422{ 10423 return __builtin_altivec_vcmpgtub_p(__CR6_EQ, (vector unsigned char)__a, __b); 10424} 10425 10426static int __ATTRS_o_ai 10427vec_all_le(vector bool char __a, vector bool char __b) 10428{ 10429 return __builtin_altivec_vcmpgtub_p(__CR6_EQ, 10430 (vector unsigned char)__a, 10431 (vector unsigned char)__b); 10432} 10433 10434static int __ATTRS_o_ai 10435vec_all_le(vector short __a, vector short __b) 10436{ 10437 return __builtin_altivec_vcmpgtsh_p(__CR6_EQ, __a, __b); 10438} 10439 10440static int __ATTRS_o_ai 10441vec_all_le(vector short __a, vector bool short __b) 10442{ 10443 return __builtin_altivec_vcmpgtsh_p(__CR6_EQ, __a, (vector short)__b); 10444} 10445 10446static int __ATTRS_o_ai 10447vec_all_le(vector unsigned short __a, vector unsigned short __b) 10448{ 10449 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ, __a, __b); 10450} 10451 10452static int __ATTRS_o_ai 10453vec_all_le(vector unsigned short __a, vector bool short __b) 10454{ 10455 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ, __a, (vector unsigned short)__b); 10456} 10457 10458static int __ATTRS_o_ai 10459vec_all_le(vector bool short __a, vector short __b) 10460{ 10461 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ, 10462 (vector unsigned short)__a, 10463 (vector unsigned short)__b); 10464} 10465 10466static int __ATTRS_o_ai 10467vec_all_le(vector bool short __a, vector unsigned short __b) 10468{ 10469 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ, (vector unsigned short)__a, __b); 10470} 10471 10472static int __ATTRS_o_ai 10473vec_all_le(vector bool short __a, vector bool short __b) 10474{ 10475 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ, 10476 (vector unsigned short)__a, 10477 (vector unsigned short)__b); 10478} 10479 10480static int __ATTRS_o_ai 10481vec_all_le(vector int __a, vector int __b) 10482{ 10483 return __builtin_altivec_vcmpgtsw_p(__CR6_EQ, __a, __b); 10484} 10485 10486static int __ATTRS_o_ai 10487vec_all_le(vector int __a, vector bool int __b) 10488{ 10489 return __builtin_altivec_vcmpgtsw_p(__CR6_EQ, __a, (vector int)__b); 10490} 10491 10492static int __ATTRS_o_ai 10493vec_all_le(vector unsigned int __a, vector unsigned int __b) 10494{ 10495 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ, __a, __b); 10496} 10497 10498static int __ATTRS_o_ai 10499vec_all_le(vector unsigned int __a, vector bool int __b) 10500{ 10501 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ, __a, (vector unsigned int)__b); 10502} 10503 10504static int __ATTRS_o_ai 10505vec_all_le(vector bool int __a, vector int __b) 10506{ 10507 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ, 10508 (vector unsigned int)__a, 10509 (vector unsigned int)__b); 10510} 10511 10512static int __ATTRS_o_ai 10513vec_all_le(vector bool int __a, vector unsigned int __b) 10514{ 10515 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ, (vector unsigned int)__a, __b); 10516} 10517 10518static int __ATTRS_o_ai 10519vec_all_le(vector bool int __a, vector bool int __b) 10520{ 10521 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ, 10522 (vector unsigned int)__a, 10523 (vector unsigned int)__b); 10524} 10525 10526static int __ATTRS_o_ai 10527vec_all_le(vector float __a, vector float __b) 10528{ 10529 return __builtin_altivec_vcmpgefp_p(__CR6_LT, __b, __a); 10530} 10531 10532/* vec_all_lt */ 10533 10534static int __ATTRS_o_ai 10535vec_all_lt(vector signed char __a, vector signed char __b) 10536{ 10537 return __builtin_altivec_vcmpgtsb_p(__CR6_LT, __b, __a); 10538} 10539 10540static int __ATTRS_o_ai 10541vec_all_lt(vector signed char __a, vector bool char __b) 10542{ 10543 return __builtin_altivec_vcmpgtsb_p(__CR6_LT, (vector signed char)__b, __a); 10544} 10545 10546static int __ATTRS_o_ai 10547vec_all_lt(vector unsigned char __a, vector unsigned char __b) 10548{ 10549 return __builtin_altivec_vcmpgtub_p(__CR6_LT, __b, __a); 10550} 10551 10552static int __ATTRS_o_ai 10553vec_all_lt(vector unsigned char __a, vector bool char __b) 10554{ 10555 return __builtin_altivec_vcmpgtub_p(__CR6_LT, (vector unsigned char)__b, __a); 10556} 10557 10558static int __ATTRS_o_ai 10559vec_all_lt(vector bool char __a, vector signed char __b) 10560{ 10561 return __builtin_altivec_vcmpgtub_p(__CR6_LT, 10562 (vector unsigned char)__b, 10563 (vector unsigned char)__a); 10564} 10565 10566static int __ATTRS_o_ai 10567vec_all_lt(vector bool char __a, vector unsigned char __b) 10568{ 10569 return __builtin_altivec_vcmpgtub_p(__CR6_LT, __b, (vector unsigned char)__a); 10570} 10571 10572static int __ATTRS_o_ai 10573vec_all_lt(vector bool char __a, vector bool char __b) 10574{ 10575 return __builtin_altivec_vcmpgtub_p(__CR6_LT, 10576 (vector unsigned char)__b, 10577 (vector unsigned char)__a); 10578} 10579 10580static int __ATTRS_o_ai 10581vec_all_lt(vector short __a, vector short __b) 10582{ 10583 return __builtin_altivec_vcmpgtsh_p(__CR6_LT, __b, __a); 10584} 10585 10586static int __ATTRS_o_ai 10587vec_all_lt(vector short __a, vector bool short __b) 10588{ 10589 return __builtin_altivec_vcmpgtsh_p(__CR6_LT, (vector short)__b, __a); 10590} 10591 10592static int __ATTRS_o_ai 10593vec_all_lt(vector unsigned short __a, vector unsigned short __b) 10594{ 10595 return __builtin_altivec_vcmpgtuh_p(__CR6_LT, __b, __a); 10596} 10597 10598static int __ATTRS_o_ai 10599vec_all_lt(vector unsigned short __a, vector bool short __b) 10600{ 10601 return __builtin_altivec_vcmpgtuh_p(__CR6_LT, (vector unsigned short)__b, __a); 10602} 10603 10604static int __ATTRS_o_ai 10605vec_all_lt(vector bool short __a, vector short __b) 10606{ 10607 return __builtin_altivec_vcmpgtuh_p(__CR6_LT, 10608 (vector unsigned short)__b, 10609 (vector unsigned short)__a); 10610} 10611 10612static int __ATTRS_o_ai 10613vec_all_lt(vector bool short __a, vector unsigned short __b) 10614{ 10615 return __builtin_altivec_vcmpgtuh_p(__CR6_LT, __b, (vector unsigned short)__a); 10616} 10617 10618static int __ATTRS_o_ai 10619vec_all_lt(vector bool short __a, vector bool short __b) 10620{ 10621 return __builtin_altivec_vcmpgtuh_p(__CR6_LT, 10622 (vector unsigned short)__b, 10623 (vector unsigned short)__a); 10624} 10625 10626static int __ATTRS_o_ai 10627vec_all_lt(vector int __a, vector int __b) 10628{ 10629 return __builtin_altivec_vcmpgtsw_p(__CR6_LT, __b, __a); 10630} 10631 10632static int __ATTRS_o_ai 10633vec_all_lt(vector int __a, vector bool int __b) 10634{ 10635 return __builtin_altivec_vcmpgtsw_p(__CR6_LT, (vector int)__b, __a); 10636} 10637 10638static int __ATTRS_o_ai 10639vec_all_lt(vector unsigned int __a, vector unsigned int __b) 10640{ 10641 return __builtin_altivec_vcmpgtuw_p(__CR6_LT, __b, __a); 10642} 10643 10644static int __ATTRS_o_ai 10645vec_all_lt(vector unsigned int __a, vector bool int __b) 10646{ 10647 return __builtin_altivec_vcmpgtuw_p(__CR6_LT, (vector unsigned int)__b, __a); 10648} 10649 10650static int __ATTRS_o_ai 10651vec_all_lt(vector bool int __a, vector int __b) 10652{ 10653 return __builtin_altivec_vcmpgtuw_p(__CR6_LT, 10654 (vector unsigned int)__b, 10655 (vector unsigned int)__a); 10656} 10657 10658static int __ATTRS_o_ai 10659vec_all_lt(vector bool int __a, vector unsigned int __b) 10660{ 10661 return __builtin_altivec_vcmpgtuw_p(__CR6_LT, __b, (vector unsigned int)__a); 10662} 10663 10664static int __ATTRS_o_ai 10665vec_all_lt(vector bool int __a, vector bool int __b) 10666{ 10667 return __builtin_altivec_vcmpgtuw_p(__CR6_LT, 10668 (vector unsigned int)__b, 10669 (vector unsigned int)__a); 10670} 10671 10672static int __ATTRS_o_ai 10673vec_all_lt(vector float __a, vector float __b) 10674{ 10675 return __builtin_altivec_vcmpgtfp_p(__CR6_LT, __b, __a); 10676} 10677 10678/* vec_all_nan */ 10679 10680static int __attribute__((__always_inline__)) 10681vec_all_nan(vector float __a) 10682{ 10683 return __builtin_altivec_vcmpeqfp_p(__CR6_EQ, __a, __a); 10684} 10685 10686/* vec_all_ne */ 10687 10688static int __ATTRS_o_ai 10689vec_all_ne(vector signed char __a, vector signed char __b) 10690{ 10691 return __builtin_altivec_vcmpequb_p(__CR6_EQ, (vector char)__a, (vector char)__b); 10692} 10693 10694static int __ATTRS_o_ai 10695vec_all_ne(vector signed char __a, vector bool char __b) 10696{ 10697 return __builtin_altivec_vcmpequb_p(__CR6_EQ, (vector char)__a, (vector char)__b); 10698} 10699 10700static int __ATTRS_o_ai 10701vec_all_ne(vector unsigned char __a, vector unsigned char __b) 10702{ 10703 return __builtin_altivec_vcmpequb_p(__CR6_EQ, (vector char)__a, (vector char)__b); 10704} 10705 10706static int __ATTRS_o_ai 10707vec_all_ne(vector unsigned char __a, vector bool char __b) 10708{ 10709 return __builtin_altivec_vcmpequb_p(__CR6_EQ, (vector char)__a, (vector char)__b); 10710} 10711 10712static int __ATTRS_o_ai 10713vec_all_ne(vector bool char __a, vector signed char __b) 10714{ 10715 return __builtin_altivec_vcmpequb_p(__CR6_EQ, (vector char)__a, (vector char)__b); 10716} 10717 10718static int __ATTRS_o_ai 10719vec_all_ne(vector bool char __a, vector unsigned char __b) 10720{ 10721 return __builtin_altivec_vcmpequb_p(__CR6_EQ, (vector char)__a, (vector char)__b); 10722} 10723 10724static int __ATTRS_o_ai 10725vec_all_ne(vector bool char __a, vector bool char __b) 10726{ 10727 return __builtin_altivec_vcmpequb_p(__CR6_EQ, (vector char)__a, (vector char)__b); 10728} 10729 10730static int __ATTRS_o_ai 10731vec_all_ne(vector short __a, vector short __b) 10732{ 10733 return __builtin_altivec_vcmpequh_p(__CR6_EQ, __a, __b); 10734} 10735 10736static int __ATTRS_o_ai 10737vec_all_ne(vector short __a, vector bool short __b) 10738{ 10739 return __builtin_altivec_vcmpequh_p(__CR6_EQ, __a, (vector short)__b); 10740} 10741 10742static int __ATTRS_o_ai 10743vec_all_ne(vector unsigned short __a, vector unsigned short __b) 10744{ 10745 return 10746 __builtin_altivec_vcmpequh_p(__CR6_EQ, (vector short)__a, (vector short)__b); 10747} 10748 10749static int __ATTRS_o_ai 10750vec_all_ne(vector unsigned short __a, vector bool short __b) 10751{ 10752 return 10753 __builtin_altivec_vcmpequh_p(__CR6_EQ, (vector short)__a, (vector short)__b); 10754} 10755 10756static int __ATTRS_o_ai 10757vec_all_ne(vector bool short __a, vector short __b) 10758{ 10759 return 10760 __builtin_altivec_vcmpequh_p(__CR6_EQ, (vector short)__a, (vector short)__b); 10761} 10762 10763static int __ATTRS_o_ai 10764vec_all_ne(vector bool short __a, vector unsigned short __b) 10765{ 10766 return 10767 __builtin_altivec_vcmpequh_p(__CR6_EQ, (vector short)__a, (vector short)__b); 10768} 10769 10770static int __ATTRS_o_ai 10771vec_all_ne(vector bool short __a, vector bool short __b) 10772{ 10773 return 10774 __builtin_altivec_vcmpequh_p(__CR6_EQ, (vector short)__a, (vector short)__b); 10775} 10776 10777static int __ATTRS_o_ai 10778vec_all_ne(vector pixel __a, vector pixel __b) 10779{ 10780 return 10781 __builtin_altivec_vcmpequh_p(__CR6_EQ, (vector short)__a, (vector short)__b); 10782} 10783 10784static int __ATTRS_o_ai 10785vec_all_ne(vector int __a, vector int __b) 10786{ 10787 return __builtin_altivec_vcmpequw_p(__CR6_EQ, __a, __b); 10788} 10789 10790static int __ATTRS_o_ai 10791vec_all_ne(vector int __a, vector bool int __b) 10792{ 10793 return __builtin_altivec_vcmpequw_p(__CR6_EQ, __a, (vector int)__b); 10794} 10795 10796static int __ATTRS_o_ai 10797vec_all_ne(vector unsigned int __a, vector unsigned int __b) 10798{ 10799 return __builtin_altivec_vcmpequw_p(__CR6_EQ, (vector int)__a, (vector int)__b); 10800} 10801 10802static int __ATTRS_o_ai 10803vec_all_ne(vector unsigned int __a, vector bool int __b) 10804{ 10805 return __builtin_altivec_vcmpequw_p(__CR6_EQ, (vector int)__a, (vector int)__b); 10806} 10807 10808static int __ATTRS_o_ai 10809vec_all_ne(vector bool int __a, vector int __b) 10810{ 10811 return __builtin_altivec_vcmpequw_p(__CR6_EQ, (vector int)__a, (vector int)__b); 10812} 10813 10814static int __ATTRS_o_ai 10815vec_all_ne(vector bool int __a, vector unsigned int __b) 10816{ 10817 return __builtin_altivec_vcmpequw_p(__CR6_EQ, (vector int)__a, (vector int)__b); 10818} 10819 10820static int __ATTRS_o_ai 10821vec_all_ne(vector bool int __a, vector bool int __b) 10822{ 10823 return __builtin_altivec_vcmpequw_p(__CR6_EQ, (vector int)__a, (vector int)__b); 10824} 10825 10826static int __ATTRS_o_ai 10827vec_all_ne(vector float __a, vector float __b) 10828{ 10829 return __builtin_altivec_vcmpeqfp_p(__CR6_EQ, __a, __b); 10830} 10831 10832/* vec_all_nge */ 10833 10834static int __attribute__((__always_inline__)) 10835vec_all_nge(vector float __a, vector float __b) 10836{ 10837 return __builtin_altivec_vcmpgefp_p(__CR6_EQ, __a, __b); 10838} 10839 10840/* vec_all_ngt */ 10841 10842static int __attribute__((__always_inline__)) 10843vec_all_ngt(vector float __a, vector float __b) 10844{ 10845 return __builtin_altivec_vcmpgtfp_p(__CR6_EQ, __a, __b); 10846} 10847 10848/* vec_all_nle */ 10849 10850static int __attribute__((__always_inline__)) 10851vec_all_nle(vector float __a, vector float __b) 10852{ 10853 return __builtin_altivec_vcmpgefp_p(__CR6_EQ, __b, __a); 10854} 10855 10856/* vec_all_nlt */ 10857 10858static int __attribute__((__always_inline__)) 10859vec_all_nlt(vector float __a, vector float __b) 10860{ 10861 return __builtin_altivec_vcmpgtfp_p(__CR6_EQ, __b, __a); 10862} 10863 10864/* vec_all_numeric */ 10865 10866static int __attribute__((__always_inline__)) 10867vec_all_numeric(vector float __a) 10868{ 10869 return __builtin_altivec_vcmpeqfp_p(__CR6_LT, __a, __a); 10870} 10871 10872/* vec_any_eq */ 10873 10874static int __ATTRS_o_ai 10875vec_any_eq(vector signed char __a, vector signed char __b) 10876{ 10877 return 10878 __builtin_altivec_vcmpequb_p(__CR6_EQ_REV, (vector char)__a, (vector char)__b); 10879} 10880 10881static int __ATTRS_o_ai 10882vec_any_eq(vector signed char __a, vector bool char __b) 10883{ 10884 return 10885 __builtin_altivec_vcmpequb_p(__CR6_EQ_REV, (vector char)__a, (vector char)__b); 10886} 10887 10888static int __ATTRS_o_ai 10889vec_any_eq(vector unsigned char __a, vector unsigned char __b) 10890{ 10891 return 10892 __builtin_altivec_vcmpequb_p(__CR6_EQ_REV, (vector char)__a, (vector char)__b); 10893} 10894 10895static int __ATTRS_o_ai 10896vec_any_eq(vector unsigned char __a, vector bool char __b) 10897{ 10898 return 10899 __builtin_altivec_vcmpequb_p(__CR6_EQ_REV, (vector char)__a, (vector char)__b); 10900} 10901 10902static int __ATTRS_o_ai 10903vec_any_eq(vector bool char __a, vector signed char __b) 10904{ 10905 return 10906 __builtin_altivec_vcmpequb_p(__CR6_EQ_REV, (vector char)__a, (vector char)__b); 10907} 10908 10909static int __ATTRS_o_ai 10910vec_any_eq(vector bool char __a, vector unsigned char __b) 10911{ 10912 return 10913 __builtin_altivec_vcmpequb_p(__CR6_EQ_REV, (vector char)__a, (vector char)__b); 10914} 10915 10916static int __ATTRS_o_ai 10917vec_any_eq(vector bool char __a, vector bool char __b) 10918{ 10919 return 10920 __builtin_altivec_vcmpequb_p(__CR6_EQ_REV, (vector char)__a, (vector char)__b); 10921} 10922 10923static int __ATTRS_o_ai 10924vec_any_eq(vector short __a, vector short __b) 10925{ 10926 return __builtin_altivec_vcmpequh_p(__CR6_EQ_REV, __a, __b); 10927} 10928 10929static int __ATTRS_o_ai 10930vec_any_eq(vector short __a, vector bool short __b) 10931{ 10932 return __builtin_altivec_vcmpequh_p(__CR6_EQ_REV, __a, (vector short)__b); 10933} 10934 10935static int __ATTRS_o_ai 10936vec_any_eq(vector unsigned short __a, vector unsigned short __b) 10937{ 10938 return __builtin_altivec_vcmpequh_p(__CR6_EQ_REV, 10939 (vector short)__a, 10940 (vector short)__b); 10941} 10942 10943static int __ATTRS_o_ai 10944vec_any_eq(vector unsigned short __a, vector bool short __b) 10945{ 10946 return __builtin_altivec_vcmpequh_p(__CR6_EQ_REV, 10947 (vector short)__a, 10948 (vector short)__b); 10949} 10950 10951static int __ATTRS_o_ai 10952vec_any_eq(vector bool short __a, vector short __b) 10953{ 10954 return __builtin_altivec_vcmpequh_p(__CR6_EQ_REV, 10955 (vector short)__a, 10956 (vector short)__b); 10957} 10958 10959static int __ATTRS_o_ai 10960vec_any_eq(vector bool short __a, vector unsigned short __b) 10961{ 10962 return __builtin_altivec_vcmpequh_p(__CR6_EQ_REV, 10963 (vector short)__a, 10964 (vector short)__b); 10965} 10966 10967static int __ATTRS_o_ai 10968vec_any_eq(vector bool short __a, vector bool short __b) 10969{ 10970 return __builtin_altivec_vcmpequh_p(__CR6_EQ_REV, 10971 (vector short)__a, 10972 (vector short)__b); 10973} 10974 10975static int __ATTRS_o_ai 10976vec_any_eq(vector pixel __a, vector pixel __b) 10977{ 10978 return __builtin_altivec_vcmpequh_p(__CR6_EQ_REV, 10979 (vector short)__a, 10980 (vector short)__b); 10981} 10982 10983static int __ATTRS_o_ai 10984vec_any_eq(vector int __a, vector int __b) 10985{ 10986 return __builtin_altivec_vcmpequw_p(__CR6_EQ_REV, __a, __b); 10987} 10988 10989static int __ATTRS_o_ai 10990vec_any_eq(vector int __a, vector bool int __b) 10991{ 10992 return __builtin_altivec_vcmpequw_p(__CR6_EQ_REV, __a, (vector int)__b); 10993} 10994 10995static int __ATTRS_o_ai 10996vec_any_eq(vector unsigned int __a, vector unsigned int __b) 10997{ 10998 return 10999 __builtin_altivec_vcmpequw_p(__CR6_EQ_REV, (vector int)__a, (vector int)__b); 11000} 11001 11002static int __ATTRS_o_ai 11003vec_any_eq(vector unsigned int __a, vector bool int __b) 11004{ 11005 return 11006 __builtin_altivec_vcmpequw_p(__CR6_EQ_REV, (vector int)__a, (vector int)__b); 11007} 11008 11009static int __ATTRS_o_ai 11010vec_any_eq(vector bool int __a, vector int __b) 11011{ 11012 return 11013 __builtin_altivec_vcmpequw_p(__CR6_EQ_REV, (vector int)__a, (vector int)__b); 11014} 11015 11016static int __ATTRS_o_ai 11017vec_any_eq(vector bool int __a, vector unsigned int __b) 11018{ 11019 return 11020 __builtin_altivec_vcmpequw_p(__CR6_EQ_REV, (vector int)__a, (vector int)__b); 11021} 11022 11023static int __ATTRS_o_ai 11024vec_any_eq(vector bool int __a, vector bool int __b) 11025{ 11026 return 11027 __builtin_altivec_vcmpequw_p(__CR6_EQ_REV, (vector int)__a, (vector int)__b); 11028} 11029 11030static int __ATTRS_o_ai 11031vec_any_eq(vector float __a, vector float __b) 11032{ 11033 return __builtin_altivec_vcmpeqfp_p(__CR6_EQ_REV, __a, __b); 11034} 11035 11036/* vec_any_ge */ 11037 11038static int __ATTRS_o_ai 11039vec_any_ge(vector signed char __a, vector signed char __b) 11040{ 11041 return __builtin_altivec_vcmpgtsb_p(__CR6_LT_REV, __b, __a); 11042} 11043 11044static int __ATTRS_o_ai 11045vec_any_ge(vector signed char __a, vector bool char __b) 11046{ 11047 return __builtin_altivec_vcmpgtsb_p(__CR6_LT_REV, (vector signed char)__b, __a); 11048} 11049 11050static int __ATTRS_o_ai 11051vec_any_ge(vector unsigned char __a, vector unsigned char __b) 11052{ 11053 return __builtin_altivec_vcmpgtub_p(__CR6_LT_REV, __b, __a); 11054} 11055 11056static int __ATTRS_o_ai 11057vec_any_ge(vector unsigned char __a, vector bool char __b) 11058{ 11059 return __builtin_altivec_vcmpgtub_p(__CR6_LT_REV, (vector unsigned char)__b, __a); 11060} 11061 11062static int __ATTRS_o_ai 11063vec_any_ge(vector bool char __a, vector signed char __b) 11064{ 11065 return __builtin_altivec_vcmpgtub_p(__CR6_LT_REV, 11066 (vector unsigned char)__b, 11067 (vector unsigned char)__a); 11068} 11069 11070static int __ATTRS_o_ai 11071vec_any_ge(vector bool char __a, vector unsigned char __b) 11072{ 11073 return __builtin_altivec_vcmpgtub_p(__CR6_LT_REV, __b, (vector unsigned char)__a); 11074} 11075 11076static int __ATTRS_o_ai 11077vec_any_ge(vector bool char __a, vector bool char __b) 11078{ 11079 return __builtin_altivec_vcmpgtub_p(__CR6_LT_REV, 11080 (vector unsigned char)__b, 11081 (vector unsigned char)__a); 11082} 11083 11084static int __ATTRS_o_ai 11085vec_any_ge(vector short __a, vector short __b) 11086{ 11087 return __builtin_altivec_vcmpgtsh_p(__CR6_LT_REV, __b, __a); 11088} 11089 11090static int __ATTRS_o_ai 11091vec_any_ge(vector short __a, vector bool short __b) 11092{ 11093 return __builtin_altivec_vcmpgtsh_p(__CR6_LT_REV, (vector short)__b, __a); 11094} 11095 11096static int __ATTRS_o_ai 11097vec_any_ge(vector unsigned short __a, vector unsigned short __b) 11098{ 11099 return __builtin_altivec_vcmpgtuh_p(__CR6_LT_REV, __b, __a); 11100} 11101 11102static int __ATTRS_o_ai 11103vec_any_ge(vector unsigned short __a, vector bool short __b) 11104{ 11105 return 11106 __builtin_altivec_vcmpgtuh_p(__CR6_LT_REV, (vector unsigned short)__b, __a); 11107} 11108 11109static int __ATTRS_o_ai 11110vec_any_ge(vector bool short __a, vector short __b) 11111{ 11112 return __builtin_altivec_vcmpgtuh_p(__CR6_LT_REV, 11113 (vector unsigned short)__b, 11114 (vector unsigned short)__a); 11115} 11116 11117static int __ATTRS_o_ai 11118vec_any_ge(vector bool short __a, vector unsigned short __b) 11119{ 11120 return 11121 __builtin_altivec_vcmpgtuh_p(__CR6_LT_REV, __b, (vector unsigned short)__a); 11122} 11123 11124static int __ATTRS_o_ai 11125vec_any_ge(vector bool short __a, vector bool short __b) 11126{ 11127 return __builtin_altivec_vcmpgtuh_p(__CR6_LT_REV, 11128 (vector unsigned short)__b, 11129 (vector unsigned short)__a); 11130} 11131 11132static int __ATTRS_o_ai 11133vec_any_ge(vector int __a, vector int __b) 11134{ 11135 return __builtin_altivec_vcmpgtsw_p(__CR6_LT_REV, __b, __a); 11136} 11137 11138static int __ATTRS_o_ai 11139vec_any_ge(vector int __a, vector bool int __b) 11140{ 11141 return __builtin_altivec_vcmpgtsw_p(__CR6_LT_REV, (vector int)__b, __a); 11142} 11143 11144static int __ATTRS_o_ai 11145vec_any_ge(vector unsigned int __a, vector unsigned int __b) 11146{ 11147 return __builtin_altivec_vcmpgtuw_p(__CR6_LT_REV, __b, __a); 11148} 11149 11150static int __ATTRS_o_ai 11151vec_any_ge(vector unsigned int __a, vector bool int __b) 11152{ 11153 return __builtin_altivec_vcmpgtuw_p(__CR6_LT_REV, (vector unsigned int)__b, __a); 11154} 11155 11156static int __ATTRS_o_ai 11157vec_any_ge(vector bool int __a, vector int __b) 11158{ 11159 return __builtin_altivec_vcmpgtuw_p(__CR6_LT_REV, 11160 (vector unsigned int)__b, 11161 (vector unsigned int)__a); 11162} 11163 11164static int __ATTRS_o_ai 11165vec_any_ge(vector bool int __a, vector unsigned int __b) 11166{ 11167 return __builtin_altivec_vcmpgtuw_p(__CR6_LT_REV, __b, (vector unsigned int)__a); 11168} 11169 11170static int __ATTRS_o_ai 11171vec_any_ge(vector bool int __a, vector bool int __b) 11172{ 11173 return __builtin_altivec_vcmpgtuw_p(__CR6_LT_REV, 11174 (vector unsigned int)__b, 11175 (vector unsigned int)__a); 11176} 11177 11178static int __ATTRS_o_ai 11179vec_any_ge(vector float __a, vector float __b) 11180{ 11181 return __builtin_altivec_vcmpgefp_p(__CR6_EQ_REV, __a, __b); 11182} 11183 11184/* vec_any_gt */ 11185 11186static int __ATTRS_o_ai 11187vec_any_gt(vector signed char __a, vector signed char __b) 11188{ 11189 return __builtin_altivec_vcmpgtsb_p(__CR6_EQ_REV, __a, __b); 11190} 11191 11192static int __ATTRS_o_ai 11193vec_any_gt(vector signed char __a, vector bool char __b) 11194{ 11195 return __builtin_altivec_vcmpgtsb_p(__CR6_EQ_REV, __a, (vector signed char)__b); 11196} 11197 11198static int __ATTRS_o_ai 11199vec_any_gt(vector unsigned char __a, vector unsigned char __b) 11200{ 11201 return __builtin_altivec_vcmpgtub_p(__CR6_EQ_REV, __a, __b); 11202} 11203 11204static int __ATTRS_o_ai 11205vec_any_gt(vector unsigned char __a, vector bool char __b) 11206{ 11207 return 11208 __builtin_altivec_vcmpgtub_p(__CR6_EQ_REV, __a, (vector unsigned char)__b); 11209} 11210 11211static int __ATTRS_o_ai 11212vec_any_gt(vector bool char __a, vector signed char __b) 11213{ 11214 return __builtin_altivec_vcmpgtub_p(__CR6_EQ_REV, 11215 (vector unsigned char)__a, 11216 (vector unsigned char)__b); 11217} 11218 11219static int __ATTRS_o_ai 11220vec_any_gt(vector bool char __a, vector unsigned char __b) 11221{ 11222 return 11223 __builtin_altivec_vcmpgtub_p(__CR6_EQ_REV, (vector unsigned char)__a, __b); 11224} 11225 11226static int __ATTRS_o_ai 11227vec_any_gt(vector bool char __a, vector bool char __b) 11228{ 11229 return __builtin_altivec_vcmpgtub_p(__CR6_EQ_REV, 11230 (vector unsigned char)__a, 11231 (vector unsigned char)__b); 11232} 11233 11234static int __ATTRS_o_ai 11235vec_any_gt(vector short __a, vector short __b) 11236{ 11237 return __builtin_altivec_vcmpgtsh_p(__CR6_EQ_REV, __a, __b); 11238} 11239 11240static int __ATTRS_o_ai 11241vec_any_gt(vector short __a, vector bool short __b) 11242{ 11243 return __builtin_altivec_vcmpgtsh_p(__CR6_EQ_REV, __a, (vector short)__b); 11244} 11245 11246static int __ATTRS_o_ai 11247vec_any_gt(vector unsigned short __a, vector unsigned short __b) 11248{ 11249 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ_REV, __a, __b); 11250} 11251 11252static int __ATTRS_o_ai 11253vec_any_gt(vector unsigned short __a, vector bool short __b) 11254{ 11255 return 11256 __builtin_altivec_vcmpgtuh_p(__CR6_EQ_REV, __a, (vector unsigned short)__b); 11257} 11258 11259static int __ATTRS_o_ai 11260vec_any_gt(vector bool short __a, vector short __b) 11261{ 11262 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ_REV, 11263 (vector unsigned short)__a, 11264 (vector unsigned short)__b); 11265} 11266 11267static int __ATTRS_o_ai 11268vec_any_gt(vector bool short __a, vector unsigned short __b) 11269{ 11270 return 11271 __builtin_altivec_vcmpgtuh_p(__CR6_EQ_REV, (vector unsigned short)__a, __b); 11272} 11273 11274static int __ATTRS_o_ai 11275vec_any_gt(vector bool short __a, vector bool short __b) 11276{ 11277 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ_REV, 11278 (vector unsigned short)__a, 11279 (vector unsigned short)__b); 11280} 11281 11282static int __ATTRS_o_ai 11283vec_any_gt(vector int __a, vector int __b) 11284{ 11285 return __builtin_altivec_vcmpgtsw_p(__CR6_EQ_REV, __a, __b); 11286} 11287 11288static int __ATTRS_o_ai 11289vec_any_gt(vector int __a, vector bool int __b) 11290{ 11291 return __builtin_altivec_vcmpgtsw_p(__CR6_EQ_REV, __a, (vector int)__b); 11292} 11293 11294static int __ATTRS_o_ai 11295vec_any_gt(vector unsigned int __a, vector unsigned int __b) 11296{ 11297 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ_REV, __a, __b); 11298} 11299 11300static int __ATTRS_o_ai 11301vec_any_gt(vector unsigned int __a, vector bool int __b) 11302{ 11303 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ_REV, __a, (vector unsigned int)__b); 11304} 11305 11306static int __ATTRS_o_ai 11307vec_any_gt(vector bool int __a, vector int __b) 11308{ 11309 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ_REV, 11310 (vector unsigned int)__a, 11311 (vector unsigned int)__b); 11312} 11313 11314static int __ATTRS_o_ai 11315vec_any_gt(vector bool int __a, vector unsigned int __b) 11316{ 11317 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ_REV, (vector unsigned int)__a, __b); 11318} 11319 11320static int __ATTRS_o_ai 11321vec_any_gt(vector bool int __a, vector bool int __b) 11322{ 11323 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ_REV, 11324 (vector unsigned int)__a, 11325 (vector unsigned int)__b); 11326} 11327 11328static int __ATTRS_o_ai 11329vec_any_gt(vector float __a, vector float __b) 11330{ 11331 return __builtin_altivec_vcmpgtfp_p(__CR6_EQ_REV, __a, __b); 11332} 11333 11334/* vec_any_le */ 11335 11336static int __ATTRS_o_ai 11337vec_any_le(vector signed char __a, vector signed char __b) 11338{ 11339 return __builtin_altivec_vcmpgtsb_p(__CR6_LT_REV, __a, __b); 11340} 11341 11342static int __ATTRS_o_ai 11343vec_any_le(vector signed char __a, vector bool char __b) 11344{ 11345 return __builtin_altivec_vcmpgtsb_p(__CR6_LT_REV, __a, (vector signed char)__b); 11346} 11347 11348static int __ATTRS_o_ai 11349vec_any_le(vector unsigned char __a, vector unsigned char __b) 11350{ 11351 return __builtin_altivec_vcmpgtub_p(__CR6_LT_REV, __a, __b); 11352} 11353 11354static int __ATTRS_o_ai 11355vec_any_le(vector unsigned char __a, vector bool char __b) 11356{ 11357 return 11358 __builtin_altivec_vcmpgtub_p(__CR6_LT_REV, __a, (vector unsigned char)__b); 11359} 11360 11361static int __ATTRS_o_ai 11362vec_any_le(vector bool char __a, vector signed char __b) 11363{ 11364 return __builtin_altivec_vcmpgtub_p(__CR6_LT_REV, 11365 (vector unsigned char)__a, 11366 (vector unsigned char)__b); 11367} 11368 11369static int __ATTRS_o_ai 11370vec_any_le(vector bool char __a, vector unsigned char __b) 11371{ 11372 return 11373 __builtin_altivec_vcmpgtub_p(__CR6_LT_REV, (vector unsigned char)__a, __b); 11374} 11375 11376static int __ATTRS_o_ai 11377vec_any_le(vector bool char __a, vector bool char __b) 11378{ 11379 return __builtin_altivec_vcmpgtub_p(__CR6_LT_REV, 11380 (vector unsigned char)__a, 11381 (vector unsigned char)__b); 11382} 11383 11384static int __ATTRS_o_ai 11385vec_any_le(vector short __a, vector short __b) 11386{ 11387 return __builtin_altivec_vcmpgtsh_p(__CR6_LT_REV, __a, __b); 11388} 11389 11390static int __ATTRS_o_ai 11391vec_any_le(vector short __a, vector bool short __b) 11392{ 11393 return __builtin_altivec_vcmpgtsh_p(__CR6_LT_REV, __a, (vector short)__b); 11394} 11395 11396static int __ATTRS_o_ai 11397vec_any_le(vector unsigned short __a, vector unsigned short __b) 11398{ 11399 return __builtin_altivec_vcmpgtuh_p(__CR6_LT_REV, __a, __b); 11400} 11401 11402static int __ATTRS_o_ai 11403vec_any_le(vector unsigned short __a, vector bool short __b) 11404{ 11405 return 11406 __builtin_altivec_vcmpgtuh_p(__CR6_LT_REV, __a, (vector unsigned short)__b); 11407} 11408 11409static int __ATTRS_o_ai 11410vec_any_le(vector bool short __a, vector short __b) 11411{ 11412 return __builtin_altivec_vcmpgtuh_p(__CR6_LT_REV, 11413 (vector unsigned short)__a, 11414 (vector unsigned short)__b); 11415} 11416 11417static int __ATTRS_o_ai 11418vec_any_le(vector bool short __a, vector unsigned short __b) 11419{ 11420 return 11421 __builtin_altivec_vcmpgtuh_p(__CR6_LT_REV, (vector unsigned short)__a, __b); 11422} 11423 11424static int __ATTRS_o_ai 11425vec_any_le(vector bool short __a, vector bool short __b) 11426{ 11427 return __builtin_altivec_vcmpgtuh_p(__CR6_LT_REV, 11428 (vector unsigned short)__a, 11429 (vector unsigned short)__b); 11430} 11431 11432static int __ATTRS_o_ai 11433vec_any_le(vector int __a, vector int __b) 11434{ 11435 return __builtin_altivec_vcmpgtsw_p(__CR6_LT_REV, __a, __b); 11436} 11437 11438static int __ATTRS_o_ai 11439vec_any_le(vector int __a, vector bool int __b) 11440{ 11441 return __builtin_altivec_vcmpgtsw_p(__CR6_LT_REV, __a, (vector int)__b); 11442} 11443 11444static int __ATTRS_o_ai 11445vec_any_le(vector unsigned int __a, vector unsigned int __b) 11446{ 11447 return __builtin_altivec_vcmpgtuw_p(__CR6_LT_REV, __a, __b); 11448} 11449 11450static int __ATTRS_o_ai 11451vec_any_le(vector unsigned int __a, vector bool int __b) 11452{ 11453 return __builtin_altivec_vcmpgtuw_p(__CR6_LT_REV, __a, (vector unsigned int)__b); 11454} 11455 11456static int __ATTRS_o_ai 11457vec_any_le(vector bool int __a, vector int __b) 11458{ 11459 return __builtin_altivec_vcmpgtuw_p(__CR6_LT_REV, 11460 (vector unsigned int)__a, 11461 (vector unsigned int)__b); 11462} 11463 11464static int __ATTRS_o_ai 11465vec_any_le(vector bool int __a, vector unsigned int __b) 11466{ 11467 return __builtin_altivec_vcmpgtuw_p(__CR6_LT_REV, (vector unsigned int)__a, __b); 11468} 11469 11470static int __ATTRS_o_ai 11471vec_any_le(vector bool int __a, vector bool int __b) 11472{ 11473 return __builtin_altivec_vcmpgtuw_p(__CR6_LT_REV, 11474 (vector unsigned int)__a, 11475 (vector unsigned int)__b); 11476} 11477 11478static int __ATTRS_o_ai 11479vec_any_le(vector float __a, vector float __b) 11480{ 11481 return __builtin_altivec_vcmpgefp_p(__CR6_EQ_REV, __b, __a); 11482} 11483 11484/* vec_any_lt */ 11485 11486static int __ATTRS_o_ai 11487vec_any_lt(vector signed char __a, vector signed char __b) 11488{ 11489 return __builtin_altivec_vcmpgtsb_p(__CR6_EQ_REV, __b, __a); 11490} 11491 11492static int __ATTRS_o_ai 11493vec_any_lt(vector signed char __a, vector bool char __b) 11494{ 11495 return __builtin_altivec_vcmpgtsb_p(__CR6_EQ_REV, (vector signed char)__b, __a); 11496} 11497 11498static int __ATTRS_o_ai 11499vec_any_lt(vector unsigned char __a, vector unsigned char __b) 11500{ 11501 return __builtin_altivec_vcmpgtub_p(__CR6_EQ_REV, __b, __a); 11502} 11503 11504static int __ATTRS_o_ai 11505vec_any_lt(vector unsigned char __a, vector bool char __b) 11506{ 11507 return 11508 __builtin_altivec_vcmpgtub_p(__CR6_EQ_REV, (vector unsigned char)__b, __a); 11509} 11510 11511static int __ATTRS_o_ai 11512vec_any_lt(vector bool char __a, vector signed char __b) 11513{ 11514 return __builtin_altivec_vcmpgtub_p(__CR6_EQ_REV, 11515 (vector unsigned char)__b, 11516 (vector unsigned char)__a); 11517} 11518 11519static int __ATTRS_o_ai 11520vec_any_lt(vector bool char __a, vector unsigned char __b) 11521{ 11522 return 11523 __builtin_altivec_vcmpgtub_p(__CR6_EQ_REV, __b, (vector unsigned char)__a); 11524} 11525 11526static int __ATTRS_o_ai 11527vec_any_lt(vector bool char __a, vector bool char __b) 11528{ 11529 return __builtin_altivec_vcmpgtub_p(__CR6_EQ_REV, 11530 (vector unsigned char)__b, 11531 (vector unsigned char)__a); 11532} 11533 11534static int __ATTRS_o_ai 11535vec_any_lt(vector short __a, vector short __b) 11536{ 11537 return __builtin_altivec_vcmpgtsh_p(__CR6_EQ_REV, __b, __a); 11538} 11539 11540static int __ATTRS_o_ai 11541vec_any_lt(vector short __a, vector bool short __b) 11542{ 11543 return __builtin_altivec_vcmpgtsh_p(__CR6_EQ_REV, (vector short)__b, __a); 11544} 11545 11546static int __ATTRS_o_ai 11547vec_any_lt(vector unsigned short __a, vector unsigned short __b) 11548{ 11549 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ_REV, __b, __a); 11550} 11551 11552static int __ATTRS_o_ai 11553vec_any_lt(vector unsigned short __a, vector bool short __b) 11554{ 11555 return 11556 __builtin_altivec_vcmpgtuh_p(__CR6_EQ_REV, (vector unsigned short)__b, __a); 11557} 11558 11559static int __ATTRS_o_ai 11560vec_any_lt(vector bool short __a, vector short __b) 11561{ 11562 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ_REV, 11563 (vector unsigned short)__b, 11564 (vector unsigned short)__a); 11565} 11566 11567static int __ATTRS_o_ai 11568vec_any_lt(vector bool short __a, vector unsigned short __b) 11569{ 11570 return 11571 __builtin_altivec_vcmpgtuh_p(__CR6_EQ_REV, __b, (vector unsigned short)__a); 11572} 11573 11574static int __ATTRS_o_ai 11575vec_any_lt(vector bool short __a, vector bool short __b) 11576{ 11577 return __builtin_altivec_vcmpgtuh_p(__CR6_EQ_REV, 11578 (vector unsigned short)__b, 11579 (vector unsigned short)__a); 11580} 11581 11582static int __ATTRS_o_ai 11583vec_any_lt(vector int __a, vector int __b) 11584{ 11585 return __builtin_altivec_vcmpgtsw_p(__CR6_EQ_REV, __b, __a); 11586} 11587 11588static int __ATTRS_o_ai 11589vec_any_lt(vector int __a, vector bool int __b) 11590{ 11591 return __builtin_altivec_vcmpgtsw_p(__CR6_EQ_REV, (vector int)__b, __a); 11592} 11593 11594static int __ATTRS_o_ai 11595vec_any_lt(vector unsigned int __a, vector unsigned int __b) 11596{ 11597 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ_REV, __b, __a); 11598} 11599 11600static int __ATTRS_o_ai 11601vec_any_lt(vector unsigned int __a, vector bool int __b) 11602{ 11603 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ_REV, (vector unsigned int)__b, __a); 11604} 11605 11606static int __ATTRS_o_ai 11607vec_any_lt(vector bool int __a, vector int __b) 11608{ 11609 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ_REV, 11610 (vector unsigned int)__b, 11611 (vector unsigned int)__a); 11612} 11613 11614static int __ATTRS_o_ai 11615vec_any_lt(vector bool int __a, vector unsigned int __b) 11616{ 11617 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ_REV, __b, (vector unsigned int)__a); 11618} 11619 11620static int __ATTRS_o_ai 11621vec_any_lt(vector bool int __a, vector bool int __b) 11622{ 11623 return __builtin_altivec_vcmpgtuw_p(__CR6_EQ_REV, 11624 (vector unsigned int)__b, 11625 (vector unsigned int)__a); 11626} 11627 11628static int __ATTRS_o_ai 11629vec_any_lt(vector float __a, vector float __b) 11630{ 11631 return __builtin_altivec_vcmpgtfp_p(__CR6_EQ_REV, __b, __a); 11632} 11633 11634/* vec_any_nan */ 11635 11636static int __attribute__((__always_inline__)) 11637vec_any_nan(vector float __a) 11638{ 11639 return __builtin_altivec_vcmpeqfp_p(__CR6_LT_REV, __a, __a); 11640} 11641 11642/* vec_any_ne */ 11643 11644static int __ATTRS_o_ai 11645vec_any_ne(vector signed char __a, vector signed char __b) 11646{ 11647 return 11648 __builtin_altivec_vcmpequb_p(__CR6_LT_REV, (vector char)__a, (vector char)__b); 11649} 11650 11651static int __ATTRS_o_ai 11652vec_any_ne(vector signed char __a, vector bool char __b) 11653{ 11654 return 11655 __builtin_altivec_vcmpequb_p(__CR6_LT_REV, (vector char)__a, (vector char)__b); 11656} 11657 11658static int __ATTRS_o_ai 11659vec_any_ne(vector unsigned char __a, vector unsigned char __b) 11660{ 11661 return 11662 __builtin_altivec_vcmpequb_p(__CR6_LT_REV, (vector char)__a, (vector char)__b); 11663} 11664 11665static int __ATTRS_o_ai 11666vec_any_ne(vector unsigned char __a, vector bool char __b) 11667{ 11668 return 11669 __builtin_altivec_vcmpequb_p(__CR6_LT_REV, (vector char)__a, (vector char)__b); 11670} 11671 11672static int __ATTRS_o_ai 11673vec_any_ne(vector bool char __a, vector signed char __b) 11674{ 11675 return 11676 __builtin_altivec_vcmpequb_p(__CR6_LT_REV, (vector char)__a, (vector char)__b); 11677} 11678 11679static int __ATTRS_o_ai 11680vec_any_ne(vector bool char __a, vector unsigned char __b) 11681{ 11682 return 11683 __builtin_altivec_vcmpequb_p(__CR6_LT_REV, (vector char)__a, (vector char)__b); 11684} 11685 11686static int __ATTRS_o_ai 11687vec_any_ne(vector bool char __a, vector bool char __b) 11688{ 11689 return 11690 __builtin_altivec_vcmpequb_p(__CR6_LT_REV, (vector char)__a, (vector char)__b); 11691} 11692 11693static int __ATTRS_o_ai 11694vec_any_ne(vector short __a, vector short __b) 11695{ 11696 return __builtin_altivec_vcmpequh_p(__CR6_LT_REV, __a, __b); 11697} 11698 11699static int __ATTRS_o_ai 11700vec_any_ne(vector short __a, vector bool short __b) 11701{ 11702 return __builtin_altivec_vcmpequh_p(__CR6_LT_REV, __a, (vector short)__b); 11703} 11704 11705static int __ATTRS_o_ai 11706vec_any_ne(vector unsigned short __a, vector unsigned short __b) 11707{ 11708 return __builtin_altivec_vcmpequh_p(__CR6_LT_REV, 11709 (vector short)__a, 11710 (vector short)__b); 11711} 11712 11713static int __ATTRS_o_ai 11714vec_any_ne(vector unsigned short __a, vector bool short __b) 11715{ 11716 return __builtin_altivec_vcmpequh_p(__CR6_LT_REV, 11717 (vector short)__a, 11718 (vector short)__b); 11719} 11720 11721static int __ATTRS_o_ai 11722vec_any_ne(vector bool short __a, vector short __b) 11723{ 11724 return __builtin_altivec_vcmpequh_p(__CR6_LT_REV, 11725 (vector short)__a, 11726 (vector short)__b); 11727} 11728 11729static int __ATTRS_o_ai 11730vec_any_ne(vector bool short __a, vector unsigned short __b) 11731{ 11732 return __builtin_altivec_vcmpequh_p(__CR6_LT_REV, 11733 (vector short)__a, 11734 (vector short)__b); 11735} 11736 11737static int __ATTRS_o_ai 11738vec_any_ne(vector bool short __a, vector bool short __b) 11739{ 11740 return __builtin_altivec_vcmpequh_p(__CR6_LT_REV, 11741 (vector short)__a, 11742 (vector short)__b); 11743} 11744 11745static int __ATTRS_o_ai 11746vec_any_ne(vector pixel __a, vector pixel __b) 11747{ 11748 return __builtin_altivec_vcmpequh_p(__CR6_LT_REV, 11749 (vector short)__a, 11750 (vector short)__b); 11751} 11752 11753static int __ATTRS_o_ai 11754vec_any_ne(vector int __a, vector int __b) 11755{ 11756 return __builtin_altivec_vcmpequw_p(__CR6_LT_REV, __a, __b); 11757} 11758 11759static int __ATTRS_o_ai 11760vec_any_ne(vector int __a, vector bool int __b) 11761{ 11762 return __builtin_altivec_vcmpequw_p(__CR6_LT_REV, __a, (vector int)__b); 11763} 11764 11765static int __ATTRS_o_ai 11766vec_any_ne(vector unsigned int __a, vector unsigned int __b) 11767{ 11768 return 11769 __builtin_altivec_vcmpequw_p(__CR6_LT_REV, (vector int)__a, (vector int)__b); 11770} 11771 11772static int __ATTRS_o_ai 11773vec_any_ne(vector unsigned int __a, vector bool int __b) 11774{ 11775 return 11776 __builtin_altivec_vcmpequw_p(__CR6_LT_REV, (vector int)__a, (vector int)__b); 11777} 11778 11779static int __ATTRS_o_ai 11780vec_any_ne(vector bool int __a, vector int __b) 11781{ 11782 return 11783 __builtin_altivec_vcmpequw_p(__CR6_LT_REV, (vector int)__a, (vector int)__b); 11784} 11785 11786static int __ATTRS_o_ai 11787vec_any_ne(vector bool int __a, vector unsigned int __b) 11788{ 11789 return 11790 __builtin_altivec_vcmpequw_p(__CR6_LT_REV, (vector int)__a, (vector int)__b); 11791} 11792 11793static int __ATTRS_o_ai 11794vec_any_ne(vector bool int __a, vector bool int __b) 11795{ 11796 return 11797 __builtin_altivec_vcmpequw_p(__CR6_LT_REV, (vector int)__a, (vector int)__b); 11798} 11799 11800static int __ATTRS_o_ai 11801vec_any_ne(vector float __a, vector float __b) 11802{ 11803 return __builtin_altivec_vcmpeqfp_p(__CR6_LT_REV, __a, __b); 11804} 11805 11806/* vec_any_nge */ 11807 11808static int __attribute__((__always_inline__)) 11809vec_any_nge(vector float __a, vector float __b) 11810{ 11811 return __builtin_altivec_vcmpgefp_p(__CR6_LT_REV, __a, __b); 11812} 11813 11814/* vec_any_ngt */ 11815 11816static int __attribute__((__always_inline__)) 11817vec_any_ngt(vector float __a, vector float __b) 11818{ 11819 return __builtin_altivec_vcmpgtfp_p(__CR6_LT_REV, __a, __b); 11820} 11821 11822/* vec_any_nle */ 11823 11824static int __attribute__((__always_inline__)) 11825vec_any_nle(vector float __a, vector float __b) 11826{ 11827 return __builtin_altivec_vcmpgefp_p(__CR6_LT_REV, __b, __a); 11828} 11829 11830/* vec_any_nlt */ 11831 11832static int __attribute__((__always_inline__)) 11833vec_any_nlt(vector float __a, vector float __b) 11834{ 11835 return __builtin_altivec_vcmpgtfp_p(__CR6_LT_REV, __b, __a); 11836} 11837 11838/* vec_any_numeric */ 11839 11840static int __attribute__((__always_inline__)) 11841vec_any_numeric(vector float __a) 11842{ 11843 return __builtin_altivec_vcmpeqfp_p(__CR6_EQ_REV, __a, __a); 11844} 11845 11846/* vec_any_out */ 11847 11848static int __attribute__((__always_inline__)) 11849vec_any_out(vector float __a, vector float __b) 11850{ 11851 return __builtin_altivec_vcmpbfp_p(__CR6_EQ_REV, __a, __b); 11852} 11853 11854#undef __ATTRS_o_ai 11855 11856#endif /* __ALTIVEC_H */ 11857