| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
|
|
|
| |
this adds a function CCTK_ScheduleQueryCurrentFunction which returns the
cFunctionData of the function currently executing via
CCTK_CallScheduledFunction
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4805 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4804 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
| |
forgot to call free() after strdup()
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4802 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4801 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4800 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4799 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Expression are of the form:
foo::bar = 2*sin(foo:baz)
ie. arithmetic and access to already set parameters. The new behaviour is
triggered if the parameter string (for real, boolean and int parameters) does
not parser properly as a double/int/bool. This last test is mostly an
optimization.
The largest change is actually in the expression parser which has been extended
to handle eg. exponential notation and negations. It now uses a state machine
to parse its input.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4797 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4794 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
| |
Set file buffering for stdout (Cactus option -l) after redirecting I/O
(Cactus option -r), so that the buffering applies also for redirected
I/O.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4793 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
| |
This provides support for specifying READS and WRITES clauses for each
function scheduled in schedule.ccl. These list the variables which
the scheduled function reads from or writes to. This supports future
dependency-based scheduling. See
https://docs.einsteintoolkit.org/et-docs/Adding_requirements_to_the_Cactus_scheduler
for more information.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4788 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4777 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
| |
Declare cctkGH as const*, and CCTK_ARGUMENTS as const. This prevents
accidental modifications and allows more optimisations.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4772 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
| |
The table data types (util_Table.h) have internal routines that print
the table contents to screen. This can be helpful for debugging. This
patch makes these functions publicly available.
Add a routine Util_TablePrintPretty that converts a table to a nice,
human-readable string.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4769 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In Fortran, Cactus currently declares grid functions e.g. as (this is
the expansion of DECLARE_CCTK_ARGUMENTS)
REAL*8 gxx (X0metric,X1metric,X2metric)
where X0metric etc. are integers passed into the routine. Each grid
function group has its own, independent size. This has two
disadvantages:
- The compiler does not know that all grid functions have the same
size (namely cctk_lsh), and thus has to perform array index
calculations separately for each group
- The argument list is longer than neded
The enclosed patch declares grid functions via cctk_lsh. Grid arrays
are still declared independently.
This reduces the code size of e.g. GRHydro/GRHydro_Tmunu.F90 from 6836
to 6241 bytes on my system. I have not attempted to measure a
performance difference.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4763 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4731 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
| |
Correct definitions of CCTK_LSSH and CCTK_LSSH_IDX in Fortran. Add
comments.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4722 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4721 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
| |
Check grid point indices in CCTK_GFINDEX3D and friends when CCTK_DEBUG
is defined.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4719 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4716 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
| |
warning. This helps prevent mixing of stdout and stderr when both are
redirected to the same file.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4714 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
| |
Modify the parameter file parser to accept comments in multi-line
strings. These comments extend from a "#" character to the end of the
line. This makes it much easier to comment out variables in output
strings.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4710 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
| |
functions into a new file cctk_ScheduleFunctions.h, which is included
into cctk.h.
This is done only for C (and C++) since Fortran prototypes cannot be
declared at file scope.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4696 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4683 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Correctly load parameter files with DOS line-endings
Before this commit, when a parameter file with DOS line-endings was
used, certain features of Cactus did not work correctly. For example,
setting an output directory of $parfile would create an output
directory named "$parfile" instead of expanding the parameter
filename. This commit converts any CR-LF sequences to LF immediately
after the parameter file is loaded.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4663 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Thorns can specify that they can make use of a particular capability
(for example HDF5), but that it is not absolutely required. It is
currently not possible to detect a capability in the source code or
make system of a thorn because there is no preprocessor macro and no
make variable defined to indicate that the capability is available.
Additionally, the preprocessor definitions which are explicitly
provided by a capability are written to an include file which is
malformed and hence these definitions cannot be read. This commit:
* Introduces makefile and preprocessor variables HAVE_CAPABILITY_<cap>
for each provided capability
* Removes the incorrect definition line causing the include file to be
malformed
* Renames cctki_Capabilities.h to cctk_Capabilities.h and causes
cctk_Capabilities.h to be included from cctk.h by all thorns
* Excludes cctk_Capabilities.h from dependency checking (dependencies
of the files included from this one will be sufficient)
[Patch from Ian Hinder]
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4659 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
| |
Add functions CCTK_VectGF1D, CCTK_VectGF2D etc. and the corresponding
macros CCTK_VECTGFINDEX1D etc. that allow indexing into vector grid
variables. Vector grid variables require an additional index, namely
the vector index; these functions simplify using them.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4654 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
| |
Cactus variables might be unused and should not be reported as such. This closes ET ticket #1
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4651 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4646 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
| |
meaningful error message
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4644 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
| |
modifiers, and some of them apparently allow non-full variable names. My mistake, not corrected.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4639 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
| |
schedule tree, and give corresponding warning message
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4637 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
| |
Cactus does at startup a bit, fixing also some indentation problems.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4620 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4609 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4608 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4607 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4606 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
when the last line is in a comment or in a string, and may overrun the
end of the buffer. The symptoms are error messages past the last line
of the parameter file, because the memory after the buffer end is
interpreted as (probably mal-formed) parameter file content.
Since the paring routine is quite complex, this patch works around
this problem by increasing the size of the buffer by a few characters
and setting these to NUL.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4594 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4593 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
| |
warnings.
Remove the function print_bold_stderr. Use bold_stdout and
bold_stderr instead.
Clean up the way variable argument lists are handled.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4591 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
is consistent with the routines converting Fortran strings to C
strings.
Fortran strings have a fixed length, and trailing white space is
usually ignored. The Cactus routine converting Fortran to C strings
did already ignore trailing white space, but the routine comparing
Fortran and C strings did not. This is now consistent.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4590 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
| |
global_late. These modes can then be used in Carpet, where they will
simplify traversing the schedule tree when local, level, and global
mode routines are mixed.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4589 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
| |
the name of the I/O method, not an IOMethod structure.
Add a new routine CCTK_IOMethod which returns a pointer to the
IOMethod structure describing the I/O method.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4588 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These generalise the LoopControl thorn of Carpet, and introduce a
generic looping mechanism to Cactus. They provides a simple,
straightforward implementation (without the optimisations found in
Carpet's LoopControl thorn), and other thorns can provide various
optimisations, e.g. loop tiling or OpenMP parallelisation.
The macros are defined in a new file cctk_Loop.h, automatically
included from cctk.h. There are macros for 1D, 2D, 3D, and 4D loops,
corresponding to Cactus' CCTK_GFINDEX* macros. Each macro comes in
four variants:
CCTK_LOOP3: a generic 3D loop
CCTK_LOOP3_ALL: loop over all grid points of a grid function
CCTK_LOOP3_INTERIOR: loop over the interior points, excluding
ghost, symmetry, and boundary points
CCTK_LOOP3_BOUNDARY: loop over all (outer) boundary points
The header file contains a straightforward implementation via macros
that expand to corresponding "for" statements.
There are also macros for Fortran, but these are much less elegant
since Fortran does not support block-scope local variables. In
addition, Fortran requires declaring certain variables as private when
OpenMP is used, which adds another complication.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4581 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4576 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
files.
The main changes are:
- when reading a parameter file do not parse the file while reading,
but read it first into a buffer, preprocess that and parse the
buffer after that
- replace the code which changes $parfile into the parameter file
name to use this buffer preprocessing
- replace $ENV{'*'} "defines" by environment variable values (*),
e.g. $ENV{'HOME'} with $HOME.
Frank
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4573 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
| |
so its execution times in different bins can be distinguished.
For multiple calls within the same bin, the accumulated time is reported
only once.
This applies patch http://www.cactuscode.org/old/pipermail/patches/2009-April/000258.html.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4557 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
| |
(patch http://www.cactuscode.org/old/pipermail/patches/2009-February/000256.html)
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4552 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4517 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4511 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4509 17b73243-c579-4c4c-a9d2-2d5706c11dac
|