Commit a863949
committed
[SYCL] Implement "swizzle" member function on swizzles
It brings it closer to SYCL spec and makes more consistent by having "named"
swizzle member functions (like `.hi()`/`.lo()`) and `.swizzle<...>()` behave in
a similar way, i.e. we still have a bug when doing a swizzle on an expression
tree.
Note that the whole "expression tree" machinery is not standard-conformant and
will be completely removed separately (under `-fpreview-breaking-changes` flag).
I still want to implement this partial bugfix so that I could switch to a
unified mixin-based implementation for swizzles on `vec`/`swizzle` classes,
instead of doing preprocessor tricks with `swizzles.def` file.1 parent 1876162 commit a863949
File tree
2 files changed
+13
-12
lines changed- sycl
- include/sycl
- test/basic_tests/vectors
2 files changed
+13
-12
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1207 | 1207 | | |
1208 | 1208 | | |
1209 | 1209 | | |
| 1210 | + | |
| 1211 | + | |
| 1212 | + | |
| 1213 | + | |
| 1214 | + | |
| 1215 | + | |
| 1216 | + | |
| 1217 | + | |
| 1218 | + | |
| 1219 | + | |
1210 | 1220 | | |
1211 | 1221 | | |
1212 | 1222 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
5 | | - | |
6 | | - | |
7 | 4 | | |
8 | 5 | | |
9 | 6 | | |
| |||
15 | 12 | | |
16 | 13 | | |
17 | 14 | | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | 15 | | |
22 | | - | |
23 | 16 | | |
24 | 17 | | |
25 | 18 | | |
26 | | - | |
27 | 19 | | |
28 | 20 | | |
29 | 21 | | |
30 | 22 | | |
31 | 23 | | |
32 | 24 | | |
33 | | - | |
34 | 25 | | |
35 | 26 | | |
36 | 27 | | |
37 | | - | |
38 | | - | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
39 | 31 | | |
40 | | - | |
41 | 32 | | |
42 | 33 | | |
43 | 34 | | |
0 commit comments