aboutsummaryrefslogtreecommitdiff
path: root/src/arch
diff options
context:
space:
mode:
Diffstat (limited to 'src/arch')
-rw-r--r--src/arch/avx2.h8
-rw-r--r--src/arch/common.h8
-rw-r--r--src/arch/neon.h8
-rw-r--r--src/arch/portable.h8
4 files changed, 16 insertions, 16 deletions
diff --git a/src/arch/avx2.h b/src/arch/avx2.h
index b6ff510..ebcf84f 100644
--- a/src/arch/avx2.h
+++ b/src/arch/avx2.h
@@ -23,7 +23,7 @@ popcount_u32(uint32_t x)
23} 23}
24 24
25STATIC void 25STATIC void
26pieces(cube_t *cube, uint8_t c[static 8], uint8_t e[static 12]) 26pieces(cube_t cube[static 1], uint8_t c[static 8], uint8_t e[static 12])
27{ 27{
28 uint8_t aux[32]; 28 uint8_t aux[32];
29 29
@@ -252,19 +252,19 @@ coord_esep(cube_t c)
252} 252}
253 253
254STATIC_INLINE void 254STATIC_INLINE void
255copy_corners(cube_t *dest, cube_t src) 255copy_corners(cube_t dest[static 1], cube_t src)
256{ 256{
257 *dest = _mm256_blend_epi32(*dest, src, 0x0F); 257 *dest = _mm256_blend_epi32(*dest, src, 0x0F);
258} 258}
259 259
260STATIC_INLINE void 260STATIC_INLINE void
261copy_edges(cube_t *dest, cube_t src) 261copy_edges(cube_t dest[static 1], cube_t src)
262{ 262{
263 *dest = _mm256_blend_epi32(*dest, src, 0xF0); 263 *dest = _mm256_blend_epi32(*dest, src, 0xF0);
264} 264}
265 265
266STATIC_INLINE void 266STATIC_INLINE void
267set_eo(cube_t *cube, int64_t eo) 267set_eo(cube_t cube[static 1], int64_t eo)
268{ 268{
269 int64_t eo12, eotop, eobot; 269 int64_t eo12, eotop, eobot;
270 __m256i veo; 270 __m256i veo;
diff --git a/src/arch/common.h b/src/arch/common.h
index 52e0fc7..5c1efde 100644
--- a/src/arch/common.h
+++ b/src/arch/common.h
@@ -1,6 +1,6 @@
1STATIC_INLINE int popcount_u32(uint32_t); 1STATIC_INLINE int popcount_u32(uint32_t);
2 2
3STATIC void pieces(cube_t *, uint8_t [static 8], uint8_t [static 12]); 3STATIC void pieces(cube_t [static 1], uint8_t [static 8], uint8_t [static 12]);
4STATIC_INLINE bool equal(cube_t, cube_t); 4STATIC_INLINE bool equal(cube_t, cube_t);
5STATIC_INLINE cube_t invertco(cube_t); 5STATIC_INLINE cube_t invertco(cube_t);
6STATIC_INLINE cube_t compose_edges(cube_t, cube_t); 6STATIC_INLINE cube_t compose_edges(cube_t, cube_t);
@@ -14,9 +14,9 @@ STATIC_INLINE int64_t coord_cocsep(cube_t);
14STATIC_INLINE int64_t coord_eo(cube_t); 14STATIC_INLINE int64_t coord_eo(cube_t);
15STATIC_INLINE int64_t coord_esep(cube_t); 15STATIC_INLINE int64_t coord_esep(cube_t);
16 16
17STATIC_INLINE void copy_corners(cube_t *, cube_t); 17STATIC_INLINE void copy_corners(cube_t [static 1], cube_t);
18STATIC_INLINE void copy_edges(cube_t *, cube_t); 18STATIC_INLINE void copy_edges(cube_t [static 1], cube_t);
19STATIC_INLINE void set_eo(cube_t *, int64_t); 19STATIC_INLINE void set_eo(cube_t [static 1], int64_t);
20STATIC_INLINE cube_t invcoord_esep(int64_t); 20STATIC_INLINE cube_t invcoord_esep(int64_t);
21 21
22STATIC_INLINE void invcoord_esep_array(int64_t, int64_t, uint8_t[static 12]); 22STATIC_INLINE void invcoord_esep_array(int64_t, int64_t, uint8_t[static 12]);
diff --git a/src/arch/neon.h b/src/arch/neon.h
index 19f6f9d..d5f5f8b 100644
--- a/src/arch/neon.h
+++ b/src/arch/neon.h
@@ -39,7 +39,7 @@ popcount_u32(uint32_t x)
39} 39}
40 40
41STATIC void 41STATIC void
42pieces(cube_t *cube, uint8_t c[static 8], uint8_t e[static 12]) 42pieces(cube_t cube[static 1], uint8_t c[static 8], uint8_t e[static 12])
43{ 43{
44 // First 8 bytes of the corner vector are copied from the c array 44 // First 8 bytes of the corner vector are copied from the c array
45 vst1_u8(c, cube->corner); 45 vst1_u8(c, cube->corner);
@@ -287,19 +287,19 @@ coord_esep(cube_t c)
287} 287}
288 288
289STATIC_INLINE void 289STATIC_INLINE void
290copy_corners(cube_t *dst, cube_t src) 290copy_corners(cube_t dst[static 1], cube_t src)
291{ 291{
292 dst->corner = src.corner; 292 dst->corner = src.corner;
293} 293}
294 294
295STATIC_INLINE void 295STATIC_INLINE void
296copy_edges(cube_t *dst, cube_t src) 296copy_edges(cube_t dst[static 1], cube_t src)
297{ 297{
298 dst->edge = src.edge; 298 dst->edge = src.edge;
299} 299}
300 300
301STATIC_INLINE void 301STATIC_INLINE void
302set_eo(cube_t *cube, int64_t eo) 302set_eo(cube_t cube[static 1], int64_t eo)
303{ 303{
304 // Temp array to store the NEON vector 304 // Temp array to store the NEON vector
305 uint8_t mem[16]; 305 uint8_t mem[16];
diff --git a/src/arch/portable.h b/src/arch/portable.h
index b8c5211..4ac5fe7 100644
--- a/src/arch/portable.h
+++ b/src/arch/portable.h
@@ -22,7 +22,7 @@ popcount_u32(uint32_t x)
22} 22}
23 23
24STATIC void 24STATIC void
25pieces(cube_t *cube, uint8_t c[static 8], uint8_t e[static 12]) 25pieces(cube_t cube[static 1], uint8_t c[static 8], uint8_t e[static 12])
26{ 26{
27 memcpy(c, cube->corner, 8); 27 memcpy(c, cube->corner, 8);
28 memcpy(e, cube->edge, 12); 28 memcpy(e, cube->edge, 12);
@@ -227,19 +227,19 @@ coord_esep(cube_t c)
227} 227}
228 228
229STATIC_INLINE void 229STATIC_INLINE void
230copy_corners(cube_t *dest, cube_t src) 230copy_corners(cube_t dest[static 1], cube_t src)
231{ 231{
232 memcpy(&dest->corner, src.corner, sizeof(src.corner)); 232 memcpy(&dest->corner, src.corner, sizeof(src.corner));
233} 233}
234 234
235STATIC_INLINE void 235STATIC_INLINE void
236copy_edges(cube_t *dest, cube_t src) 236copy_edges(cube_t dest[static 1], cube_t src)
237{ 237{
238 memcpy(&dest->edge, src.edge, sizeof(src.edge)); 238 memcpy(&dest->edge, src.edge, sizeof(src.edge));
239} 239}
240 240
241STATIC_INLINE void 241STATIC_INLINE void
242set_eo(cube_t *cube, int64_t eo) 242set_eo(cube_t cube[static 1], int64_t eo)
243{ 243{
244 uint8_t i, sum, flip; 244 uint8_t i, sum, flip;
245 245

Generated with cgit - Back to sebastiano.tronto.net