diff options
author | hinder <hinder@105869f7-3296-0410-a4ea-f4349344b45a> | 2011-06-16 20:57:52 +0000 |
---|---|---|
committer | hinder <hinder@105869f7-3296-0410-a4ea-f4349344b45a> | 2011-06-16 20:57:52 +0000 |
commit | a8dd909e99aa25fe697e46fee37c0cf48f087488 (patch) | |
tree | f1d10318f6aa479c204f792071e241cb15f75d1b | |
parent | 2ab4d61cd4b632c0e991c781f3c15f3b054d1bbd (diff) |
Add startup message giving vector length
This allows you to check that a simulation is using vectorisation.
git-svn-id: https://svn.cct.lsu.edu/repos/numrel/LSUThorns/Vectors/trunk@11 105869f7-3296-0410-a4ea-f4349344b45a
-rw-r--r-- | configuration.ccl | 2 | ||||
-rw-r--r-- | schedule.ccl | 5 | ||||
-rw-r--r-- | src/make.code.defn | 2 | ||||
-rw-r--r-- | src/vectors.c | 11 |
4 files changed, 19 insertions, 1 deletions
diff --git a/configuration.ccl b/configuration.ccl index 54500d7..9468abc 100644 --- a/configuration.ccl +++ b/configuration.ccl @@ -13,3 +13,5 @@ PROVIDES Vectors VECTORISE_STREAMING_STORES \ VECTORISE_EMULATE_AVX } + +REQUIRES Vectors diff --git a/schedule.ccl b/schedule.ccl index 2f68b01..7da984f 100644 --- a/schedule.ccl +++ b/schedule.ccl @@ -1 +1,6 @@ # Schedule definitions for thorn Vectors + +schedule Vectors_Startup at CCTK_STARTUP +{ + LANG: C +} "Print startup message" diff --git a/src/make.code.defn b/src/make.code.defn index fa10ccb..15ba9a9 100644 --- a/src/make.code.defn +++ b/src/make.code.defn @@ -1,7 +1,7 @@ # Main make.code.defn file for thorn Vectors # Source files in this directory -SRCS = +SRCS = vectors.c # Subdirectories containing source files SUBDIRS = diff --git a/src/vectors.c b/src/vectors.c new file mode 100644 index 0000000..04df73c --- /dev/null +++ b/src/vectors.c @@ -0,0 +1,11 @@ + +#include "cctk.h" +#include "cctk_Arguments.h" +#include "cctk_Parameters.h" +#include "vectors.h" + +int Vectors_Startup(void) +{ + CCTK_VInfo(CCTK_THORNSTRING, "Using vector size %d", CCTK_REAL_VEC_SIZE); + return 0; +} |