| Commit message (Collapse) | Author | Age |
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@5030 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Map CCTK_COMPLEX to "double complex" in C, and "complex<double>" in
C++. (It is already mapped to "double complex" in Fortran.)
Update type definitions.
Re-implement Cactus complex number math functions by calling the
respective C functions.
Update thorn that access real and imaginary parts of complex numbers
to use standard-conforming methods instead.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4979 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
| |
(2) Disallow setting multiple parameters on one line
(3) Allow sign in floating point format to be optional
(4) Use package piraha
(5) change PirahaParser to cctk_PirahaParser
(6) remove size.py
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4966 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4960 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
| |
data is a pointer to user-supplied data used for evaluating the expression. It should not be modified by the evaluation. Note that this modifies the flesh API to the (undocumented) thorn-visible function Util_ExpressionEvaluate.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4922 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
| |
fread takes an "item size" and a "number of items" and returns the number of items successfully read. Previously, we asked for 1 item of the size of the file, to read the entire file. The error check which was added in r4915 assumed that the returned value of fread was the number of bytes read, which is not correct since only one item is returned, and causes Cactus to fail with a fatal error when any parameter file is loaded. The present commit changes the fread call to ask for file_size items of size 1, for which the error-checking code makes sense, as there are now file_size items returned.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4917 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4915 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4914 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4892 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
| |
These functions return whether a Cactus timer is running or not (either by name or by handle).
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4890 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
| |
Starting a running timer and stopping a not running timer will produce a level 1 warning and will otherwise do nothing (will not actually start/stop twice). This fixes the issue at hand - although it will now produce that warning for the total simulation time timer - which is stopped multiple times within Carpet.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4889 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4885 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4884 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
| |
Provide macros to always make isnan available under its standard name,
even if it actually needs to be called in a different manner.
Provide C wrapper functions for isnan, which can function as fallback
for C++.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4882 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4877 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4834 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch changes the return value in the "does not compile" case to -1 and
updates all source files that I could find that use it.
Note that this patch changes behaviour of a routine. It used to return 0 for
non-compiling patterns so thorns that test for C-like true would interpret
invalid patterns as does-not-match, but will interpret the -1 return value as
does-match.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4831 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4804 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
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
| |
where there's only '*' given as allowed value
(see also thread http://www.cactuscode.org/old/pipermail/developers/2008-September/005626.html)
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4504 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
interprets ranges consisting of single numbers as allowing this number
and all larger numbers. For example, the specification
INT spatial_order "Order of spatial differencing"
{
2 :: "second order"
4 :: "fourth order"
} 2
allows all numbers not less than 2.
This patch corrects this problem. Since this involves regular
expressions which are often difficult to read, I have broken up the
regular expressions into macros containing sub-expressions.
I have also replaced calls to atoi and atof with calls to strtol and
strtod, since these allow error checking which also was not present
before.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4496 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Network.c uses gethostbyname() which is available on the front-end
nodes of the XT4, but not available on Compute Node Linux back-end
nodes. The code will link fine with gethostbyname(), but will resolve
to the dynamically shared library version of glibc. Since the Compute
nodes do not understand dynamically linked libraries (only static linking),
then it causes a fatal runtime error if gethostbyname() is invoked even
though the compiler will not provide any warning that something bad
will occur.
Therefore, if you #define CRAY_XT, it will disable the gethostbyname() so as
to prevent a fatal runtime error when GetHostName is called.
Need to find out a way to recognize Cray XT4/Compute-node-Linux systems
automatically. The front-end of the XT4 looks exactly like a Linux cluster.
(uname returns "Linux"). Perhaps add a test to the Linux cluster known
architectures file that points it to a XT4_CNL known-architetures file.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4434 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Timer handles are not numbered consecutively from 0 upwards. It is
therefore not possible to test for legal timer number by checking the
range [0, CCTK_NumTimers()). Instead, for each timer handle one has
to check whether handled data exist.
Remove the feature that a timer number of -1 prints all existing
timers, since it is not possible (?) to iterate over all existing
timers.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4396 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
| |
CCTK_TimerPrintDataI.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4395 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
| |
Fixes PR 2058.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4386 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
| |
values. This makes its behaviour consistent with the flesh API routine
CCTK_ParameterSet().
This closes PR Cactus/2050: preserve newlines in quoted string parameter values.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4371 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
to return a date/time stamp following the ISO 8601 standard format if possible
(see http://www.cactuscode.org/old/pipermail/developers/2006-July/004971.html).
Add the timezone information in the time stamp returned by Util_CurrentTime().
You also need to update lib/make/make.configuration now in order to compile
src/datestamp.c.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4358 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4292 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4272 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
| |
Patches mailing list.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4263 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
| |
needed was more checking. This checked out alright on lemieux.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4231 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4230 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
| |
produce an error if it is exceeded.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4210 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4163 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
| |
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4162 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
instead of with fprintf (stderr, ...).
Correct critical error in looking at the values of cctk_full_warnings,
highlight_warning_messages, and cctk_strong_param_check.
Handle the empty regular expression specially in CCTK_RegexMatch,
since regcomp may treat it as illegal expression. In Cactus, an empty
regular expression matches everything.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4150 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
| |
positive.
Cast to unsigned int when checking whether the parameter value
complies with the step size. Explain why this is necessary.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4119 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
|
|
| |
Complete the implementation of the Cactus variable type
CCTK_POINTER_TO_CONST. Define a constant
CCTK_VARIABLE_POINTER_TO_CONST. Handle this variable when asking for
its name and its size. Allow values of this type in tables.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4113 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
|
| |
strings.
This applies patch http://www.cactuscode.org/pipermail/patches/2005-June/000061.html.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4102 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
| |
-- very interesting bug!)
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4092 17b73243-c579-4c4c-a9d2-2d5706c11dac
|
|
|
|
|
|
|
| |
definitions to make the code fit into 80 columns.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4091 17b73243-c579-4c4c-a9d2-2d5706c11dac
|