aboutsummaryrefslogtreecommitdiff
path: root/test/test.h
diff options
context:
space:
mode:
authorSebastiano Tronto <sebastiano@tronto.net>2024-04-12 20:22:01 +0200
committerSebastiano Tronto <sebastiano@tronto.net>2024-04-12 20:22:01 +0200
commit72e018b066bd5cc3ce0181b43865a227e8b9b6ec (patch)
tree60b2e8dbe7fd2dd7cf58ecd1606e03146329b516 /test/test.h
downloadcubecore-72e018b066bd5cc3ce0181b43865a227e8b9b6ec.tar.gz
cubecore-72e018b066bd5cc3ce0181b43865a227e8b9b6ec.zip
Initial fork from H48
Diffstat (limited to 'test/test.h')
-rw-r--r--test/test.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/test/test.h b/test/test.h
new file mode 100644
index 0000000..3cbfd10
--- /dev/null
+++ b/test/test.h
@@ -0,0 +1,27 @@
1#include <inttypes.h>
2#include <stdbool.h>
3#include <stdio.h>
4#include <stdlib.h>
5#include <string.h>
6
7#define STRLENMAX 10000
8
9typedef struct {
10 uint8_t corner[8];
11 uint8_t edge[12];
12} cube_t;
13
14#ifdef CUBE_AVX2
15#include <immintrin.h>
16typedef __m256i cube_fast_t;
17#else
18typedef cube_t cube_fast_t;
19#endif
20
21/* Basic functions used in most tests */
22cube_t solvedcube(void);
23bool iserror(cube_t);
24bool issolvable(cube_t);
25bool issolved(cube_t);
26cube_t readcube(char *, char *);
27void writecube(char *, cube_t, char *);

Generated with cgit - Back to sebastiano.tronto.net