34 lines
865 B
C++
34 lines
865 B
C++
#ifndef _paras_hpp_INCLUDED
|
|
#define _paras_hpp_INCLUDED
|
|
|
|
#include <cstring>
|
|
#include <unordered_map>
|
|
|
|
// name, type, default, low, high, comments
|
|
#define PARAS \
|
|
PARA( mode , int , 0 , 0 , 2 , "SAT=1, UNSAT=2") \
|
|
PARA( simplify , int , 1 , 0 , 1 , "Use Simplify(only preprocess)") \
|
|
PARA( times , double , 5000 , 0 , 1e8 , "Cutoff time") \
|
|
PARA( threads , int , 32 , 1 , 128 , "Thread number") \
|
|
|
|
|
|
struct paras
|
|
{
|
|
#define PARA(N, T, D, L, H, C) \
|
|
T N = D;
|
|
PARAS
|
|
#undef PARA
|
|
|
|
std::unordered_map<std::string, int> map_int;
|
|
std::unordered_map<std::string, double> map_double;
|
|
|
|
void init_paras ();
|
|
void sync_paras ();
|
|
void print_change ();
|
|
void set_para (char *arg, int val);
|
|
void set_para (char *arg, double val);
|
|
};
|
|
|
|
#define OPT(N) (opt->N)
|
|
|
|
#endif |