aboutsummaryrefslogtreecommitdiff
path: root/src/InterpLocalUniform.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/InterpLocalUniform.c')
-rw-r--r--src/InterpLocalUniform.c158
1 files changed, 79 insertions, 79 deletions
diff --git a/src/InterpLocalUniform.c b/src/InterpLocalUniform.c
index 0d0ff63..3d35b2c 100644
--- a/src/InterpLocalUniform.c
+++ b/src/InterpLocalUniform.c
@@ -104,21 +104,21 @@ static
int N_dims,
int param_table_handle,
/***** coordinate system *****/
- const CCTK_REAL *restrict coord_origin,
- const CCTK_REAL *restrict coord_delta,
+ const CCTK_REAL coord_origin[],
+ const CCTK_REAL coord_delta[],
/***** interpolation points *****/
int N_interp_points,
int interp_coords_type_code,
- const void *restrict const *restrict interp_coords,
+ const void *const interp_coords[],
/***** input arrays *****/
int N_input_arrays,
- const CCTK_INT *restrict input_array_dims,
- const CCTK_INT *restrict input_array_type_codes,
- const void *restrict const *restrict input_arrays,
+ const CCTK_INT input_array_dims[],
+ const CCTK_INT input_array_type_codes[],
+ const void *const input_arrays[],
/***** output arrays *****/
int N_output_arrays,
- const CCTK_INT *restrict output_array_type_codes,
- void *restrict const *restrict output_arrays);
+ const CCTK_INT output_array_type_codes[],
+ void *const output_arrays[]);
static
void check_boundary_tolerances
@@ -127,48 +127,48 @@ static
const CCTK_REAL boundary_extrapolation_tolerance[MAX_N_BOUNDARIES]);
static
int get_error_point_info(int param_table_handle,
- struct error_info *restrict p_error_info);
+ struct error_info *p_error_info);
static
int get_and_decode_molecule_family
(int param_table_handle,
- int buffer_size, char *restrict molecule_family_string_buffer,
- enum molecule_family *restrict p_molecule_family);
+ int buffer_size, char molecule_family_string_buffer[],
+ enum molecule_family *p_molecule_family);
static
int get_molecule_positions
(int param_table_handle,
- int N_dims, CCTK_INT *restrict molecule_positions_array[MAX_N_DIMS]);
+ int N_dims, CCTK_INT* molecule_positions_array[MAX_N_DIMS]);
static
int get_Jacobian_info(int param_table_handle,
int N_dims, int N_output_arrays,
- struct Jacobian_info *restrict p_Jacobian_info);
+ struct Jacobian_info* p_Jacobian_info);
static
int set_error_info(int param_table_handle,
- struct error_info *restrict p_error_info);
+ struct error_info* p_error_info);
static
int set_molecule_structure
(int param_table_handle,
- const struct molecule_structure_flags *restrict p_molecule_structure_flags);
+ const struct molecule_structure_flags* p_molecule_structure_flags);
static
int set_molecule_min_max_m
(int param_table_handle,
int N_dims,
- const struct molecule_min_max_m_info *restrict p_molecule_min_max_m_info);
+ const struct molecule_min_max_m_info* p_molecule_min_max_m_info);
static
- int get_and_check_INT(int param_table_handle, const char *restrict name,
+ int get_and_check_INT(int param_table_handle, const char name[],
bool mandatory_flag, int default_value,
bool check_range_flag, int min_value, int max_value,
- const char *restrict max_value_string,
- CCTK_INT *restrict p_value);
+ const char max_value_string[],
+ CCTK_INT* p_value);
static
- int get_INT_array(int param_table_handle, const char *restrict name,
+ int get_INT_array(int param_table_handle, const char name[],
bool default_flag, int default_value,
- int N, CCTK_INT *restrict buffer,
- bool *restrict p_value_not_set);
+ int N, CCTK_INT buffer[],
+ bool* p_value_not_set);
static
- int get_REAL_array(int param_table_handle, const char *restrict name,
+ int get_REAL_array(int param_table_handle, const char name[],
CCTK_REAL default_value,
- int N, CCTK_REAL *restrict buffer);
+ int N, CCTK_REAL buffer[]);
/**************************************/
@@ -424,21 +424,21 @@ static const p_interp_fn_t p_interp_fn_table[N_INTERP_OPERATORS]
int AEILocalInterp_U_Lagrange_TP(int N_dims,
int param_table_handle,
/***** coordinate system *****/
- const CCTK_REAL *restrict coord_origin,
- const CCTK_REAL *restrict coord_delta,
+ const CCTK_REAL coord_origin[],
+ const CCTK_REAL coord_delta[],
/***** interpolation points *****/
int N_interp_points,
int interp_coords_type_code,
- const void *restrict const *restrict interp_coords,
+ const void *const interp_coords[],
/***** input arrays *****/
int N_input_arrays,
- const CCTK_INT *restrict input_array_dims,
- const CCTK_INT *restrict input_array_type_codes,
- const void *restrict const *restrict input_arrays,
+ const CCTK_INT input_array_dims[],
+ const CCTK_INT input_array_type_codes[],
+ const void *const input_arrays[],
/***** output arrays *****/
int N_output_arrays,
- const CCTK_INT *restrict output_array_type_codes,
- void *restrict const *restrict output_arrays)
+ const CCTK_INT output_array_type_codes[],
+ void *const output_arrays[])
{
return InterpLocalUniform(interp_operator_Lagrange_TP,
"Lagrange polynomial interpolation (tensor product)",
@@ -492,21 +492,21 @@ return InterpLocalUniform(interp_operator_Lagrange_TP,
int AEILocalInterp_U_Lagrange_MD(int N_dims,
int param_table_handle,
/***** coordinate system *****/
- const CCTK_REAL *restrict coord_origin,
- const CCTK_REAL *restrict coord_delta,
+ const CCTK_REAL coord_origin[],
+ const CCTK_REAL coord_delta[],
/***** interpolation points *****/
int N_interp_points,
int interp_coords_type_code,
- const void *restrict const *restrict interp_coords,
+ const void *const interp_coords[],
/***** input arrays *****/
int N_input_arrays,
- const CCTK_INT *restrict input_array_dims,
- const CCTK_INT *restrict input_array_type_codes,
- const void *restrict const *restrict input_arrays,
+ const CCTK_INT input_array_dims[],
+ const CCTK_INT input_array_type_codes[],
+ const void *const input_arrays[],
/***** output arrays *****/
int N_output_arrays,
- const CCTK_INT *restrict output_array_type_codes,
- void *restrict const *restrict output_arrays)
+ const CCTK_INT output_array_type_codes[],
+ void *const output_arrays[])
{
return InterpLocalUniform(interp_operator_Lagrange_MD,
"Lagrange polynomial interpolation (maximum degree)",
@@ -553,21 +553,21 @@ return InterpLocalUniform(interp_operator_Lagrange_MD,
int AEILocalInterp_U_Hermite(int N_dims,
int param_table_handle,
/***** coordinate system *****/
- const CCTK_REAL *restrict coord_origin,
- const CCTK_REAL *restrict coord_delta,
+ const CCTK_REAL coord_origin[],
+ const CCTK_REAL coord_delta[],
/***** interpolation points *****/
int N_interp_points,
int interp_coords_type_code,
- const void *restrict const *restrict interp_coords,
+ const void *const interp_coords[],
/***** input arrays *****/
int N_input_arrays,
- const CCTK_INT *restrict input_array_dims,
- const CCTK_INT *restrict input_array_type_codes,
- const void *restrict const *restrict input_arrays,
+ const CCTK_INT input_array_dims[],
+ const CCTK_INT input_array_type_codes[],
+ const void *const input_arrays[],
/***** output arrays *****/
int N_output_arrays,
- const CCTK_INT *restrict output_array_type_codes,
- void *restrict const *restrict output_arrays)
+ const CCTK_INT output_array_type_codes[],
+ void *const output_arrays[])
{
return InterpLocalUniform(interp_operator_Hermite,
"Hermite polynomial interpolation",
@@ -1029,21 +1029,21 @@ static
int N_dims,
int param_table_handle,
/***** coordinate system *****/
- const CCTK_REAL *restrict coord_origin,
- const CCTK_REAL *restrict coord_delta,
+ const CCTK_REAL coord_origin[],
+ const CCTK_REAL coord_delta[],
/***** interpolation points *****/
int N_interp_points,
int interp_coords_type_code,
- const void *restrict const *restrict interp_coords,
+ const void *const interp_coords[],
/***** input arrays *****/
int N_input_arrays,
- const CCTK_INT *restrict input_array_dims,
- const CCTK_INT *restrict input_array_type_codes,
- const void *restrict const *restrict input_arrays,
+ const CCTK_INT input_array_dims[],
+ const CCTK_INT input_array_type_codes[],
+ const void *const input_arrays[],
/***** output arrays *****/
int N_output_arrays,
- const CCTK_INT *restrict output_array_type_codes,
- void *restrict const *restrict output_arrays)
+ const CCTK_INT output_array_type_codes[],
+ void *const output_arrays[])
{
/*
* Implementation Note:
@@ -1396,7 +1396,7 @@ if (value_not_set)
/**************************************/
{
-CCTK_INT *restrict const operation_codes
+CCTK_INT* const operation_codes
= (CCTK_INT*) malloc(N_output_arrays1 * sizeof(CCTK_INT));
if (operation_codes == NULL)
then {
@@ -1423,8 +1423,8 @@ if (status != 0)
*/
{
-struct molecule_min_max_m_info *restrict p_molecule_min_max_m_info = NULL;
-struct molecule_min_max_m_info molecule_min_max_m_info;
+struct molecule_min_max_m_info* p_molecule_min_max_m_info = NULL;
+struct molecule_min_max_m_info molecule_min_max_m_info;
/* molecule min/max m */
status1 = Util_TableQueryValueInfo(param_table_handle,
@@ -1452,8 +1452,8 @@ if (status1 && status2)
then p_molecule_min_max_m_info = &molecule_min_max_m_info;
{
-CCTK_INT *restrict *restrict p_molecule_positions = NULL;
-CCTK_INT *restrict molecule_positions_array[MAX_N_DIMS];
+CCTK_INT** p_molecule_positions = NULL;
+CCTK_INT* molecule_positions_array[MAX_N_DIMS];
/* are we doing a molecule-positions query? */
status = Util_TableQueryValueInfo(param_table_handle,
@@ -1491,8 +1491,8 @@ if (status)
*/
{
-struct Jacobian_info *restrict p_Jacobian_info = NULL;
-struct Jacobian_info Jacobian_info;
+struct Jacobian_info* p_Jacobian_info = NULL;
+struct Jacobian_info Jacobian_info;
Jacobian_info.Jacobian_pointer = NULL;
Jacobian_info.Jacobian_offset = NULL;
@@ -1794,7 +1794,7 @@ int ibndry;
*/
static
int get_error_point_info(int param_table_handle,
- struct error_info *restrict p_error_info)
+ struct error_info *p_error_info)
{
CCTK_POINTER per_point_status;
int status;
@@ -1864,8 +1864,8 @@ return 0; /*** NORMAL RETURN ***/
static
int get_and_decode_molecule_family
(int param_table_handle,
- int buffer_size, char *restrict molecule_family_string_buffer,
- enum molecule_family *restrict p_molecule_family)
+ int buffer_size, char molecule_family_string_buffer[],
+ enum molecule_family *p_molecule_family)
{
enum molecule_family molecule_family;
int status;
@@ -1938,7 +1938,7 @@ return 0; /*** NORMAL RETURN ***/
static
int get_molecule_positions
(int param_table_handle,
- int N_dims, CCTK_INT *restrict molecule_positions_array[MAX_N_DIMS])
+ int N_dims, CCTK_INT* molecule_positions_array[MAX_N_DIMS])
{
CCTK_POINTER molecule_positions_temp[MAX_N_DIMS];
int status;
@@ -1988,7 +1988,7 @@ return 0; /*** NORMAL RETURN ***/
static
int get_Jacobian_info(int param_table_handle,
int N_dims, int N_output_arrays,
- struct Jacobian_info *restrict p_Jacobian_info)
+ struct Jacobian_info* p_Jacobian_info)
{
/* padded array size, cf. InterpLocalUniform() header comments */
const int N_output_arrays1 = N_output_arrays + 1;
@@ -2106,7 +2106,7 @@ return 0; /*** NORMAL RETURN ***/
*/
static
int set_error_info(int param_table_handle,
- struct error_info *restrict p_error_info)
+ struct error_info* p_error_info)
{
if (p_error_info->found_per_point_status)
then {
@@ -2146,7 +2146,7 @@ return 0; /*** NORMAL RETURN ***/
static
int set_molecule_structure
(int param_table_handle,
- const struct molecule_structure_flags *restrict p_molecule_structure_flags)
+ const struct molecule_structure_flags* p_molecule_structure_flags)
{
const int status1
= Util_TableSetInt(param_table_handle,
@@ -2198,7 +2198,7 @@ static
int set_molecule_min_max_m
(int param_table_handle,
int N_dims,
- const struct molecule_min_max_m_info *restrict p_molecule_min_max_m_info)
+ const struct molecule_min_max_m_info* p_molecule_min_max_m_info)
{
const int status1
= Util_TableSetIntArray(param_table_handle,
@@ -2251,11 +2251,11 @@ return 0; /*** NORMAL RETURN ***/
* This function returns 0 for ok, or the (nonzero) return code for error.
*/
static
- int get_and_check_INT(int param_table_handle, const char *restrict name,
+ int get_and_check_INT(int param_table_handle, const char name[],
bool mandatory_flag, int default_value,
bool check_range_flag, int min_value, int max_value,
- const char *restrict max_value_string,
- CCTK_INT *restrict p_value)
+ const char max_value_string[],
+ CCTK_INT* p_value)
{
CCTK_INT value;
@@ -2353,10 +2353,10 @@ return 0; /*** NORMAL RETURN ***/
* positive or negative!
*/
static
- int get_INT_array(int param_table_handle, const char *restrict name,
+ int get_INT_array(int param_table_handle, const char name[],
bool default_flag, int default_value,
- int N, CCTK_INT *restrict buffer,
- bool *restrict p_value_not_set)
+ int N, CCTK_INT buffer[],
+ bool* p_value_not_set)
{
const int status
= Util_TableGetIntArray(param_table_handle,
@@ -2433,9 +2433,9 @@ return 0; /*** NORMAL RETURN ***/
* positive or negative!
*/
static
- int get_REAL_array(int param_table_handle, const char *restrict name,
+ int get_REAL_array(int param_table_handle, const char name[],
CCTK_REAL default_value,
- int N, CCTK_REAL *restrict buffer)
+ int N, CCTK_REAL buffer[])
{
const int status
= Util_TableGetRealArray(param_table_handle,