|
| 1 | +/* { dg-do compile } */ |
| 2 | +/* { dg-options "-O2 -fdump-tree-forwprop1" } */ |
| 3 | +/* { dg-additional-options "-fgimple" } */ |
| 4 | + |
| 5 | +#include <stdint.h> |
| 6 | + |
| 7 | +typedef int32_t int32x4_t __attribute__((vector_size(16))); |
| 8 | +typedef int32_t int32x2_t __attribute__((vector_size(8))); |
| 9 | +typedef int32_t int32x1_t __attribute__((vector_size(4))); |
| 10 | + |
| 11 | +int32x4_t __GIMPLE (ssa) |
| 12 | +foo (int32x4_t x) |
| 13 | +{ |
| 14 | + int32x2_t _1; |
| 15 | + int32x2_t _2; |
| 16 | + int32x4_t _6; |
| 17 | + |
| 18 | +__BB(2): |
| 19 | + _1 = __BIT_FIELD_REF <int32x2_t> (x, 64, 64); |
| 20 | + _2 = __BIT_FIELD_REF <int32x2_t> (x, 64, 0); |
| 21 | + _6 = _Literal (int32x4_t) { _1, _2 }; |
| 22 | + return _6; |
| 23 | +} |
| 24 | + |
| 25 | +int32x4_t __GIMPLE (ssa) |
| 26 | +foo2 (int32x4_t x) |
| 27 | +{ |
| 28 | + int32x1_t _1; |
| 29 | + int32x1_t _2; |
| 30 | + int32x1_t _3; |
| 31 | + int32x1_t _4; |
| 32 | + int32x4_t _6; |
| 33 | + |
| 34 | +__BB(2): |
| 35 | + _1 = __BIT_FIELD_REF <int32x1_t> (x, 32, 64); |
| 36 | + _2 = __BIT_FIELD_REF <int32x1_t> (x, 32, 96); |
| 37 | + _3 = __BIT_FIELD_REF <int32x1_t> (x, 32, 0); |
| 38 | + _4 = __BIT_FIELD_REF <int32x1_t> (x, 32, 32); |
| 39 | + _6 = _Literal (int32x4_t) { _1, _2, _3, _4 }; |
| 40 | + return _6; |
| 41 | +} |
| 42 | + |
| 43 | +int32x4_t __GIMPLE (ssa) |
| 44 | +foo3 (int32x4_t x, int32x4_t y) |
| 45 | +{ |
| 46 | + int32x2_t _1; |
| 47 | + int32x2_t _2; |
| 48 | + int32x4_t _6; |
| 49 | + |
| 50 | +__BB(2): |
| 51 | + _1 = __BIT_FIELD_REF <int32x2_t> (x, 64, 64); |
| 52 | + _2 = __BIT_FIELD_REF <int32x2_t> (y, 64, 0); |
| 53 | + _6 = _Literal (int32x4_t) { _1, _2 }; |
| 54 | + return _6; |
| 55 | +} |
| 56 | + |
| 57 | +int32x4_t __GIMPLE (ssa) |
| 58 | +foo4 (int32x4_t x, int32x4_t y) |
| 59 | +{ |
| 60 | + int32x1_t _1; |
| 61 | + int32x1_t _2; |
| 62 | + int32x1_t _3; |
| 63 | + int32x1_t _4; |
| 64 | + int32x4_t _6; |
| 65 | + |
| 66 | +__BB(2): |
| 67 | + _1 = __BIT_FIELD_REF <int32x1_t> (x, 32, 64); |
| 68 | + _2 = __BIT_FIELD_REF <int32x1_t> (y, 32, 96); |
| 69 | + _3 = __BIT_FIELD_REF <int32x1_t> (x, 32, 0); |
| 70 | + _4 = __BIT_FIELD_REF <int32x1_t> (y, 32, 32); |
| 71 | + _6 = _Literal (int32x4_t) { _1, _2, _3, _4 }; |
| 72 | + return _6; |
| 73 | +} |
| 74 | + |
| 75 | +int32x4_t __GIMPLE (ssa) |
| 76 | +foo5 (int32x4_t x) |
| 77 | +{ |
| 78 | + int32x2_t _1; |
| 79 | + int32x2_t _2; |
| 80 | + int32x4_t _6; |
| 81 | + |
| 82 | +__BB(2): |
| 83 | + _1 = __BIT_FIELD_REF <int32x2_t> (x, 64, 64); |
| 84 | + _2 = _Literal (int32x2_t) { 1, 2 }; |
| 85 | + _6 = _Literal (int32x4_t) { _1, _2 }; |
| 86 | + return _6; |
| 87 | +} |
| 88 | + |
| 89 | +int32x4_t __GIMPLE (ssa) |
| 90 | +foo6 (int32x4_t x, int32_t y) |
| 91 | +{ |
| 92 | + int32x2_t _1; |
| 93 | + int32x2_t _2; |
| 94 | + int32x4_t _6; |
| 95 | + |
| 96 | +__BB(2): |
| 97 | + _1 = __BIT_FIELD_REF <int32x2_t> (x, 64, 64); |
| 98 | + _2 = _Literal (int32x2_t) { y, y }; |
| 99 | + _6 = _Literal (int32x4_t) { _1, _2 }; |
| 100 | + return _6; |
| 101 | +} |
| 102 | + |
| 103 | +int32x4_t __GIMPLE (ssa) |
| 104 | +foo7 (int32x4_t x) |
| 105 | +{ |
| 106 | + int32x2_t _1; |
| 107 | + int32x2_t _2; |
| 108 | + int32x4_t _6; |
| 109 | + |
| 110 | +__BB(2): |
| 111 | + _1 = __BIT_FIELD_REF <int32x2_t> (x, 64, 64); |
| 112 | + _2 = _Literal (int32x2_t) { 1, 2 }; |
| 113 | + _6 = _Literal (int32x4_t) { _2, _1 }; |
| 114 | + return _6; |
| 115 | +} |
| 116 | + |
| 117 | +int32x4_t __GIMPLE (ssa) |
| 118 | +foo8 (int32x4_t x, int32_t y) |
| 119 | +{ |
| 120 | + int32x2_t _1; |
| 121 | + int32x2_t _2; |
| 122 | + int32x4_t _6; |
| 123 | + |
| 124 | +__BB(2): |
| 125 | + _1 = __BIT_FIELD_REF <int32x2_t> (x, 64, 64); |
| 126 | + _2 = _Literal (int32x2_t) { y, y }; |
| 127 | + _6 = _Literal (int32x4_t) { _2, _1 }; |
| 128 | + return _6; |
| 129 | +} |
| 130 | + |
| 131 | +int32x4_t __GIMPLE (ssa) |
| 132 | +foo9 (int32x4_t x) |
| 133 | +{ |
| 134 | + int32x1_t _1; |
| 135 | + int32x1_t _2; |
| 136 | + int32x1_t _3; |
| 137 | + int32x1_t _4; |
| 138 | + int32x4_t _6; |
| 139 | + |
| 140 | +__BB(2): |
| 141 | + _1 = __BIT_FIELD_REF <int32x1_t> (x, 32, 96); |
| 142 | + _2 = __BIT_FIELD_REF <int32x1_t> (x, 32, 64); |
| 143 | + _3 = _Literal (int32x1_t) { 1 }; |
| 144 | + _4 = _Literal (int32x1_t) { 1 }; |
| 145 | + _6 = _Literal (int32x4_t) { _3, _4, _1, _2 }; |
| 146 | + return _6; |
| 147 | +} |
| 148 | + |
| 149 | +int32x4_t __GIMPLE (ssa) |
| 150 | +foo10 (int32x4_t x, int32_t y) |
| 151 | +{ |
| 152 | + int32x1_t _1; |
| 153 | + int32x1_t _2; |
| 154 | + int32x1_t _3; |
| 155 | + int32x1_t _4; |
| 156 | + int32x4_t _6; |
| 157 | + |
| 158 | +__BB(2): |
| 159 | + _1 = __BIT_FIELD_REF <int32x1_t> (x, 32, 96); |
| 160 | + _2 = __BIT_FIELD_REF <int32x1_t> (x, 32, 64); |
| 161 | + _3 = _Literal (int32x1_t) { y }; |
| 162 | + _4 = _Literal (int32x1_t) { y }; |
| 163 | + _6 = _Literal (int32x4_t) { _3, _4, _1, _2 }; |
| 164 | + |
| 165 | + return _6; |
| 166 | +} |
| 167 | + |
| 168 | + |
| 169 | +/* { dg-final { scan-tree-dump-times "VEC_PERM_EXPR" 10 "forwprop1" } } */ |
0 commit comments