1 #include <cstdint>
2
3 struct alignas(16) vec_t {
4 uint64_t a, b;
5 };
6
main()7 int main() {
8 constexpr uint64_t gprs[] = {
9 0x0001020304050607,
10 0x1011121314151617,
11 0x2021222324252627,
12 0x3031323334353637,
13 0x4041424344454647,
14 0x5051525354555657,
15 0x6061626364656667,
16 0x7071727374757677,
17 };
18
19 constexpr vec_t vecs[] = {
20 { 0x0F0E0D0C0B0A0908, 0x1716151413121110, },
21 { 0x100F0E0D0C0B0A09, 0x1817161514131211, },
22 { 0x11100F0E0D0C0B0A, 0x1918171615141312, },
23 { 0x1211100F0E0D0C0B, 0x1A19181716151413, },
24 { 0x131211100F0E0D0C, 0x1B1A191817161514, },
25 { 0x14131211100F0E0D, 0x1C1B1A1918171615, },
26 { 0x1514131211100F0E, 0x1D1C1B1A19181716, },
27 { 0x161514131211100F, 0x1E1D1C1B1A191817, },
28 };
29
30 asm volatile(
31 "ldp x0, x1, [%0]\n\t"
32 "ldp x2, x3, [%0, #16]\n\t"
33 "ldp x4, x5, [%0, #32]\n\t"
34 "ldp x6, x7, [%0, #48]\n\t"
35 "\n\t"
36 "ld1 {v0.2d, v1.2d, v2.2d, v3.2d}, [%1], #64\n\t"
37 "ld1 {v4.2d, v5.2d, v6.2d, v7.2d}, [%1], #64\n\t"
38 "\n\t"
39 "brk #0\n\t"
40 :
41 : "r"(gprs), "r"(vecs)
42 : "x0", "x1", "x2", "x3", "x4", "x5", "x6", "x7",
43 "v0", "v1", "v2", "v3", "v4", "v5", "v6", "v7"
44 );
45
46 return 0;
47 }
48