util.c: compress_variables: declare variable at start of code block.
[barvinok.git] / options.c
blob98a4e25d0653eddb4a96f94a8c504d3bdc35d438
1 #include <unistd.h>
2 #include <polylib/polylibgmp.h>
3 #include <barvinok/options.h>
4 #include <barvinok/util.h>
5 #include "config.h"
7 #ifdef HAVE_GROWING_CHERNIKOVA
8 #define MAXRAYS (POL_NO_DUAL | POL_INTEGER)
9 #else
10 #define MAXRAYS 600
11 #endif
13 #define ALLOC(type) (type*)malloc(sizeof(type))
15 struct barvinok_options *barvinok_options_new_with_defaults()
17 struct barvinok_options *options = ALLOC(struct barvinok_options);
18 if (!options)
19 return NULL;
21 options->MaxRays = MAXRAYS;
23 #ifdef USE_INCREMENTAL_BF
24 options->incremental_specialization = 2;
25 #elif defined USE_INCREMENTAL_DF
26 options->incremental_specialization = 1;
27 #else
28 options->incremental_specialization = 0;
29 #endif
31 options->emptiness_check = 1;
33 return options;