aboutsummaryrefslogtreecommitdiff
path: root/src/cube.c
blob: 97f7844d2f72955805a13d03dc675e4ef5925ada (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#include <inttypes.h>
#include <stdbool.h>
#include <string.h>

#ifdef DEBUG
#include <stdio.h>
#define _static
#define _static_inline
#define DBG_LOG(...) fprintf(stderr, __VA_ARGS__)
#define DBG_WARN(condition, ...) if (!(condition)) DBG_LOG(__VA_ARGS__);
#define DBG_ASSERT(condition, retval, ...) \
    if (!(condition)) { DBG_LOG(__VA_ARGS__); return retval; }

#else
#define _static static
#define _static_inline static inline
#define DBG_LOG(...)
#define DBG_WARN(condition, ...)
#define DBG_ASSERT(condition, retval, ...)
#endif

#include "constants.h"

#if defined(CUBE_AVX2)
#include <immintrin.h>
#include "cube_avx2.h"
#elif defined(CUBE_NEON)
#include "cube_neon.h"
#else
#include <stdlib.h> /* TODO: check if can be removed */
#include "cube_portable.h"
#endif

#include "io_move_trans.h"
#include "constant_cubes.h"
#include "cube_generic.h"
#include "io_cube.h"

/* TODO: work in progress */
#if 0
#include "constant_cubes_transform.h"
#include "cube_transform.h"
#else
#include "cube_transform_with_switch.h"
#endif

#include "moves.h"
#include "solve_h48.h"
#include "solve_generic.h"

#include "cube_public.h"

Generated with cgit - Back to sebastiano.tronto.net