aboutsummaryrefslogtreecommitdiff
path: root/Tools/CodeGen/CalculationFunction.m
Commit message (Collapse)AuthorAge
* CalculationFunction.m: Eliminate t magicIan Hinder2012-01-27
| | | | We don't need to replace t -> cctk_time any more, because we define t as a constant.
* Factor out InitFDVariablesIan Hinder2012-01-26
| | | This means it can be different for CaKernel
* Move SetDataType to Thorn.m and CaKernel.mIan Hinder2012-01-26
|
* Remove unused DeclareFDVariablesIan Hinder2012-01-26
|
* Factor out gridfunction access (phi[index]) functionIan Hinder2012-01-25
|
* Factor out looping function and make it a member function of a calculationIan Hinder2012-01-25
|
* CalculationFunction.m: Make the generation of a "caller" function dependent ↵Ian Hinder2012-01-24
| | | | | on a calculation member variable The "caller" function is the one that is actually scheduled (in the C case) and which calls the looping function with the body function as argument. This separation is not needed for all targets, so make it optional.
* Pull out the generation of the calculation body function definition into a ↵Ian Hinder2012-01-24
| | | | | calculation member function This allows it to be customized based on the target type.
* Tidy up argument passing for calculation and source file generationIan Hinder2012-01-24
|
* Merge branch 'hydro'Ian Hinder2012-01-22
|\ | | | | | | | | | | | | | | | | | | Conflicts: Auxiliary/Cactus/KrancNumericalTools/GenericFD/src/MathematicaCompat.h Examples/kranc.th Tools/CodeGen/Kranc.m Tools/CodeGen/KrancTensor.m Tools/CodeGen/Schedule.m Tools/CodeGen/Thorn.m
| * Merge remote-tracking branch 'origin/master' into hydroIan Hinder2011-06-03
| |\
| * | CalculationFunction.m: Add function GridFunctionsInExpressionIan Hinder2010-10-01
| | |
| * | CalculationFunction.m: Export the calculationSymbols functionIan Hinder2010-10-01
| | |
* | | use CCTK_LOOP3 for simple loops, make dependency on LoopControl optionalRoland Haas2012-01-10
| | | | | | | | | | | | for non-vectorized codes
* | | Relax variable checking to allow variables to be expressed as strings ↵Ian Hinder2011-12-20
| | | | | | | | | | | | | | | instead of symbols Using Mathematica strings for variable names makes it possible to access variables with names containing underscores from other thorns.
* | | CalculationFunction.m: Check that derivatives are not used in calculations ↵Ian Hinder2011-11-29
| | | | | | | | | | | | | | | | | | with Where -> Everywhere This is the default, and would lead to operators which read off the edge of the grid.
* | | Don't output full equations in InfoFull mode when simplifyingIan Hinder2011-11-19
| | |
* | | Add some debugging code (disabled by default)Ian Hinder2011-11-14
| | |
* | | Skip factorisation if NoSimplify has been specified for a calculationIan Hinder2011-11-14
| | | | | | | | | The factoring of complex expressions is very slow. In one case, skipping the factoring reduced thorn-generation time from 90 minutes to 40 seconds.
* | | Add ability to evolve ODEs in calculationsHal Finkel2011-11-01
| | |
* | | CalculationFunction.m: Correct argument order for CheckStencilIan Hinder2011-10-28
| | |
* | | CalculationFunction.m: Improve output of list verification error messageIan Hinder2011-10-28
| | |
* | | CalculationFunction.m: Add explicit profiling to Simplify operationIan Hinder2011-10-28
| | |
* | | CalculationFunction.m: Use DefFn for two important functionsIan Hinder2011-10-28
| | |
* | | Make ZeroDimensions work againIan Hinder2011-10-28
| | |
* | | Split CodeGen.m into CodeGen.m, CodeGenC.m and CodeGenCactus.mIan Hinder2011-10-07
| | | | | | | | | | | | | | | | | | | | | - CodeGenC.m still contains Fortran variants. These might be moved into CodeGenFortran.m. - Several other modules essentially need to pull in all three packages due to newly broken abstraction barriers. This can be fixed incrementally. - Indent and format all three files consistently
* | | Add support for generating OpenCL codeErik Schnetter2011-09-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This must be enabled via an option UseOpenCL->True, similar to vectorisation. * When generating code for a calculation, stringify the kernel and call the OpenCL run time, when OpenCL code should be generated. * Stringify Differencing.h when OpenCL is used. * Move certain function calls out of the body of the generated code and into the wrapper, e.g. screen output and checking whether grid functions have memory.
* | | Use imin and imax instead of min and max as formal argument names for loop ↵Erik Schnetter2011-09-29
| | | | | | | | | | | | body functions
* | | Make dt (CCTK_DELTA_TIME) available in calculations.Erik Schnetter2011-09-29
| | |
* | | Enable selection of finite difference operators using run-time parametersIan Hinder2011-09-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Partial derivative definitions can now depend on Mathematica variables corresponding to parameters defined in IntParameters. These parameters should be defined with an AllowedValues -> {1, 2, 3, …} entry. Derivative operators are created for all possible values of the parameter. At run-time, a switch statement in the grid function loop selects which set of operators are used. Only one parameter can currently be used.
* | | Add Scalar[] which can be used to prevent vectorisation and use it for tests ↵Barry Wardell2011-06-19
| | | | | | | | | | | | in conditionals. Also add a couple more simplification rules for the vectorisation.
* | | CalculationFunction.m: Re-implement collection of sequential IfThen ↵Barry Wardell2011-06-19
| | | | | | | | | | | | expressions in more straightforward way.
* | | Improve handling of ToReal and parameters in conditionalsIan Hinder2011-06-11
| |/ |/|
* | Check stencil widths for each calculationIan Hinder2011-05-27
| |
* | Correct vectorisation errors recently introducedErik Schnetter2011-05-27
| | | | | | | | | | | | | | | | | | | | | | | | (1) vec_load cannot be used on constants, it can only be used to access array elements. Replacing UseVectors by False is just a band aid. vec_load was attached to a routine defining and setting a variable; really, it should be attached to a routine accessing array elements, but Kranc doesn't use such an abstraction yet.(2) ToReal is introduced, but must be removed again for integer expressions such as the conditions controlling if statements. I added band-aid code to Conditional[] to remove it. The vectorization routines already handle IfThen, Pow etc., but Conditional isn't visible to them.
* | Vectorisation correction for vector sizes > 2Erik Schnetter2011-05-27
| | | | | | | | | | Correct the vectorisation code for vector sizes >2 when the array size is smaller than the vector size
* | CalculationFunction.m: Tidy up assignment of local variables for gridfunctionsIan Hinder2011-05-25
| | | | | | Make a general mechanism for ensuring that certain grid functions are not accessed based on a condition. This mechanism is only used internally at the moment, but can be extended later to the user level.
* | CalculationFunction.m: Collect sequential IfThen expressionsIan Hinder2011-05-25
| | | | | | | | If multiple sequential IfThen expressions appear at the head of the RHS of a set of equations with the same condition, they are now pulled out into a separate if(){...} statement.
* | CalculationFunction.m: Correct debugging codeIan Hinder2011-05-20
| |
* | Add support for a Jacobian to be applied to all derivativesIan Hinder2011-05-20
| |
* | Improved common subexpression elimination support.Barry Wardell2011-03-16
| |
* | Only vectorise FD variables and macros when UseVectors is setIan Hinder2011-01-22
| |
* | Only vectorise when converting local variables if UseVectors is setIan Hinder2011-01-22
| |
* | Use DataType function for CCTK_REAL / CCTK_REAL_VECIan Hinder2011-01-22
| |
* | Only vectorise in ReplacePowers if UseVectors is setIan Hinder2011-01-22
| |
* | Use ptrdiff_t instead of int for indices; this avoids many 32-to-64-bit ↵Erik Schnetter2010-12-23
| | | | | | | | | | | | conversions and thus generates faster code. Correct code generation for static functions that evaluate the derivative operators.
* | Merge master into vectorIan Hinder2010-12-06
|\ \
| * | Ignore certain groups when checking for storageIan Hinder2010-12-01
| | | | | | | | | | | | There are currently some McLachlan-specific group names hard-coded into Kranc which are only accessed based on a grid scalar predicate. This commit takes these into account by ignoring them when checking for storage.
| * | Check group storageIan Hinder2010-12-01
| |/
* | Implement vectorisationIan Hinder2010-11-23
| | | | | | | | This is Erik's vectorisation working tree from 13-Oct-2010