summaryrefslogtreecommitdiff
path: root/src/main/SetupCache.c
diff options
context:
space:
mode:
authorallen <allen@17b73243-c579-4c4c-a9d2-2d5706c11dac>2000-06-20 09:10:51 +0000
committerallen <allen@17b73243-c579-4c4c-a9d2-2d5706c11dac>2000-06-20 09:10:51 +0000
commita21b899e4f32882635fb5cf58bfb4d36b055d0cf (patch)
treeac2cf5d05865273daf7081c413b5c53cf3c01c0e /src/main/SetupCache.c
parente54585413368a76ad565df6fac4dacb3d2fbea98 (diff)
Using ParameterGet
git-svn-id: http://svn.cactuscode.org/flesh/trunk@1684 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'src/main/SetupCache.c')
-rw-r--r--src/main/SetupCache.c17
1 files changed, 12 insertions, 5 deletions
diff --git a/src/main/SetupCache.c b/src/main/SetupCache.c
index 0d061b88..f99a2254 100644
--- a/src/main/SetupCache.c
+++ b/src/main/SetupCache.c
@@ -11,8 +11,9 @@
#include "cctk_Config.h"
#include "cctk_Flesh.h"
+#include "cctk_Parameter.h"
+
#include "cctki_Cache.h"
-#include "cctk_Parameters.h"
static char *rcsid = "$Header$";
@@ -43,16 +44,22 @@ CCTK_FILEVERSION(main_SetupCache_c)
@@*/
int CCTKi_SetupCache(void)
{
- DECLARE_CCTK_PARAMETERS
+ int param_type;
+ int manual_cache_setup;
unsigned long cache_size;
unsigned long cacheline_bytes;
+ manual_cache_setup = (*(int *)CCTK_ParameterGet("manual_cache_setup",
+ "Cactus",&param_type));
+
if(manual_cache_setup)
{
- cache_size = manual_cache_size;
- cacheline_bytes = manual_cacheline_bytes;
- }
+ cache_size = (*(int *)CCTK_ParameterGet("manual_cache_size",
+ "Cactus",&param_type));
+ cacheline_bytes = (*(int *)CCTK_ParameterGet("manual_cacheline_bytes",
+ "Cactus",&param_type));
+ }
else
{
/* FIXME: Remove this check for release */