diff --git a/python/dune/perftool/options.py b/python/dune/perftool/options.py index 6c7da068ea0cf8e87eaeb89fd030c920d59a886f..bc96b7d728dd957f6399a68ba22afe04b2edc4da 100644 --- a/python/dune/perftool/options.py +++ b/python/dune/perftool/options.py @@ -36,23 +36,33 @@ class PerftoolOptionsArray(ImmutableRecord): uflfile = PerftoolOption(helpstr="the UFL file to compile") debug_cache_with_stack = PerftoolOption(default=False, helpstr="Store stack along with cache objects. Makes debugging caching issues easier.") driver_file = PerftoolOption(helpstr="The filename for the generated driver header") - operator_file = PerftoolOption(helpstr="The filename for the generated local operator header") - numerical_jacobian = PerftoolOption(default=False, helpstr="use numerical jacobians (only makes sense, if uflpdelab for some reason fails to generate analytic jacobians)") - matrix_free = PerftoolOption(default=False, helpstr="Use iterative solver with matrix free jacobian application") explicit_time_stepping = PerftoolOption(default=False, helpstr="use explicit time stepping") exact_solution_expression = PerftoolOption(helpstr="name of the exact solution expression in the ufl file") compare_l2errorsquared = PerftoolOption(helpstr="maximal allowed l2 error squared of difference between numerical solution and interpolation of exact solution (NOTE: requires --exact-solution-expression)") l2error_tree_path = PerftoolOption(default=None, helpstr="Tree pathes that should be considered for l2 error calculation. Default None means we take all of them into account.") - print_transformations = PerftoolOption(default=False, helpstr="print out dot files after ufl tree transformations") - print_transformations_dir = PerftoolOption(default=".", helpstr="place where to put dot files (can be omitted)") - quadrature_order = PerftoolOption(_type=int, helpstr="Quadrature order used for all integrals.") - diagonal_transformation_matrix = PerftoolOption(default=False, helpstr="set option if the jacobian of the transformation is diagonal (axiparallel grids)") - constant_transformation_matrix = PerftoolOption(default=False, helpstr="set option if the jacobian of the transformation is constant on a cell") ini_file = PerftoolOption(helpstr="An inifile to use. A generated driver will be hard-coded to it, a [formcompiler] section will be used as default values to form compiler arguments (use snake case)") opcounter = PerftoolOption(default=False, helpstr="Count operations. Note: In this case only operator applications are generated since solving and operator counting does not work. You probably want to set instrumentation level>0.") performance_measuring = PerftoolOption(default=False, helpstr="Generate opcounter codepath, but only measure times!") instrumentation_level = PerftoolOption(default=0, helpstr="Control time/opcounter measurements. 0-do nothing, 1-measure program as a whole, 2-operator applications, 3-measure kernel (eg. alpha-volume, ...), 4-parts of kernel (eg. stage 1-3 of SF)") project_basedir = PerftoolOption(helpstr="The base (build) directory of the dune-perftool project") + architecture = PerftoolOption(default="haswell", helpstr="The architecture to optimize for. Possible values: haswell|knl|skylake") + yaspgrid_offset = PerftoolOption(default=False, helpstr="Set to true if you want a yasp grid where the lower left corner is not in the origin.") + precision_bits = PerftoolOption(default=64, helpstr="The number of bits for the floating point type") + overlapping = PerftoolOption(default=False, helpstr="Use an overlapping solver and constraints. You still need to make sure to construct a grid with overlap! The parallel option will be set automatically.") + + # Arguments that are mainly to be set by logic depending on other options + max_vector_width = PerftoolOption(default=256, helpstr=None) + parallel = PerftoolOption(default=False, helpstr="Mark that this program should be run in parallel. If set to true the c++ code will check that there are more than 1 MPI-ranks involved and the error computation will use communication.") + + # Form specific options + operator_file = PerftoolOption(helpstr="The filename for the generated local operator header") + numerical_jacobian = PerftoolOption(default=False, helpstr="use numerical jacobians (only makes sense, if uflpdelab for some reason fails to generate analytic jacobians)") + matrix_free = PerftoolOption(default=False, helpstr="Use iterative solver with matrix free jacobian application") + print_transformations = PerftoolOption(default=False, helpstr="print out dot files after ufl tree transformations") + print_transformations_dir = PerftoolOption(default=".", helpstr="place where to put dot files (can be omitted)") + quadrature_order = PerftoolOption(_type=int, helpstr="Quadrature order used for all integrals.") + diagonal_transformation_matrix = PerftoolOption(default=False, helpstr="set option if the jacobian of the transformation is diagonal (axiparallel grids)") + constant_transformation_matrix = PerftoolOption(default=False, helpstr="set option if the jacobian of the transformation is constant on a cell") fastdg = PerftoolOption(default=False, helpstr="Use FastDGGridOperator from PDELab.") sumfact = PerftoolOption(default=False, helpstr="Use sumfactorization") vectorization_quadloop = PerftoolOption(default=False, helpstr="whether to generate code with explicit vectorization") @@ -62,21 +72,14 @@ class PerftoolOptionsArray(ImmutableRecord): vectorization_padding = PerftoolOption(default=None, helpstr="an explicit value for the allowed padding in vectorization") vectorization_allow_quadrature_changes = PerftoolOption(default=False, helpstr="whether the vectorization strategy is allowed to alter quadrature point numbers") vectorization_list_index = PerftoolOption(default=None, helpstr="Which vectorization to pick from a list (only valid with vectorization_strategy=fromlist).") - architecture = PerftoolOption(default="haswell", helpstr="The architecture to optimize for. Possible values: haswell|knl|skylake") - yaspgrid_offset = PerftoolOption(default=False, helpstr="Set to true if you want a yasp grid where the lower left corner is not in the origin.") simplify = PerftoolOption(default=False, helpstr="Whether to simplify expressions using sympy") - precision_bits = PerftoolOption(default=64, helpstr="The number of bits for the floating point type") assure_statement_ordering = PerftoolOption(default=False, helpstr="Whether special care should be taken for a good statement ordering in sumfact kernels, runs into a loopy scheduler performance bug, but is necessary for production.") generate_jacobians = PerftoolOption(default=True, helpstr="Whether jacobian_* methods should be generated. This is set to false automatically, when numerical_jacobian is set to true.") - - # Arguments that are mainly to be set by logic depending on other options - max_vector_width = PerftoolOption(default=256, helpstr=None) unroll_dimension_loops = PerftoolOption(default=False, helpstr="whether loops over the geometric dimension should be unrolled") precompute_quadrature_info = PerftoolOption(default=True, helpstr="compute quadrature points and weights in the constructor of the local operator") blockstructured = PerftoolOption(default=False, helpstr="Use block structure") number_of_blocks = PerftoolOption(default=1, helpstr="Number of sub blocks in one direction") - overlapping = PerftoolOption(default=False, helpstr="Use an overlapping solver and constraints. You still need to make sure to construct a grid with overlap! The parallel option will be set automatically.") - parallel = PerftoolOption(default=False, helpstr="Mark that this program should be run in parallel. If set to true the c++ code will check that there are more than 1 MPI-ranks involved and the error computation will use communication.") + # Until more sophisticated logic is needed, we keep the actual option data in this module _options = PerftoolOptionsArray()