5 #include <isl/options.h>
7 struct ppcg_debug_options
{
8 int dump_schedule_constraints
;
10 int dump_final_schedule
;
16 struct isl_options
*isl
;
17 struct ppcg_debug_options
*debug
;
19 /* Group chains of consecutive statements before scheduling. */
22 /* Use isl to compute a schedule replacing the original schedule. */
27 /* Assume all parameters are non-negative. */
28 int non_negative_parameters
;
32 /* Perform tiling (C target). */
36 /* Isolate full tiles from partial tiles. */
37 int isolate_full_tiles
;
39 /* Take advantage of private memory. */
40 int use_private_memory
;
42 /* Take advantage of shared memory. */
43 int use_shared_memory
;
45 /* Maximal amount of shared memory. */
46 int max_shared_memory
;
48 /* The target we generate code for. */
51 /* Generate OpenMP macros (C target only). */
54 /* Linearize all device arrays. */
55 int linearize_device_arrays
;
57 /* Allow the use of GNU extensions in generated code. */
58 int allow_gnu_extensions
;
60 /* Allow live range to be reordered. */
61 int live_range_reordering
;
63 /* Allow hybrid tiling whenever a suitable input pattern is found. */
66 /* Unroll the code for copying to/from shared memory. */
67 int unroll_copy_shared
;
68 /* Unroll code inside tile on GPU targets. */
71 /* Options to pass to the OpenCL compiler. */
72 char *opencl_compiler_options
;
73 /* Prefer GPU device over CPU. */
75 /* Number of files to include. */
76 int opencl_n_include_file
;
77 /* Files to include. */
78 const char **opencl_include_files
;
79 /* Print definitions of types in kernels. */
80 int opencl_print_kernel_types
;
81 /* Embed OpenCL kernel code in host code. */
82 int opencl_embed_kernel_code
;
84 /* Name of file for saving isl computed schedule or NULL. */
85 char *save_schedule_file
;
86 /* Name of file for loading schedule or NULL. */
87 char *load_schedule_file
;
90 ISL_ARG_DECL(ppcg_debug_options
, struct ppcg_debug_options
,
91 ppcg_debug_options_args
)
92 ISL_ARG_DECL(ppcg_options
, struct ppcg_options
, ppcg_options_args
)
94 #define PPCG_TARGET_C 0
95 #define PPCG_TARGET_CUDA 1
96 #define PPCG_TARGET_OPENCL 2
98 void ppcg_options_set_target_defaults(struct ppcg_options
*options
);