diff options
author | Ian Hinder <ian.hinder@aei.mpg.de> | 2013-09-09 18:46:30 +0200 |
---|---|---|
committer | Ian Hinder <ian.hinder@aei.mpg.de> | 2013-09-09 18:46:30 +0200 |
commit | a1a049f9e903c0c73bb474a71573fb026bdc6e3e (patch) | |
tree | e885971d467bfa4f53c1500f684ca973dc42b7ad | |
parent | 492ae490d7b1063a548874910be163e169072764 (diff) |
Interface.m: Move MoL aliased function declarations into MoL.m
-rw-r--r-- | Tools/CodeGen/Interface.m | 20 | ||||
-rw-r--r-- | Tools/CodeGen/MoL.m | 19 |
2 files changed, 21 insertions, 18 deletions
diff --git a/Tools/CodeGen/Interface.m b/Tools/CodeGen/Interface.m index 353e629..6bd36cf 100644 --- a/Tools/CodeGen/Interface.m +++ b/Tools/CodeGen/Interface.m @@ -20,7 +20,7 @@ BeginPackage["Interface`", {"Thorn`", "KrancGroups`", "MapLookup`", "Errors`", "Helpers`", "Kranc`", "CaKernel`", "OpenCL`", - "CodeGenInterface`"}]; + "CodeGenInterface`", "MoL`"}]; CreateKrancInterface; @@ -130,21 +130,6 @@ CreateKrancInterface[nonevolvedGroups_, evolvedGroups_, rhsGroups_, VerifyStringList[inheritedImplementations, "InheritedImplementations"]; VerifyStringList[includeFiles, "IncludeFiles"]; (* These are the aliased functions that are USED by this thorn from other thorns *) - registerEvolved = - { - Name -> "MoLRegisterEvolved", - Type -> "CCTK_INT", - ArgString -> "CCTK_INT IN EvolvedIndex, CCTK_INT IN RHSIndex" - }; - - (* - registerConstrained = - { - Name -> "MoLRegisterConstrained", - Type -> "CCTK_INT", - ArgString -> "CCTK_INT IN ConstrainedIndex" - }; - *) diffCoeff = { @@ -201,8 +186,7 @@ CreateKrancInterface[nonevolvedGroups_, evolvedGroups_, rhsGroups_, If[OptionValue[UseVectors], {"vectors.h"}, {}]], groupStructures, UsesFunctions -> - Join[{registerEvolved, (*registerConstrained,*) - diffCoeff, getMap}, + Join[MoLUsedFunctions[], {diffCoeff, getMap}, CactusBoundary`GetUsedFunctions[]]], {If[OptionValue[UseCaKernel], CaKernelInterfaceCLL[], {}]}]; diff --git a/Tools/CodeGen/MoL.m b/Tools/CodeGen/MoL.m index 1fc829f..83b91fd 100644 --- a/Tools/CodeGen/MoL.m +++ b/Tools/CodeGen/MoL.m @@ -33,6 +33,7 @@ MoLNonevolvedGroups; EvolvedGroupToRHSGroup::usage = ""; MoLRHSGroupDefinitions; MoLRHSODEGroupDefinitions; +MoLUsedFunctions; Begin["`Private`"]; @@ -578,6 +579,24 @@ DefFn[ evolvedODEGroupDefinitions = Map[groupFromName[#, groups] &, evolvedODEGroups]; Map[EvolvedGroupToRHSGroup[#, evolvedODEGroupDefinitions] &, evolvedODEGroups]]]; +DefFn[ + MoLUsedFunctions[] := + { + { + Name -> "MoLRegisterEvolved", + Type -> "CCTK_INT", + ArgString -> "CCTK_INT IN EvolvedIndex, CCTK_INT IN RHSIndex" + } + + (* + { + Name -> "MoLRegisterConstrained", + Type -> "CCTK_INT", + ArgString -> "CCTK_INT IN ConstrainedIndex" + }; + *) + }]; + End[]; EndPackage[]; |