diff options
Diffstat (limited to 'src/cubetypes.h')
| -rw-r--r-- | src/cubetypes.h | 32 |
1 files changed, 14 insertions, 18 deletions
diff --git a/src/cubetypes.h b/src/cubetypes.h index 9ec8620..3ad960b 100644 --- a/src/cubetypes.h +++ b/src/cubetypes.h | |||
| @@ -81,9 +81,8 @@ typedef struct commandargs CommandArgs; | |||
| 81 | typedef struct coordinate Coordinate; | 81 | typedef struct coordinate Coordinate; |
| 82 | typedef struct cube Cube; | 82 | typedef struct cube Cube; |
| 83 | typedef struct cubearray CubeArray; | 83 | typedef struct cubearray CubeArray; |
| 84 | typedef struct dfsdata DfsData; | 84 | typedef struct dfsarg DfsArg; |
| 85 | typedef struct estimatedata EstimateData; | 85 | typedef struct estimatedata EstimateData; |
| 86 | typedef struct localinfo LocalInfo; | ||
| 87 | typedef struct piecefilter PieceFilter; | 86 | typedef struct piecefilter PieceFilter; |
| 88 | typedef struct prunedata PruneData; | 87 | typedef struct prunedata PruneData; |
| 89 | typedef struct solveoptions SolveOptions; | 88 | typedef struct solveoptions SolveOptions; |
| @@ -94,7 +93,7 @@ typedef struct threaddatagenpt ThreadDataGenpt; | |||
| 94 | 93 | ||
| 95 | typedef Cube (*AntiIndexer) (uint64_t); | 94 | typedef Cube (*AntiIndexer) (uint64_t); |
| 96 | typedef bool (*Checker) (Cube); | 95 | typedef bool (*Checker) (Cube); |
| 97 | typedef int (*Estimator) (EstimateData *); | 96 | typedef int (*Estimator) (DfsArg *); |
| 98 | typedef bool (*Validator) (Alg *); | 97 | typedef bool (*Validator) (Alg *); |
| 99 | typedef void (*Exec) (CommandArgs *); | 98 | typedef void (*Exec) (CommandArgs *); |
| 100 | typedef uint64_t (*Indexer) (Cube); | 99 | typedef uint64_t (*Indexer) (Cube); |
| @@ -198,36 +197,31 @@ cubearray | |||
| 198 | }; | 197 | }; |
| 199 | 198 | ||
| 200 | struct | 199 | struct |
| 201 | dfsdata | 200 | dfsarg |
| 202 | { | 201 | { |
| 202 | Step * step; | ||
| 203 | SolveOptions * opts; | ||
| 204 | Cube cube; | ||
| 205 | Cube inverse; | ||
| 203 | int d; | 206 | int d; |
| 204 | int m; | 207 | uint64_t badmoves; |
| 205 | int lb; | 208 | uint64_t badmovesinv; |
| 206 | bool niss; | 209 | bool niss; |
| 207 | Move last1; | 210 | Move last1; |
| 208 | Move last2; | 211 | Move last2; |
| 212 | Move last1inv; | ||
| 213 | Move last2inv; | ||
| 209 | EstimateData * ed; | 214 | EstimateData * ed; |
| 210 | AlgList * sols; | 215 | AlgList * sols; |
| 211 | pthread_mutex_t * sols_mutex; | 216 | pthread_mutex_t * sols_mutex; |
| 212 | Alg * current_alg; | 217 | Alg * current_alg; |
| 213 | Move * sorted_moves; | 218 | Move * sorted_moves; |
| 214 | int * move_position; | 219 | int * move_position; |
| 215 | uint8_t * visited; | ||
| 216 | }; | 220 | }; |
| 217 | 221 | ||
| 218 | struct | 222 | struct |
| 219 | estimatedata | 223 | estimatedata |
| 220 | { | 224 | { |
| 221 | Cube cube; | ||
| 222 | int target; | ||
| 223 | Move lastmove; | ||
| 224 | uint64_t movebitmask; | ||
| 225 | LocalInfo * li; | ||
| 226 | }; | ||
| 227 | |||
| 228 | struct | ||
| 229 | localinfo | ||
| 230 | { | ||
| 231 | int corners; | 225 | int corners; |
| 232 | int normal_ud; | 226 | int normal_ud; |
| 233 | int normal_fb; | 227 | int normal_fb; |
| @@ -235,7 +229,7 @@ localinfo | |||
| 235 | int inverse_ud; | 229 | int inverse_ud; |
| 236 | int inverse_fb; | 230 | int inverse_fb; |
| 237 | int inverse_rl; | 231 | int inverse_rl; |
| 238 | int prev_ret; | 232 | int oldret; |
| 239 | }; | 233 | }; |
| 240 | 234 | ||
| 241 | struct | 235 | struct |
| @@ -284,6 +278,8 @@ step | |||
| 284 | { | 278 | { |
| 285 | char * shortname; | 279 | char * shortname; |
| 286 | char * name; | 280 | char * name; |
| 281 | bool final; | ||
| 282 | Checker is_done; | ||
| 287 | Estimator estimate; | 283 | Estimator estimate; |
| 288 | Checker ready; | 284 | Checker ready; |
| 289 | char * ready_msg; | 285 | char * ready_msg; |
