diff --git a/benchmarks/diffusion_2D/diffusion_2D.hpp b/benchmarks/diffusion_2D/diffusion_2D.hpp index a27c004e63..b7cf467f4d 100644 --- a/benchmarks/diffusion_2D/diffusion_2D.hpp +++ b/benchmarks/diffusion_2D/diffusion_2D.hpp @@ -48,11 +48,10 @@ #endif // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/cmake/SundialsSetupCompilers.cmake b/cmake/SundialsSetupCompilers.cmake index af5ef91f5f..52c4a5e7af 100644 --- a/cmake/SundialsSetupCompilers.cmake +++ b/cmake/SundialsSetupCompilers.cmake @@ -85,7 +85,8 @@ if(ENABLE_ALL_WARNINGS) set(WARNING_FLAGS "-Wno-unknown-warning-option -Wall -Wpedantic -Wextra -Wshadow \ -Wwrite-strings -Wcast-align -Wdisabled-optimization -Wvla -Walloca \ --Wduplicated-cond -Wduplicated-branches") +-Wduplicated-cond -Wduplicated-branches -Wunused-macros \ +-Wunused-local-typedefs") # TODO(SBR): Try to add -Wredundant-decls once SuperLU version is updated in # CI tests diff --git a/examples/arkode/CXX_parallel/ark_heat2D_lsrk_p.cpp b/examples/arkode/CXX_parallel/ark_heat2D_lsrk_p.cpp index 5a69244b8b..361c621c1a 100644 --- a/examples/arkode/CXX_parallel/ark_heat2D_lsrk_p.cpp +++ b/examples/arkode/CXX_parallel/ark_heat2D_lsrk_p.cpp @@ -60,11 +60,10 @@ #include "sunadaptcontroller/sunadaptcontroller_soderlind.h" // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/arkode/CXX_parallel/ark_heat2D_p.cpp b/examples/arkode/CXX_parallel/ark_heat2D_p.cpp index ed59996da6..498fb0500f 100644 --- a/examples/arkode/CXX_parallel/ark_heat2D_p.cpp +++ b/examples/arkode/CXX_parallel/ark_heat2D_p.cpp @@ -59,11 +59,10 @@ #include "sunlinsol/sunlinsol_spgmr.h" // access to SPGMR SUNLinearSolver // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/arkode/CXX_parhyp/ark_heat2D_hypre_ls.cpp b/examples/arkode/CXX_parhyp/ark_heat2D_hypre_ls.cpp index 997bd4d787..f1b2e86f5e 100644 --- a/examples/arkode/CXX_parhyp/ark_heat2D_hypre_ls.cpp +++ b/examples/arkode/CXX_parhyp/ark_heat2D_hypre_ls.cpp @@ -61,11 +61,10 @@ #include "sundials/sundials_matrix.h" // definition SUNMatrix // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/arkode/CXX_parhyp/ark_heat2D_hypre_pfmg.cpp b/examples/arkode/CXX_parhyp/ark_heat2D_hypre_pfmg.cpp index 3950d8c482..f457f69875 100644 --- a/examples/arkode/CXX_parhyp/ark_heat2D_hypre_pfmg.cpp +++ b/examples/arkode/CXX_parhyp/ark_heat2D_hypre_pfmg.cpp @@ -61,11 +61,10 @@ #include "sunlinsol/sunlinsol_spgmr.h" // access to SPGMR SUNLinearSolver // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/arkode/CXX_parhyp/ark_heat2D_hypre_pfmg_imex.cpp b/examples/arkode/CXX_parhyp/ark_heat2D_hypre_pfmg_imex.cpp index 9ca07cbfe1..28aa57b8de 100644 --- a/examples/arkode/CXX_parhyp/ark_heat2D_hypre_pfmg_imex.cpp +++ b/examples/arkode/CXX_parhyp/ark_heat2D_hypre_pfmg_imex.cpp @@ -62,11 +62,10 @@ #include "sunlinsol/sunlinsol_spgmr.h" // access to GMRES SUNLinearSolver // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/arkode/CXX_parhyp/ark_heat2D_hypre_pfmg_mri.cpp b/examples/arkode/CXX_parhyp/ark_heat2D_hypre_pfmg_mri.cpp index bf090c0020..d5b0e0935d 100644 --- a/examples/arkode/CXX_parhyp/ark_heat2D_hypre_pfmg_mri.cpp +++ b/examples/arkode/CXX_parhyp/ark_heat2D_hypre_pfmg_mri.cpp @@ -61,11 +61,10 @@ #include "sunlinsol/sunlinsol_spgmr.h" // access to GMRES SUNLinearSolver // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/arkode/CXX_serial/ark_analytic_sys.cpp b/examples/arkode/CXX_serial/ark_analytic_sys.cpp index d48ce0abb9..388a5b982b 100644 --- a/examples/arkode/CXX_serial/ark_analytic_sys.cpp +++ b/examples/arkode/CXX_serial/ark_analytic_sys.cpp @@ -54,11 +54,9 @@ #include // access to dense SUNMatrix #if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" #define ESYM "Le" #define FSYM "Lf" #else -#define GSYM "g" #define ESYM "e" #define FSYM "f" #endif diff --git a/examples/arkode/CXX_serial/ark_heat2D.cpp b/examples/arkode/CXX_serial/ark_heat2D.cpp index 4b75d703bb..6b7ec1654c 100644 --- a/examples/arkode/CXX_serial/ark_heat2D.cpp +++ b/examples/arkode/CXX_serial/ark_heat2D.cpp @@ -59,11 +59,10 @@ #include "sunlinsol/sunlinsol_spgmr.h" // access to SPGMR SUNLinearSolver // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/arkode/CXX_serial/ark_heat2D_lsrk.cpp b/examples/arkode/CXX_serial/ark_heat2D_lsrk.cpp index 52549e1544..578a1de757 100644 --- a/examples/arkode/CXX_serial/ark_heat2D_lsrk.cpp +++ b/examples/arkode/CXX_serial/ark_heat2D_lsrk.cpp @@ -63,11 +63,10 @@ #include "sunadaptcontroller/sunadaptcontroller_soderlind.h" // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/arkode/CXX_serial/ark_kpr_Mt.cpp b/examples/arkode/CXX_serial/ark_kpr_Mt.cpp index f48f81bc84..4652d87b43 100644 --- a/examples/arkode/CXX_serial/ark_kpr_Mt.cpp +++ b/examples/arkode/CXX_serial/ark_kpr_Mt.cpp @@ -86,11 +86,9 @@ #include #if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" #define ESYM "Le" #define FSYM "Lf" #else -#define GSYM "g" #define ESYM "e" #define FSYM "f" #endif diff --git a/examples/arkode/CXX_xbraid/ark_heat2D_hypre_pfmg_xbraid.cpp b/examples/arkode/CXX_xbraid/ark_heat2D_hypre_pfmg_xbraid.cpp index 0c4da9c70e..ab77a4365b 100644 --- a/examples/arkode/CXX_xbraid/ark_heat2D_hypre_pfmg_xbraid.cpp +++ b/examples/arkode/CXX_xbraid/ark_heat2D_hypre_pfmg_xbraid.cpp @@ -63,11 +63,10 @@ #include "sunlinsol/sunlinsol_spgmr.h" // access to SPGMR SUNLinearSolver // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/arkode/CXX_xbraid/ark_heat2D_p_xbraid.cpp b/examples/arkode/CXX_xbraid/ark_heat2D_p_xbraid.cpp index 466b1f7f9c..6967adbe16 100644 --- a/examples/arkode/CXX_xbraid/ark_heat2D_p_xbraid.cpp +++ b/examples/arkode/CXX_xbraid/ark_heat2D_p_xbraid.cpp @@ -61,11 +61,10 @@ #include "sunlinsol/sunlinsol_spgmr.h" // access to SPGMR SUNLinearSolver // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/arkode/CXX_xbraid/ark_heat2D_xbraid.cpp b/examples/arkode/CXX_xbraid/ark_heat2D_xbraid.cpp index c330571584..48a19a92ff 100644 --- a/examples/arkode/CXX_xbraid/ark_heat2D_xbraid.cpp +++ b/examples/arkode/CXX_xbraid/ark_heat2D_xbraid.cpp @@ -62,11 +62,10 @@ #include "sunlinsol/sunlinsol_spgmr.h" // access to SPGMR SUNLinearSolver // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/arkode/C_openmpdev/ark_analytic_nonlin_ompdev.c b/examples/arkode/C_openmpdev/ark_analytic_nonlin_ompdev.c index 15c909a73f..e8625e0625 100644 --- a/examples/arkode/C_openmpdev/ark_analytic_nonlin_ompdev.c +++ b/examples/arkode/C_openmpdev/ark_analytic_nonlin_ompdev.c @@ -41,11 +41,9 @@ #endif #if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" #define ESYM "Le" #define FSYM "Lf" #else -#define GSYM "g" #define ESYM "e" #define FSYM "f" #endif diff --git a/examples/arkode/C_openmpdev/ark_heat1D_adapt_ompdev.c b/examples/arkode/C_openmpdev/ark_heat1D_adapt_ompdev.c index 7d12f225f8..6612042232 100644 --- a/examples/arkode/C_openmpdev/ark_heat1D_adapt_ompdev.c +++ b/examples/arkode/C_openmpdev/ark_heat1D_adapt_ompdev.c @@ -55,11 +55,9 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* constants */ diff --git a/examples/arkode/C_serial/ark_analytic_nonlin.c b/examples/arkode/C_serial/ark_analytic_nonlin.c index c39c3e80d1..8af75d1fb1 100644 --- a/examples/arkode/C_serial/ark_analytic_nonlin.c +++ b/examples/arkode/C_serial/ark_analytic_nonlin.c @@ -34,11 +34,9 @@ #include /* def. of type 'sunrealtype' */ #if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" #define ESYM "Le" #define FSYM "Lf" #else -#define GSYM "g" #define ESYM "e" #define FSYM "f" #endif diff --git a/examples/arkode/C_serial/ark_analytic_partitioned.c b/examples/arkode/C_serial/ark_analytic_partitioned.c index 173dea29c4..7979beb29a 100644 --- a/examples/arkode/C_serial/ark_analytic_partitioned.c +++ b/examples/arkode/C_serial/ark_analytic_partitioned.c @@ -46,12 +46,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif typedef struct diff --git a/examples/arkode/C_serial/ark_conserved_exp_entropy_ark.c b/examples/arkode/C_serial/ark_conserved_exp_entropy_ark.c index e1962d01fe..4029962847 100644 --- a/examples/arkode/C_serial/ark_conserved_exp_entropy_ark.c +++ b/examples/arkode/C_serial/ark_conserved_exp_entropy_ark.c @@ -74,13 +74,9 @@ /* Convince macros for using precision-specific format specifiers */ #if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else -#define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* ----------------------- * diff --git a/examples/arkode/C_serial/ark_conserved_exp_entropy_erk.c b/examples/arkode/C_serial/ark_conserved_exp_entropy_erk.c index 47bd3fa6e6..f11beee1e5 100644 --- a/examples/arkode/C_serial/ark_conserved_exp_entropy_erk.c +++ b/examples/arkode/C_serial/ark_conserved_exp_entropy_erk.c @@ -72,13 +72,9 @@ /* Convince macros for using precision-specific format specifiers */ #if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else -#define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* ----------------------- * diff --git a/examples/arkode/C_serial/ark_dissipated_exp_entropy.c b/examples/arkode/C_serial/ark_dissipated_exp_entropy.c index 35de91fff0..4a8f4af9a0 100644 --- a/examples/arkode/C_serial/ark_dissipated_exp_entropy.c +++ b/examples/arkode/C_serial/ark_dissipated_exp_entropy.c @@ -39,28 +39,21 @@ /* Convince macros for calling precision-specific math functions */ #if defined(SUNDIALS_DOUBLE_PRECISION) -#define EXP(x) (exp((x))) -#define SQRT(x) (sqrt((x))) -#define LOG(x) (log((x))) +#define EXP(x) (exp((x))) +#define LOG(x) (log((x))) #elif defined(SUNDIALS_SINGLE_PRECISION) -#define EXP(x) (expf((x))) -#define SQRT(x) (sqrtf((x))) -#define LOG(x) (logf((x))) +#define EXP(x) (expf((x))) +#define LOG(x) (logf((x))) #elif defined(SUNDIALS_EXTENDED_PRECISION) -#define EXP(x) (expl((x))) -#define SQRT(x) (sqrtl((x))) -#define LOG(x) (logl((x))) +#define EXP(x) (expl((x))) +#define LOG(x) (logl((x))) #endif /* Convince macros for using precision-specific format specifiers */ #if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else -#define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* ----------------------- * diff --git a/examples/arkode/C_serial/ark_heat1D_adapt.c b/examples/arkode/C_serial/ark_heat1D_adapt.c index 8e846e592e..cb1ef9388b 100644 --- a/examples/arkode/C_serial/ark_heat1D_adapt.c +++ b/examples/arkode/C_serial/ark_heat1D_adapt.c @@ -47,11 +47,9 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* constants */ diff --git a/examples/arkode/C_serial/ark_robertson.c b/examples/arkode/C_serial/ark_robertson.c index d0fdbb52d2..6a3fefa2da 100644 --- a/examples/arkode/C_serial/ark_robertson.c +++ b/examples/arkode/C_serial/ark_robertson.c @@ -44,11 +44,9 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* User-supplied Functions Called by the Solver */ diff --git a/examples/arkode/C_serial/ark_robertson_constraints.c b/examples/arkode/C_serial/ark_robertson_constraints.c index 532149b212..7bb3e537d4 100644 --- a/examples/arkode/C_serial/ark_robertson_constraints.c +++ b/examples/arkode/C_serial/ark_robertson_constraints.c @@ -45,11 +45,9 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* User-supplied Functions Called by the Solver */ diff --git a/examples/arkode/C_serial/ark_robertson_root.c b/examples/arkode/C_serial/ark_robertson_root.c index ae8e476394..9216a7490e 100644 --- a/examples/arkode/C_serial/ark_robertson_root.c +++ b/examples/arkode/C_serial/ark_robertson_root.c @@ -47,11 +47,9 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* User-supplied Functions Called by the Solver */ diff --git a/examples/cvode/CXX_parallel/cv_heat2D_p.cpp b/examples/cvode/CXX_parallel/cv_heat2D_p.cpp index a4fc90e7fc..c800ae4047 100644 --- a/examples/cvode/CXX_parallel/cv_heat2D_p.cpp +++ b/examples/cvode/CXX_parallel/cv_heat2D_p.cpp @@ -60,11 +60,10 @@ #include "sunlinsol/sunlinsol_spgmr.h" // access to SPGMR SUNLinearSolver // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/cvode/CXX_parhyp/cv_heat2D_hypre_ls.cpp b/examples/cvode/CXX_parhyp/cv_heat2D_hypre_ls.cpp index 57b407923a..d689c04e6d 100644 --- a/examples/cvode/CXX_parhyp/cv_heat2D_hypre_ls.cpp +++ b/examples/cvode/CXX_parhyp/cv_heat2D_hypre_ls.cpp @@ -61,11 +61,10 @@ #include "sundials/sundials_matrix.h" // definition SUNMatrix // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/cvode/CXX_parhyp/cv_heat2D_hypre_pfmg.cpp b/examples/cvode/CXX_parhyp/cv_heat2D_hypre_pfmg.cpp index cb722ec2d9..60d69b086b 100644 --- a/examples/cvode/CXX_parhyp/cv_heat2D_hypre_pfmg.cpp +++ b/examples/cvode/CXX_parhyp/cv_heat2D_hypre_pfmg.cpp @@ -61,11 +61,10 @@ #include "sunlinsol/sunlinsol_spgmr.h" // access to SPGMR SUNLinearSolver // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/cvode/CXX_serial/cv_heat2D.hpp b/examples/cvode/CXX_serial/cv_heat2D.hpp index c8b0bc779c..1318c7d56b 100644 --- a/examples/cvode/CXX_serial/cv_heat2D.hpp +++ b/examples/cvode/CXX_serial/cv_heat2D.hpp @@ -32,11 +32,10 @@ #include // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // ----------------------------------------------------------------------------- // User data structure diff --git a/examples/cvode/CXX_sycl/cvAdvDiff_kry_sycl.cpp b/examples/cvode/CXX_sycl/cvAdvDiff_kry_sycl.cpp index 84718e9e54..96c0d4774c 100644 --- a/examples/cvode/CXX_sycl/cvAdvDiff_kry_sycl.cpp +++ b/examples/cvode/CXX_sycl/cvAdvDiff_kry_sycl.cpp @@ -59,22 +59,6 @@ #define TWO SUN_RCONST(2.0) #define FIVE SUN_RCONST(5.0) -#if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" -#else -#define GSYM "g" -#define ESYM "e" -#define FSYM "f" -#endif - -#if defined(SUNDIALS_INT64_T) -#define DSYM "ld" -#else -#define DSYM "d" -#endif - // User data sstructure contains model and discretization parameters struct UserData { diff --git a/examples/cvode/ginkgo/cv_heat2D_ginkgo.hpp b/examples/cvode/ginkgo/cv_heat2D_ginkgo.hpp index e25866c747..e4ef99705b 100644 --- a/examples/cvode/ginkgo/cv_heat2D_ginkgo.hpp +++ b/examples/cvode/ginkgo/cv_heat2D_ginkgo.hpp @@ -43,11 +43,10 @@ #include // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // ----------------------------------------------------------------------------- // User data structure diff --git a/examples/cvode/serial/cvDisc_dns.c b/examples/cvode/serial/cvDisc_dns.c index d8ac4f9731..aa5fdd6fe4 100644 --- a/examples/cvode/serial/cvDisc_dns.c +++ b/examples/cvode/serial/cvDisc_dns.c @@ -25,13 +25,9 @@ #include /* access to dense SUNMatrix */ #if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else -#define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* Problem Constants */ diff --git a/examples/cvode/serial/cvDiurnal_kry_bp.c b/examples/cvode/serial/cvDiurnal_kry_bp.c index 5bb0081686..ff9ad14b3a 100644 --- a/examples/cvode/serial/cvDiurnal_kry_bp.c +++ b/examples/cvode/serial/cvDiurnal_kry_bp.c @@ -95,28 +95,20 @@ #define ATOL (RTOL * FLOOR) /* scalar absolute tolerance */ #define NEQ (NUM_SPECIES * MM) /* NEQ = number of equations */ -/* User-defined vector and matrix accessor macros: IJKth, IJth */ +/* User-defined vector and matrix accessor macro: IJKth */ /* IJKth is defined in order to isolate the translation from the mathematical 3-dimensional structure of the dependent variable vector - to the underlying 1-dimensional storage. IJth is defined in order to - write code which indexes into small dense matrices with a (row,column) - pair, where 1 <= row, column <= NUM_SPECIES. + to the underlying 1-dimensional storage. IJKth(vdata,i,j,k) references the element in the vdata array for species i at mesh point (j,k), where 1 <= i <= NUM_SPECIES, 0 <= j <= MX-1, 0 <= k <= MY-1. The vdata array is obtained via the call vdata = N_VGetArrayPointer(v), where v is an N_Vector. For each mesh point (j,k), the elements for species i and i+1 are - contiguous within vdata. - - IJth(a,i,j) references the (i,j)th entry of the small matrix sunrealtype **a, - where 1 <= i,j <= NUM_SPECIES. The small matrix routines in cvode_bandpre.h - work with matrices stored by column in a 2-dimensional array. In C, - arrays are indexed starting at 0, not 1. */ + contiguous within vdata. */ #define IJKth(vdata, i, j, k) (vdata[i - 1 + (j) * NUM_SPECIES + (k) * NSMX]) -#define IJth(a, i, j) (a[j - 1][i - 1]) /* Type : UserData contains preconditioner blocks, pivot arrays, and problem constants */ diff --git a/examples/cvode/serial/cvParticle_dns.c b/examples/cvode/serial/cvParticle_dns.c index ab716a0eae..579b9a5508 100644 --- a/examples/cvode/serial/cvParticle_dns.c +++ b/examples/cvode/serial/cvParticle_dns.c @@ -46,11 +46,9 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* Precision specific math function macros */ diff --git a/examples/cvode/serial/cvPendulum_dns.c b/examples/cvode/serial/cvPendulum_dns.c index 49c556ed85..9481c27fbd 100644 --- a/examples/cvode/serial/cvPendulum_dns.c +++ b/examples/cvode/serial/cvPendulum_dns.c @@ -67,13 +67,9 @@ /* Precision specific formatting macros */ #if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else -#define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* Precision specific math function macros */ diff --git a/examples/cvode/serial/cvRoberts_dns.c b/examples/cvode/serial/cvRoberts_dns.c index 5f6c873b04..5e338493e9 100644 --- a/examples/cvode/serial/cvRoberts_dns.c +++ b/examples/cvode/serial/cvRoberts_dns.c @@ -41,12 +41,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* User-defined vector and matrix accessor macros: Ith, IJth */ diff --git a/examples/cvode/serial/cvRoberts_dns_constraints.c b/examples/cvode/serial/cvRoberts_dns_constraints.c index aa5ca9a938..7cf8326b40 100644 --- a/examples/cvode/serial/cvRoberts_dns_constraints.c +++ b/examples/cvode/serial/cvRoberts_dns_constraints.c @@ -43,12 +43,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* User-defined vector and matrix accessor macros: Ith, IJth */ diff --git a/examples/cvode/serial/cvRoberts_dns_negsol.c b/examples/cvode/serial/cvRoberts_dns_negsol.c index 3715464042..286f614a02 100644 --- a/examples/cvode/serial/cvRoberts_dns_negsol.c +++ b/examples/cvode/serial/cvRoberts_dns_negsol.c @@ -52,8 +52,6 @@ #define TMULT SUN_RCONST(10.0) /* output time factor */ #define NOUT 14 /* number of output times */ -#define ZERO SUN_RCONST(0.0) - /* Functions Called by the Solver */ static int f(sunrealtype t, N_Vector y, N_Vector ydot, void* user_data); diff --git a/examples/cvode/serial/cvRoberts_klu.c b/examples/cvode/serial/cvRoberts_klu.c index 781bf37eb0..ac8294eccd 100644 --- a/examples/cvode/serial/cvRoberts_klu.c +++ b/examples/cvode/serial/cvRoberts_klu.c @@ -67,8 +67,6 @@ #define TMULT SUN_RCONST(10.0) /* output time factor */ #define NOUT 12 /* number of output times */ -#define ZERO SUN_RCONST(0.0) - /* Functions Called by the Solver */ static int f(sunrealtype t, N_Vector y, N_Vector ydot, void* user_data); diff --git a/examples/cvode/serial/cvRoberts_sps.c b/examples/cvode/serial/cvRoberts_sps.c index a79df81441..64865efbb0 100644 --- a/examples/cvode/serial/cvRoberts_sps.c +++ b/examples/cvode/serial/cvRoberts_sps.c @@ -67,8 +67,6 @@ #define TMULT SUN_RCONST(10.0) /* output time factor */ #define NOUT 12 /* number of output times */ -#define ZERO SUN_RCONST(0.0) - /* Functions Called by the Solver */ static int f(sunrealtype t, N_Vector y, N_Vector ydot, void* user_data); diff --git a/examples/cvode/serial/cvRocket_dns.c b/examples/cvode/serial/cvRocket_dns.c index 0dbe37448d..54d641fe29 100644 --- a/examples/cvode/serial/cvRocket_dns.c +++ b/examples/cvode/serial/cvRocket_dns.c @@ -45,16 +45,6 @@ #include "sundials/sundials_nvector.h" -#if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" -#else -#define GSYM "g" -#define ESYM "e" -#define FSYM "f" -#endif - /* Problem Constants */ #define NEQ 2 /* number of equations */ diff --git a/examples/cvode/superludist/cvAdvDiff_sludist.cpp b/examples/cvode/superludist/cvAdvDiff_sludist.cpp index 5a9ddc2b3a..6d7c316861 100644 --- a/examples/cvode/superludist/cvAdvDiff_sludist.cpp +++ b/examples/cvode/superludist/cvAdvDiff_sludist.cpp @@ -66,7 +66,6 @@ #define HALF SUN_RCONST(0.5) #define ONE SUN_RCONST(1.0) #define TWO SUN_RCONST(2.0) -#define FIVE SUN_RCONST(5.0) /* Type : UserData contains grid constants, parallel machine parameters, work array. */ diff --git a/examples/cvodes/serial/cvsAdvDiff_ASAi_bnd.c b/examples/cvodes/serial/cvsAdvDiff_ASAi_bnd.c index cd6a488a4b..f24192864d 100644 --- a/examples/cvodes/serial/cvsAdvDiff_ASAi_bnd.c +++ b/examples/cvodes/serial/cvsAdvDiff_ASAi_bnd.c @@ -68,9 +68,6 @@ #define ATOL SUN_RCONST(1.e-5) #define RTOLB SUN_RCONST(1.e-6) #define T0 SUN_RCONST(0.0) /* initial time */ -#define T1 SUN_RCONST(0.1) /* first output time */ -#define DTOUT SUN_RCONST(0.1) /* output time increment */ -#define NOUT 10 /* number of output times */ #define TOUT SUN_RCONST(1.0) /* final time */ #define NSTEP 50 /* check point saved every NSTEP */ diff --git a/examples/cvodes/serial/cvsDiurnal_kry_bp.c b/examples/cvodes/serial/cvsDiurnal_kry_bp.c index 2962e8afc1..e2dc1b8dea 100644 --- a/examples/cvodes/serial/cvsDiurnal_kry_bp.c +++ b/examples/cvodes/serial/cvsDiurnal_kry_bp.c @@ -96,28 +96,20 @@ #define ATOL (RTOL * FLOOR) /* scalar absolute tolerance */ #define NEQ (NUM_SPECIES * MM) /* NEQ = number of equations */ -/* User-defined vector and matrix accessor macros: IJKth, IJth */ +/* User-defined vector and matrix accessor macro: IJKth */ /* IJKth is defined in order to isolate the translation from the mathematical 3-dimensional structure of the dependent variable vector - to the underlying 1-dimensional storage. IJth is defined in order to - write code which indexes into small dense matrices with a (row,column) - pair, where 1 <= row, column <= NUM_SPECIES. + to the underlying 1-dimensional storage. IJKth(vdata,i,j,k) references the element in the vdata array for species i at mesh point (j,k), where 1 <= i <= NUM_SPECIES, 0 <= j <= MX-1, 0 <= k <= MY-1. The vdata array is obtained via the call vdata = N_VGetArrayPointer(v), where v is an N_Vector. For each mesh point (j,k), the elements for species i and i+1 are - contiguous within vdata. - - IJth(a,i,j) references the (i,j)th entry of the small matrix sunrealtype **a, - where 1 <= i,j <= NUM_SPECIES. The small matrix routines in dense.h - work with matrices stored by column in a 2-dimensional array. In C, - arrays are indexed starting at 0, not 1. */ + contiguous within vdata. */ #define IJKth(vdata, i, j, k) (vdata[i - 1 + (j) * NUM_SPECIES + (k) * NSMX]) -#define IJth(a, i, j) (a[j - 1][i - 1]) /* Type : UserData contains problem constants */ diff --git a/examples/cvodes/serial/cvsParticle_dns.c b/examples/cvodes/serial/cvsParticle_dns.c index f1ef964ffd..d94c9c090b 100644 --- a/examples/cvodes/serial/cvsParticle_dns.c +++ b/examples/cvodes/serial/cvsParticle_dns.c @@ -46,11 +46,9 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* Precision specific math function macros */ diff --git a/examples/cvodes/serial/cvsPendulum_dns.c b/examples/cvodes/serial/cvsPendulum_dns.c index 7afaf3381c..b2d6cd24f1 100644 --- a/examples/cvodes/serial/cvsPendulum_dns.c +++ b/examples/cvodes/serial/cvsPendulum_dns.c @@ -67,13 +67,9 @@ /* Precision specific formatting macros */ #if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else -#define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* Precision specific math function macros */ diff --git a/examples/cvodes/serial/cvsRoberts_FSA_dns.c b/examples/cvodes/serial/cvsRoberts_FSA_dns.c index d4d12969ad..f821b41b56 100644 --- a/examples/cvodes/serial/cvsRoberts_FSA_dns.c +++ b/examples/cvodes/serial/cvsRoberts_FSA_dns.c @@ -103,7 +103,6 @@ #define TMULT SUN_RCONST(10.0) /* output time factor */ #define NOUT 12 /* number of output times */ -#define NP 3 /* number of problem parameters */ #define NS 3 /* number of sensitivities computed */ #define ZERO SUN_RCONST(0.0) diff --git a/examples/cvodes/serial/cvsRoberts_FSA_dns_Switch.c b/examples/cvodes/serial/cvsRoberts_FSA_dns_Switch.c index 1b31f9d990..224d410832 100644 --- a/examples/cvodes/serial/cvsRoberts_FSA_dns_Switch.c +++ b/examples/cvodes/serial/cvsRoberts_FSA_dns_Switch.c @@ -37,13 +37,9 @@ #include /* access to dense SUNMatrix */ #if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else -#define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* Problem Constants */ diff --git a/examples/cvodes/serial/cvsRoberts_FSA_dns_constraints.c b/examples/cvodes/serial/cvsRoberts_FSA_dns_constraints.c index cfa6511321..e8aed4a029 100644 --- a/examples/cvodes/serial/cvsRoberts_FSA_dns_constraints.c +++ b/examples/cvodes/serial/cvsRoberts_FSA_dns_constraints.c @@ -96,7 +96,6 @@ #define TMULT SUN_RCONST(10.0) /* output time factor */ #define NOUT 12 /* number of output times */ -#define NP 3 /* number of problem parameters */ #define NS 3 /* number of sensitivities computed */ #define ZERO SUN_RCONST(0.0) diff --git a/examples/cvodes/serial/cvsRoberts_FSA_klu.c b/examples/cvodes/serial/cvsRoberts_FSA_klu.c index 43fe375431..56959df66a 100644 --- a/examples/cvodes/serial/cvsRoberts_FSA_klu.c +++ b/examples/cvodes/serial/cvsRoberts_FSA_klu.c @@ -88,7 +88,6 @@ #define TMULT SUN_RCONST(10.0) /* output time factor */ #define NOUT 12 /* number of output times */ -#define NP 3 /* number of problem parameters */ #define NS 3 /* number of sensitivities computed */ #define ZERO SUN_RCONST(0.0) diff --git a/examples/cvodes/serial/cvsRoberts_FSA_sps.c b/examples/cvodes/serial/cvsRoberts_FSA_sps.c index 3db757cb1c..7738f049a2 100644 --- a/examples/cvodes/serial/cvsRoberts_FSA_sps.c +++ b/examples/cvodes/serial/cvsRoberts_FSA_sps.c @@ -88,7 +88,6 @@ #define TMULT SUN_RCONST(10.0) /* output time factor */ #define NOUT 12 /* number of output times */ -#define NP 3 /* number of problem parameters */ #define NS 3 /* number of sensitivities computed */ #define ZERO SUN_RCONST(0.0) diff --git a/examples/cvodes/serial/cvsRoberts_dns.c b/examples/cvodes/serial/cvsRoberts_dns.c index b5d069ca81..a887d5e068 100644 --- a/examples/cvodes/serial/cvsRoberts_dns.c +++ b/examples/cvodes/serial/cvsRoberts_dns.c @@ -41,12 +41,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* User-defined vector and matrix accessor macros: Ith, IJth */ diff --git a/examples/cvodes/serial/cvsRoberts_dns_constraints.c b/examples/cvodes/serial/cvsRoberts_dns_constraints.c index 12ea2aefd2..49718543e7 100644 --- a/examples/cvodes/serial/cvsRoberts_dns_constraints.c +++ b/examples/cvodes/serial/cvsRoberts_dns_constraints.c @@ -43,12 +43,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* User-defined vector and matrix accessor macros: Ith, IJth */ diff --git a/examples/cvodes/serial/cvsRoberts_klu.c b/examples/cvodes/serial/cvsRoberts_klu.c index 624552f954..eb8ff8ee3b 100644 --- a/examples/cvodes/serial/cvsRoberts_klu.c +++ b/examples/cvodes/serial/cvsRoberts_klu.c @@ -67,8 +67,6 @@ #define TMULT SUN_RCONST(10.0) /* output time factor */ #define NOUT 12 /* number of output times */ -#define ZERO SUN_RCONST(0.0) - /* Functions Called by the Solver */ static int f(sunrealtype t, N_Vector y, N_Vector ydot, void* user_data); diff --git a/examples/cvodes/serial/cvsRoberts_sps.c b/examples/cvodes/serial/cvsRoberts_sps.c index 08fadf3229..369d8a17fd 100644 --- a/examples/cvodes/serial/cvsRoberts_sps.c +++ b/examples/cvodes/serial/cvsRoberts_sps.c @@ -67,8 +67,6 @@ #define TMULT SUN_RCONST(10.0) /* output time factor */ #define NOUT 12 /* number of output times */ -#define ZERO SUN_RCONST(0.0) - /* Functions Called by the Solver */ static int f(sunrealtype t, N_Vector y, N_Vector ydot, void* user_data); diff --git a/examples/ida/parallel/idaFoodWeb_kry_bbd_p.c b/examples/ida/parallel/idaFoodWeb_kry_bbd_p.c index e60fe3d7be..1924030b01 100644 --- a/examples/ida/parallel/idaFoodWeb_kry_bbd_p.c +++ b/examples/ida/parallel/idaFoodWeb_kry_bbd_p.c @@ -1029,7 +1029,6 @@ static void BSend(MPI_Comm comm, int my_pe, int ixsub, int jysub, int dsizex, #define rhs (webdata->rhs) #define cext (webdata->cext) #define rates (webdata->rates) -#define ns (webdata->ns) #define acoef (webdata->acoef) #define bcoef (webdata->bcoef) diff --git a/examples/ida/serial/idaRoberts_dns.c b/examples/ida/serial/idaRoberts_dns.c index c235c210ec..2fb58c9e2c 100644 --- a/examples/ida/serial/idaRoberts_dns.c +++ b/examples/ida/serial/idaRoberts_dns.c @@ -44,12 +44,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* Problem Constants */ diff --git a/examples/ida/serial/idaSlCrank_dns.c b/examples/ida/serial/idaSlCrank_dns.c index 324c0bafff..afdc050c1d 100644 --- a/examples/ida/serial/idaSlCrank_dns.c +++ b/examples/ida/serial/idaSlCrank_dns.c @@ -38,7 +38,6 @@ #define NOUT 41 #define ZERO SUN_RCONST(0.0) -#define HALF SUN_RCONST(0.5) #define ONE SUN_RCONST(1.0) #define TWO SUN_RCONST(2.0) #define FOUR SUN_RCONST(4.0) diff --git a/examples/idas/parallel/idasBruss_ASAp_kry_bbd_p.c b/examples/idas/parallel/idasBruss_ASAp_kry_bbd_p.c index b44eb9029c..685a6e6273 100644 --- a/examples/idas/parallel/idasBruss_ASAp_kry_bbd_p.c +++ b/examples/idas/parallel/idasBruss_ASAp_kry_bbd_p.c @@ -1231,11 +1231,8 @@ static void BSend(MPI_Comm comm, int my_pe, int ixsub, int jysub, int dsizex, #define nsmxsub2 (data->nsmxsub2) #define dx (data->dx) #define dy (data->dy) -#define cox (data->cox) -#define coy (data->coy) #define gridext (data->gridext) #define eps (data->eps) -#define ns (data->ns) /* * reslocal: Compute res = F(t,uv,uvp). diff --git a/examples/idas/parallel/idasBruss_FSA_kry_bbd_p.c b/examples/idas/parallel/idasBruss_FSA_kry_bbd_p.c index 06fef2f5e7..61c993e457 100644 --- a/examples/idas/parallel/idasBruss_FSA_kry_bbd_p.c +++ b/examples/idas/parallel/idasBruss_FSA_kry_bbd_p.c @@ -1057,11 +1057,8 @@ static void BSend(MPI_Comm comm, int my_pe, int ixsub, int jysub, int dsizex, #define nsmxsub2 (data->nsmxsub2) #define dx (data->dx) #define dy (data->dy) -#define cox (data->cox) -#define coy (data->coy) #define gridext (data->gridext) #define eps (data->eps) -#define ns (data->ns) /* * reslocal: Compute res = F(t,uv,uvp). diff --git a/examples/idas/parallel/idasBruss_kry_bbd_p.c b/examples/idas/parallel/idasBruss_kry_bbd_p.c index 6e98a00b87..b2370e833d 100644 --- a/examples/idas/parallel/idasBruss_kry_bbd_p.c +++ b/examples/idas/parallel/idasBruss_kry_bbd_p.c @@ -977,11 +977,8 @@ static void BSend(MPI_Comm comm, int my_pe, int ixsub, int jysub, int dsizex, #define nsmxsub2 (data->nsmxsub2) #define dx (data->dx) #define dy (data->dy) -#define cox (data->cox) -#define coy (data->coy) #define gridext (data->gridext) #define eps (data->eps) -#define ns (data->ns) /* * reslocal: Compute res = F(t,uv,uvp). diff --git a/examples/idas/parallel/idasFoodWeb_kry_bbd_p.c b/examples/idas/parallel/idasFoodWeb_kry_bbd_p.c index f5f848bcdf..b30b8c2b00 100644 --- a/examples/idas/parallel/idasFoodWeb_kry_bbd_p.c +++ b/examples/idas/parallel/idasFoodWeb_kry_bbd_p.c @@ -1029,7 +1029,6 @@ static void BSend(MPI_Comm comm, int my_pe, int ixsub, int jysub, int dsizex, #define rhs (webdata->rhs) #define cext (webdata->cext) #define rates (webdata->rates) -#define ns (webdata->ns) #define acoef (webdata->acoef) #define bcoef (webdata->bcoef) diff --git a/examples/idas/serial/idasRoberts_FSA_dns.c b/examples/idas/serial/idasRoberts_FSA_dns.c index 3a149b0583..1c506d86fd 100644 --- a/examples/idas/serial/idasRoberts_FSA_dns.c +++ b/examples/idas/serial/idasRoberts_FSA_dns.c @@ -65,7 +65,6 @@ #define TMULT SUN_RCONST(10.0) /* output time factor */ #define NOUT 12 /* number of output times */ -#define NP 3 /* number of problem parameters */ #define NS 3 /* number of sensitivities computed */ #define ZERO SUN_RCONST(0.0) diff --git a/examples/idas/serial/idasRoberts_FSA_klu.c b/examples/idas/serial/idasRoberts_FSA_klu.c index 911b82056e..5c0e8ac159 100644 --- a/examples/idas/serial/idasRoberts_FSA_klu.c +++ b/examples/idas/serial/idasRoberts_FSA_klu.c @@ -69,7 +69,6 @@ #define TMULT SUN_RCONST(10.0) /* output time factor */ #define NOUT 12 /* number of output times */ -#define NP 3 /* number of problem parameters */ #define NS 3 /* number of sensitivities computed */ #define ZERO SUN_RCONST(0.0) diff --git a/examples/idas/serial/idasRoberts_FSA_sps.c b/examples/idas/serial/idasRoberts_FSA_sps.c index 0843b74b48..d4d0fc2d64 100644 --- a/examples/idas/serial/idasRoberts_FSA_sps.c +++ b/examples/idas/serial/idasRoberts_FSA_sps.c @@ -69,7 +69,6 @@ #define TMULT SUN_RCONST(10.0) /* output time factor */ #define NOUT 12 /* number of output times */ -#define NP 3 /* number of problem parameters */ #define NS 3 /* number of sensitivities computed */ #define ZERO SUN_RCONST(0.0) diff --git a/examples/idas/serial/idasRoberts_dns.c b/examples/idas/serial/idasRoberts_dns.c index 2594ba2a1c..03dfdbe1b2 100644 --- a/examples/idas/serial/idasRoberts_dns.c +++ b/examples/idas/serial/idasRoberts_dns.c @@ -44,12 +44,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* Problem Constants */ diff --git a/examples/idas/serial/idasSlCrank_FSA_dns.c b/examples/idas/serial/idasSlCrank_FSA_dns.c index a072368a0c..424427e58e 100644 --- a/examples/idas/serial/idasSlCrank_FSA_dns.c +++ b/examples/idas/serial/idasSlCrank_FSA_dns.c @@ -57,12 +57,11 @@ #define RTOLFD SUN_RCONST(1.0e-06) #define ATOLFD SUN_RCONST(1.0e-08) -#define ZERO SUN_RCONST(0.00) -#define QUARTER SUN_RCONST(0.25) -#define HALF SUN_RCONST(0.50) -#define ONE SUN_RCONST(1.00) -#define TWO SUN_RCONST(2.00) -#define FOUR SUN_RCONST(4.00) +#define ZERO SUN_RCONST(0.00) +#define HALF SUN_RCONST(0.50) +#define ONE SUN_RCONST(1.00) +#define TWO SUN_RCONST(2.00) +#define FOUR SUN_RCONST(4.00) typedef struct { diff --git a/examples/idas/serial/idasSlCrank_dns.c b/examples/idas/serial/idasSlCrank_dns.c index c606001c66..b8d7eeb18e 100644 --- a/examples/idas/serial/idasSlCrank_dns.c +++ b/examples/idas/serial/idasSlCrank_dns.c @@ -54,12 +54,11 @@ #define RTOLQ SUN_RCONST(1.0e-06) #define ATOLQ SUN_RCONST(1.0e-08) -#define ZERO SUN_RCONST(0.00) -#define QUARTER SUN_RCONST(0.25) -#define HALF SUN_RCONST(0.50) -#define ONE SUN_RCONST(1.00) -#define TWO SUN_RCONST(2.00) -#define FOUR SUN_RCONST(4.00) +#define ZERO SUN_RCONST(0.00) +#define HALF SUN_RCONST(0.50) +#define ONE SUN_RCONST(1.00) +#define TWO SUN_RCONST(2.00) +#define FOUR SUN_RCONST(4.00) typedef struct { diff --git a/examples/kinsol/CXX_parallel/kin_heat2D_nonlin_p.hpp b/examples/kinsol/CXX_parallel/kin_heat2D_nonlin_p.hpp index 33a70df726..dc6d04ead0 100644 --- a/examples/kinsol/CXX_parallel/kin_heat2D_nonlin_p.hpp +++ b/examples/kinsol/CXX_parallel/kin_heat2D_nonlin_p.hpp @@ -30,12 +30,11 @@ #include "sundials/sundials_core.hpp" // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define HALF SUN_RCONST(0.5) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define HALF SUN_RCONST(0.5) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/kinsol/CXX_parhyp/kin_bratu2D_hypre_pfmg.hpp b/examples/kinsol/CXX_parhyp/kin_bratu2D_hypre_pfmg.hpp index b527b19b43..aeab4550e7 100644 --- a/examples/kinsol/CXX_parhyp/kin_bratu2D_hypre_pfmg.hpp +++ b/examples/kinsol/CXX_parhyp/kin_bratu2D_hypre_pfmg.hpp @@ -31,12 +31,11 @@ #include "sunlinsol/sunlinsol_pcg.h" // access to PCG SUNLinearSolver // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define SIX SUN_RCONST(6.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) +#define SIX SUN_RCONST(6.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/kinsol/CXX_parhyp/kin_heat2D_nonlin_hypre_pfmg.hpp b/examples/kinsol/CXX_parhyp/kin_heat2D_nonlin_hypre_pfmg.hpp index f156d8c7a3..6de6fea6f4 100644 --- a/examples/kinsol/CXX_parhyp/kin_heat2D_nonlin_hypre_pfmg.hpp +++ b/examples/kinsol/CXX_parhyp/kin_heat2D_nonlin_hypre_pfmg.hpp @@ -32,11 +32,10 @@ #include "sunlinsol/sunlinsol_pcg.h" // access to PCG SUNLinearSolver // Macros for problem constants -#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) -#define EIGHT SUN_RCONST(8.0) +#define PI SUN_RCONST(3.141592653589793238462643383279502884197169) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) +#define TWO SUN_RCONST(2.0) // Macro to access (x,y) location in 1D NVector array #define IDX(x, y, n) ((n) * (y) + (x)) diff --git a/examples/kinsol/C_openmp/kinFoodWeb_kry_omp.c b/examples/kinsol/C_openmp/kinFoodWeb_kry_omp.c index 3ca40e26e6..d86aa44d7e 100644 --- a/examples/kinsol/C_openmp/kinFoodWeb_kry_omp.c +++ b/examples/kinsol/C_openmp/kinFoodWeb_kry_omp.c @@ -123,8 +123,6 @@ 6 /* must equal 2*(number of prey or predators) number of prey = number of predators */ -#define PI SUN_RCONST(3.1415926535898) /* pi */ - #define MX 8 /* MX = number of x mesh points */ #define MY 8 /* MY = number of y mesh points */ #define NSMX (NUM_SPECIES * MX) diff --git a/examples/kinsol/parallel/kinFoodWeb_kry_bbd_p.c b/examples/kinsol/parallel/kinFoodWeb_kry_bbd_p.c index 9eb367f401..b519d8cca6 100644 --- a/examples/kinsol/parallel/kinFoodWeb_kry_bbd_p.c +++ b/examples/kinsol/parallel/kinFoodWeb_kry_bbd_p.c @@ -106,8 +106,6 @@ 6 /* must equal 2*(number of prey or predators) number of prey = number of predators */ -#define PI SUN_RCONST(3.1415926535898) /* pi */ - #define NPEX 2 /* number of processors in the x-direction */ #define NPEY 2 /* number of processors in the y-direction */ #define MXSUB 10 /* number of x mesh points per subgrid */ @@ -128,7 +126,6 @@ #define AY SUN_RCONST(1.0) /* total range of y variable */ #define FTOL SUN_RCONST(1.e-7) /* ftol tolerance */ #define STOL SUN_RCONST(1.e-13) /* stol tolerance */ -#define THOUSAND SUN_RCONST(1000.0) /* one thousand */ #define ZERO SUN_RCONST(0.0) /* 0. */ #define ONE SUN_RCONST(1.0) /* 1. */ #define PREYIN SUN_RCONST(1.0) /* initial guess for prey concentrations. */ diff --git a/examples/kinsol/parallel/kinFoodWeb_kry_p.c b/examples/kinsol/parallel/kinFoodWeb_kry_p.c index b1c2ce3868..14c5c834d3 100644 --- a/examples/kinsol/parallel/kinFoodWeb_kry_p.c +++ b/examples/kinsol/parallel/kinFoodWeb_kry_p.c @@ -105,8 +105,6 @@ 6 /* must equal 2*(number of prey or predators) number of prey = number of predators */ -#define PI SUN_RCONST(3.1415926535898) /* pi */ - #define NPEX 2 /* number of processors in the x-direction */ #define NPEY 2 /* number of processors in the y-direction */ #define MXSUB 10 /* number of x mesh points per subgrid */ diff --git a/examples/kinsol/serial/kinAnalytic_fp.c b/examples/kinsol/serial/kinAnalytic_fp.c index de44dc35be..cae597f618 100644 --- a/examples/kinsol/serial/kinAnalytic_fp.c +++ b/examples/kinsol/serial/kinAnalytic_fp.c @@ -38,12 +38,8 @@ /* precision specific formatting macros */ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* precision specific math function macros */ @@ -70,21 +66,17 @@ /* problem constants */ #define NEQ 3 /* number of equations */ -#define ZERO SUN_RCONST(0.0) /* real 0.0 */ #define PTONE SUN_RCONST(0.1) /* real 0.1 */ #define HALF SUN_RCONST(0.5) /* real 0.5 */ #define PTNINE SUN_RCONST(0.9) /* real 0.9 */ #define ONE SUN_RCONST(1.0) /* real 1.0 */ #define ONEPTZEROSIX SUN_RCONST(1.06) /* real 1.06 */ -#define ONEPTONE SUN_RCONST(1.1) /* real 1.1 */ #define THREE SUN_RCONST(3.0) /* real 3.0 */ -#define FOUR SUN_RCONST(4.0) /* real 4.0 */ #define SIX SUN_RCONST(6.0) /* real 6.0 */ #define NINE SUN_RCONST(9.0) /* real 9.0 */ #define TEN SUN_RCONST(10.0) /* real 10.0 */ #define TWENTY SUN_RCONST(20.0) /* real 20.0 */ #define SIXTY SUN_RCONST(60.0) /* real 60.0 */ -#define EIGHTYONE SUN_RCONST(81.0) /* real 81.0 */ #define PI SUN_RCONST(3.1415926535898) /* real pi */ /* analytic solution */ diff --git a/examples/kinsol/serial/kinFoodWeb_kry.c b/examples/kinsol/serial/kinFoodWeb_kry.c index a60d620238..fdc20e941b 100644 --- a/examples/kinsol/serial/kinFoodWeb_kry.c +++ b/examples/kinsol/serial/kinFoodWeb_kry.c @@ -99,8 +99,6 @@ 6 /* must equal 2*(number of prey or predators) number of prey = number of predators */ -#define PI SUN_RCONST(3.1415926535898) /* pi */ - #define MX 8 /* MX = number of x mesh points */ #define MY 8 /* MY = number of y mesh points */ #define NSMX (NUM_SPECIES * MX) diff --git a/examples/kinsol/serial/kinKrylovDemo_ls.c b/examples/kinsol/serial/kinKrylovDemo_ls.c index 1647da2297..ceaecd81bd 100644 --- a/examples/kinsol/serial/kinKrylovDemo_ls.c +++ b/examples/kinsol/serial/kinKrylovDemo_ls.c @@ -111,8 +111,6 @@ 6 /* must equal 2*(number of prey or predators) number of prey = number of predators */ -#define PI SUN_RCONST(3.1415926535898) /* pi */ - #define MX 5 /* MX = number of x mesh points */ #define MY 5 /* MY = number of y mesh points */ #define NSMX (NUM_SPECIES * MX) diff --git a/examples/kinsol/serial/kinRoberts_fp.c b/examples/kinsol/serial/kinRoberts_fp.c index 3cc777e1a1..7d1b4f0d58 100644 --- a/examples/kinsol/serial/kinRoberts_fp.c +++ b/examples/kinsol/serial/kinRoberts_fp.c @@ -37,12 +37,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* Problem Constants */ diff --git a/src/arkode/arkode_arkstep.c b/src/arkode/arkode_arkstep.c index 5ede13165c..50641020c3 100644 --- a/src/arkode/arkode_arkstep.c +++ b/src/arkode/arkode_arkstep.c @@ -28,8 +28,6 @@ #include "arkode_interp_impl.h" #include "sundials/sundials_types.h" -#define FIXED_LIN_TOL - /*=============================================================== Exported functions ===============================================================*/ diff --git a/src/arkode/fmod_int32/CMakeLists.txt b/src/arkode/fmod_int32/CMakeLists.txt index 4ae3e19a54..9272ae605f 100644 --- a/src/arkode/fmod_int32/CMakeLists.txt +++ b/src/arkode/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 ARKODE object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(arkode_SOURCES farkode_mod.f90 farkode_mod.c diff --git a/src/arkode/fmod_int64/CMakeLists.txt b/src/arkode/fmod_int64/CMakeLists.txt index 4ae3e19a54..9272ae605f 100644 --- a/src/arkode/fmod_int64/CMakeLists.txt +++ b/src/arkode/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 ARKODE object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(arkode_SOURCES farkode_mod.f90 farkode_mod.c diff --git a/src/cvode/cvode_diag.c b/src/cvode/cvode_diag.c index 25af67fbe9..3c43d3469b 100644 --- a/src/cvode/cvode_diag.c +++ b/src/cvode/cvode_diag.c @@ -43,24 +43,22 @@ static int CVDiagFree(CVodeMem cv_mem); /* Readability Replacements */ -#define lrw1 (cv_mem->cv_lrw1) -#define liw1 (cv_mem->cv_liw1) -#define f (cv_mem->cv_f) -#define uround (cv_mem->cv_uround) -#define tn (cv_mem->cv_tn) -#define h (cv_mem->cv_h) -#define rl1 (cv_mem->cv_rl1) -#define gamma (cv_mem->cv_gamma) -#define ewt (cv_mem->cv_ewt) -#define nfe (cv_mem->cv_nfe) -#define zn (cv_mem->cv_zn) -#define linit (cv_mem->cv_linit) -#define lsetup (cv_mem->cv_lsetup) -#define lsolve (cv_mem->cv_lsolve) -#define lfree (cv_mem->cv_lfree) -#define lmem (cv_mem->cv_lmem) -#define vec_tmpl (cv_mem->cv_tempv) -#define setupNonNull (cv_mem->cv_setupNonNull) +#define lrw1 (cv_mem->cv_lrw1) +#define liw1 (cv_mem->cv_liw1) +#define f (cv_mem->cv_f) +#define uround (cv_mem->cv_uround) +#define tn (cv_mem->cv_tn) +#define h (cv_mem->cv_h) +#define rl1 (cv_mem->cv_rl1) +#define gamma (cv_mem->cv_gamma) +#define ewt (cv_mem->cv_ewt) +#define zn (cv_mem->cv_zn) +#define linit (cv_mem->cv_linit) +#define lsetup (cv_mem->cv_lsetup) +#define lsolve (cv_mem->cv_lsolve) +#define lfree (cv_mem->cv_lfree) +#define lmem (cv_mem->cv_lmem) +#define vec_tmpl (cv_mem->cv_tempv) #define gammasv (cvdiag_mem->di_gammasv) #define M (cvdiag_mem->di_M) diff --git a/src/cvode/fmod_int32/CMakeLists.txt b/src/cvode/fmod_int32/CMakeLists.txt index 38581e558f..0add79ca24 100644 --- a/src/cvode/fmod_int32/CMakeLists.txt +++ b/src/cvode/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 CVODE object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(cvode_SOURCES fcvode_mod.f90 fcvode_mod.c) # Create the library diff --git a/src/cvode/fmod_int64/CMakeLists.txt b/src/cvode/fmod_int64/CMakeLists.txt index 38581e558f..0add79ca24 100644 --- a/src/cvode/fmod_int64/CMakeLists.txt +++ b/src/cvode/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 CVODE object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(cvode_SOURCES fcvode_mod.f90 fcvode_mod.c) # Create the library diff --git a/src/cvodes/cvodea.c b/src/cvodes/cvodea.c index 0365c56a59..e5e22f0e33 100644 --- a/src/cvodes/cvodea.c +++ b/src/cvodes/cvodea.c @@ -45,7 +45,9 @@ /* Shortcuts */ /*=================================================================*/ +#if defined(SUNDIALS_BUILD_WITH_PROFILING) #define CV_PROFILER cv_mem->cv_sunctx->profiler +#endif /* * ================================================================= diff --git a/src/cvodes/cvodes_diag.c b/src/cvodes/cvodes_diag.c index 857a81bf73..f51cedfdea 100644 --- a/src/cvodes/cvodes_diag.c +++ b/src/cvodes/cvodes_diag.c @@ -50,24 +50,22 @@ static int CVDiagFree(CVodeMem cv_mem); /* Readability Replacements */ -#define lrw1 (cv_mem->cv_lrw1) -#define liw1 (cv_mem->cv_liw1) -#define f (cv_mem->cv_f) -#define uround (cv_mem->cv_uround) -#define tn (cv_mem->cv_tn) -#define h (cv_mem->cv_h) -#define rl1 (cv_mem->cv_rl1) -#define gamma (cv_mem->cv_gamma) -#define ewt (cv_mem->cv_ewt) -#define nfe (cv_mem->cv_nfe) -#define zn (cv_mem->cv_zn) -#define linit (cv_mem->cv_linit) -#define lsetup (cv_mem->cv_lsetup) -#define lsolve (cv_mem->cv_lsolve) -#define lfree (cv_mem->cv_lfree) -#define lmem (cv_mem->cv_lmem) -#define vec_tmpl (cv_mem->cv_tempv) -#define setupNonNull (cv_mem->cv_setupNonNull) +#define lrw1 (cv_mem->cv_lrw1) +#define liw1 (cv_mem->cv_liw1) +#define f (cv_mem->cv_f) +#define uround (cv_mem->cv_uround) +#define tn (cv_mem->cv_tn) +#define h (cv_mem->cv_h) +#define rl1 (cv_mem->cv_rl1) +#define gamma (cv_mem->cv_gamma) +#define ewt (cv_mem->cv_ewt) +#define zn (cv_mem->cv_zn) +#define linit (cv_mem->cv_linit) +#define lsetup (cv_mem->cv_lsetup) +#define lsolve (cv_mem->cv_lsolve) +#define lfree (cv_mem->cv_lfree) +#define lmem (cv_mem->cv_lmem) +#define vec_tmpl (cv_mem->cv_tempv) #define gammasv (cvdiag_mem->di_gammasv) #define M (cvdiag_mem->di_M) diff --git a/src/cvodes/fmod_int32/CMakeLists.txt b/src/cvodes/fmod_int32/CMakeLists.txt index 100a28feed..94031156c9 100644 --- a/src/cvodes/fmod_int32/CMakeLists.txt +++ b/src/cvodes/fmod_int32/CMakeLists.txt @@ -13,6 +13,12 @@ # --------------------------------------------------------------- # CMakeLists.txt file for the F2003 cvodes object library +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(cvodes_SOURCES fcvodes_mod.f90 fcvodes_mod.c) # Create the library diff --git a/src/cvodes/fmod_int64/CMakeLists.txt b/src/cvodes/fmod_int64/CMakeLists.txt index 100a28feed..94031156c9 100644 --- a/src/cvodes/fmod_int64/CMakeLists.txt +++ b/src/cvodes/fmod_int64/CMakeLists.txt @@ -13,6 +13,12 @@ # --------------------------------------------------------------- # CMakeLists.txt file for the F2003 cvodes object library +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(cvodes_SOURCES fcvodes_mod.f90 fcvodes_mod.c) # Create the library diff --git a/src/ida/fmod_int32/CMakeLists.txt b/src/ida/fmod_int32/CMakeLists.txt index 928acaa4a5..67625d95d1 100644 --- a/src/ida/fmod_int32/CMakeLists.txt +++ b/src/ida/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 IDA object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(ida_SOURCES fida_mod.f90 fida_mod.c) # Create the library diff --git a/src/ida/fmod_int64/CMakeLists.txt b/src/ida/fmod_int64/CMakeLists.txt index 928acaa4a5..67625d95d1 100644 --- a/src/ida/fmod_int64/CMakeLists.txt +++ b/src/ida/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 IDA object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(ida_SOURCES fida_mod.f90 fida_mod.c) # Create the library diff --git a/src/ida/ida.c b/src/ida/ida.c index dec79e41d2..55a848d0b9 100644 --- a/src/ida/ida.c +++ b/src/ida/ida.c @@ -106,11 +106,9 @@ #define FOUR SUN_RCONST(4.0) /* real 4.0 */ #define FIVE SUN_RCONST(5.0) /* real 5.0 */ #define TEN SUN_RCONST(10.0) /* real 10.0 */ -#define TWELVE SUN_RCONST(12.0) /* real 12.0 */ #define TWENTY SUN_RCONST(20.0) /* real 20.0 */ #define HUNDRED SUN_RCONST(100.0) /* real 100.0 */ #define PT9 SUN_RCONST(0.9) /* real 0.9 */ -#define PT99 SUN_RCONST(0.99) /* real 0.99 */ #define PT1 SUN_RCONST(0.1) /* real 0.1 */ #define PT01 SUN_RCONST(0.01) /* real 0.01 */ #define PT001 SUN_RCONST(0.001) /* real 0.001 */ diff --git a/src/idas/fmod_int32/CMakeLists.txt b/src/idas/fmod_int32/CMakeLists.txt index 5db3a92327..2fd057ab41 100644 --- a/src/idas/fmod_int32/CMakeLists.txt +++ b/src/idas/fmod_int32/CMakeLists.txt @@ -13,6 +13,12 @@ # --------------------------------------------------------------- # CMakeLists.txt file for the F2003 IDAS object library +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(idas_SOURCES fidas_mod.f90 fidas_mod.c) # Create the library diff --git a/src/idas/fmod_int64/CMakeLists.txt b/src/idas/fmod_int64/CMakeLists.txt index 5db3a92327..2fd057ab41 100644 --- a/src/idas/fmod_int64/CMakeLists.txt +++ b/src/idas/fmod_int64/CMakeLists.txt @@ -13,6 +13,12 @@ # --------------------------------------------------------------- # CMakeLists.txt file for the F2003 IDAS object library +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(idas_SOURCES fidas_mod.f90 fidas_mod.c) # Create the library diff --git a/src/idas/idaa.c b/src/idas/idaa.c index 486afee06c..6093f25ae2 100644 --- a/src/idas/idaa.c +++ b/src/idas/idaa.c @@ -40,7 +40,9 @@ /* Shortcuts */ /*=================================================================*/ +#if defined(SUNDIALS_BUILD_WITH_PROFILING) #define IDA_PROFILER IDA_mem->ida_sunctx->profiler +#endif /*=================================================================*/ /* Private Functions Prototypes */ diff --git a/src/idas/idas.c b/src/idas/idas.c index 801da28527..a86c7f0b50 100644 --- a/src/idas/idas.c +++ b/src/idas/idas.c @@ -164,11 +164,9 @@ #define FOUR SUN_RCONST(4.0) /* real 4.0 */ #define FIVE SUN_RCONST(5.0) /* real 5.0 */ #define TEN SUN_RCONST(10.0) /* real 10.0 */ -#define TWELVE SUN_RCONST(12.0) /* real 12.0 */ #define TWENTY SUN_RCONST(20.0) /* real 20.0 */ #define HUNDRED SUN_RCONST(100.0) /* real 100.0 */ #define PT9 SUN_RCONST(0.9) /* real 0.9 */ -#define PT99 SUN_RCONST(0.99) /* real 0.99 */ #define PT1 SUN_RCONST(0.1) /* real 0.1 */ #define PT01 SUN_RCONST(0.01) /* real 0.01 */ #define PT001 SUN_RCONST(0.001) /* real 0.001 */ diff --git a/src/idas/idas_nls_stg.c b/src/idas/idas_nls_stg.c index 3e1590c780..379658e74d 100644 --- a/src/idas/idas_nls_stg.c +++ b/src/idas/idas_nls_stg.c @@ -19,9 +19,8 @@ #include "sundials/sundials_nvector_senswrapper.h" /* constant macros */ -#define PT0001 SUN_RCONST(0.0001) /* real 0.0001 */ -#define ONE SUN_RCONST(1.0) /* real 1.0 */ -#define TWENTY SUN_RCONST(20.0) /* real 20.0 */ +#define ONE SUN_RCONST(1.0) /* real 1.0 */ +#define TWENTY SUN_RCONST(20.0) /* real 20.0 */ /* nonlinear solver parameters */ #define MAXIT 4 /* default max number of nonlinear iterations */ diff --git a/src/kinsol/fmod_int32/CMakeLists.txt b/src/kinsol/fmod_int32/CMakeLists.txt index 8f127375de..2d02aa82a6 100644 --- a/src/kinsol/fmod_int32/CMakeLists.txt +++ b/src/kinsol/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 KINSOL object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(kinsol_SOURCES fkinsol_mod.f90 fkinsol_mod.c) # Create the library diff --git a/src/kinsol/fmod_int64/CMakeLists.txt b/src/kinsol/fmod_int64/CMakeLists.txt index 8f127375de..2d02aa82a6 100644 --- a/src/kinsol/fmod_int64/CMakeLists.txt +++ b/src/kinsol/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 KINSOL object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(kinsol_SOURCES fkinsol_mod.f90 fkinsol_mod.c) # Create the library diff --git a/src/kinsol/kinsol.c b/src/kinsol/kinsol.c index 7d603d5fad..a8f29044c5 100644 --- a/src/kinsol/kinsol.c +++ b/src/kinsol/kinsol.c @@ -154,7 +154,9 @@ /* Shortcuts */ /*=================================================================*/ +#if defined(SUNDIALS_BUILD_WITH_PROFILING) #define KIN_PROFILER kin_mem->kin_sunctx->profiler +#endif /* * ================================================================= diff --git a/src/kinsol/kinsol_io.c b/src/kinsol/kinsol_io.c index 0b64de5359..a9a6b29231 100644 --- a/src/kinsol/kinsol_io.c +++ b/src/kinsol/kinsol_io.c @@ -28,7 +28,6 @@ #define ZERO SUN_RCONST(0.0) #define POINT1 SUN_RCONST(0.1) #define ONETHIRD SUN_RCONST(0.3333333333333333) -#define HALF SUN_RCONST(0.5) #define TWOTHIRDS SUN_RCONST(0.6666666666666667) #define POINT9 SUN_RCONST(0.9) #define ONE SUN_RCONST(1.0) diff --git a/src/kinsol/kinsol_ls.c b/src/kinsol/kinsol_ls.c index a13fef09f8..c716beaa82 100644 --- a/src/kinsol/kinsol_ls.c +++ b/src/kinsol/kinsol_ls.c @@ -28,10 +28,8 @@ #include "kinsol_ls_impl.h" /* constants */ -#define MIN_INC_MULT SUN_RCONST(1000.0) -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) /*================================================================== KINLS Exported functions -- Required diff --git a/src/nvector/manyvector/fmod_int32/CMakeLists.txt b/src/nvector/manyvector/fmod_int32/CMakeLists.txt index 2908e42e37..8040da10b0 100644 --- a/src/nvector/manyvector/fmod_int32/CMakeLists.txt +++ b/src/nvector/manyvector/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 manyvector NVECTOR object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + if(BUILD_NVECTOR_MANYVECTOR) sundials_add_f2003_library( sundials_fnvecmanyvector_mod diff --git a/src/nvector/manyvector/fmod_int64/CMakeLists.txt b/src/nvector/manyvector/fmod_int64/CMakeLists.txt index 2908e42e37..8040da10b0 100644 --- a/src/nvector/manyvector/fmod_int64/CMakeLists.txt +++ b/src/nvector/manyvector/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 manyvector NVECTOR object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + if(BUILD_NVECTOR_MANYVECTOR) sundials_add_f2003_library( sundials_fnvecmanyvector_mod diff --git a/src/nvector/manyvector/nvector_manyvector.c b/src/nvector/manyvector/nvector_manyvector.c index 31c74c78da..b318b04147 100644 --- a/src/nvector/manyvector/nvector_manyvector.c +++ b/src/nvector/manyvector/nvector_manyvector.c @@ -41,7 +41,9 @@ #endif #define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) +#ifdef MANYVECTOR_BUILD_WITH_MPI +#define ONE SUN_RCONST(1.0) +#endif /* ----------------------------------------------------------------- ManyVector content accessor macros diff --git a/src/nvector/mpiplusx/fmod_int32/CMakeLists.txt b/src/nvector/mpiplusx/fmod_int32/CMakeLists.txt index aaa836eba9..08b529126a 100644 --- a/src/nvector/mpiplusx/fmod_int32/CMakeLists.txt +++ b/src/nvector/mpiplusx/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 MPIPlusX NVECTOR object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + if(MPI_C_COMPILER) # use MPI wrapper as the compiler set(CMAKE_C_COMPILER ${MPI_C_COMPILER}) diff --git a/src/nvector/mpiplusx/fmod_int64/CMakeLists.txt b/src/nvector/mpiplusx/fmod_int64/CMakeLists.txt index aaa836eba9..08b529126a 100644 --- a/src/nvector/mpiplusx/fmod_int64/CMakeLists.txt +++ b/src/nvector/mpiplusx/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 MPIPlusX NVECTOR object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + if(MPI_C_COMPILER) # use MPI wrapper as the compiler set(CMAKE_C_COMPILER ${MPI_C_COMPILER}) diff --git a/src/nvector/openmp/fmod_int32/CMakeLists.txt b/src/nvector/openmp/fmod_int32/CMakeLists.txt index 6510270db2..867167cc5d 100644 --- a/src/nvector/openmp/fmod_int32/CMakeLists.txt +++ b/src/nvector/openmp/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 openmp NVECTOR object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fnvecopenmp_mod SOURCES fnvector_openmp_mod.f90 fnvector_openmp_mod.c diff --git a/src/nvector/openmp/fmod_int64/CMakeLists.txt b/src/nvector/openmp/fmod_int64/CMakeLists.txt index 6510270db2..867167cc5d 100644 --- a/src/nvector/openmp/fmod_int64/CMakeLists.txt +++ b/src/nvector/openmp/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 openmp NVECTOR object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fnvecopenmp_mod SOURCES fnvector_openmp_mod.f90 fnvector_openmp_mod.c diff --git a/src/nvector/parallel/fmod_int32/CMakeLists.txt b/src/nvector/parallel/fmod_int32/CMakeLists.txt index 98c301b871..1d0614fa42 100644 --- a/src/nvector/parallel/fmod_int32/CMakeLists.txt +++ b/src/nvector/parallel/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 parallel NVECTOR object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(nvecparallel_SOURCES fnvector_parallel_mod.f90 fnvector_parallel_mod.c) if(MPI_C_COMPILER) diff --git a/src/nvector/parallel/fmod_int64/CMakeLists.txt b/src/nvector/parallel/fmod_int64/CMakeLists.txt index 98c301b871..1d0614fa42 100644 --- a/src/nvector/parallel/fmod_int64/CMakeLists.txt +++ b/src/nvector/parallel/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 parallel NVECTOR object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(nvecparallel_SOURCES fnvector_parallel_mod.f90 fnvector_parallel_mod.c) if(MPI_C_COMPILER) diff --git a/src/nvector/pthreads/fmod_int32/CMakeLists.txt b/src/nvector/pthreads/fmod_int32/CMakeLists.txt index 5fcf786118..7c7281a79b 100644 --- a/src/nvector/pthreads/fmod_int32/CMakeLists.txt +++ b/src/nvector/pthreads/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 Pthreads NVECTOR object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(nvecpthreads_SOURCES fnvector_pthreads_mod.f90 fnvector_pthreads_mod.c) sundials_add_f2003_library( diff --git a/src/nvector/pthreads/fmod_int64/CMakeLists.txt b/src/nvector/pthreads/fmod_int64/CMakeLists.txt index 5fcf786118..7c7281a79b 100644 --- a/src/nvector/pthreads/fmod_int64/CMakeLists.txt +++ b/src/nvector/pthreads/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 Pthreads NVECTOR object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(nvecpthreads_SOURCES fnvector_pthreads_mod.f90 fnvector_pthreads_mod.c) sundials_add_f2003_library( diff --git a/src/nvector/serial/fmod_int32/CMakeLists.txt b/src/nvector/serial/fmod_int32/CMakeLists.txt index fbfc2e3344..1d8a05fc73 100644 --- a/src/nvector/serial/fmod_int32/CMakeLists.txt +++ b/src/nvector/serial/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 serial NVECTOR object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fnvecserial_mod SOURCES fnvector_serial_mod.f90 fnvector_serial_mod.c diff --git a/src/nvector/serial/fmod_int64/CMakeLists.txt b/src/nvector/serial/fmod_int64/CMakeLists.txt index e52f2ae867..3cbab689c0 100644 --- a/src/nvector/serial/fmod_int64/CMakeLists.txt +++ b/src/nvector/serial/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 serial NVECTOR object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fnvecserial_mod SOURCES fnvector_serial_mod.f90 fnvector_serial_mod.c diff --git a/src/nvector/trilinos/nvector_trilinos.cpp b/src/nvector/trilinos/nvector_trilinos.cpp index 85381e0850..c7f7d06c5d 100644 --- a/src/nvector/trilinos/nvector_trilinos.cpp +++ b/src/nvector/trilinos/nvector_trilinos.cpp @@ -27,10 +27,8 @@ #include "sundials_macros.h" -#define ZERO SUN_RCONST(0.0) -#define HALF SUN_RCONST(0.5) -#define ONE SUN_RCONST(1.0) -#define ONEPT5 SUN_RCONST(1.5) +#define ZERO SUN_RCONST(0.0) +#define ONE SUN_RCONST(1.0) /* * ----------------------------------------------------------------- diff --git a/src/sunadaptcontroller/imexgus/fmod_int32/CMakeLists.txt b/src/sunadaptcontroller/imexgus/fmod_int32/CMakeLists.txt index 8fe6e45f40..cc2fd03a01 100644 --- a/src/sunadaptcontroller/imexgus/fmod_int32/CMakeLists.txt +++ b/src/sunadaptcontroller/imexgus/fmod_int32/CMakeLists.txt @@ -12,6 +12,12 @@ # SUNDIALS Copyright End # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunadaptcontrollerimexgus_mod SOURCES fsunadaptcontroller_imexgus_mod.f90 fsunadaptcontroller_imexgus_mod.c diff --git a/src/sunadaptcontroller/imexgus/fmod_int64/CMakeLists.txt b/src/sunadaptcontroller/imexgus/fmod_int64/CMakeLists.txt index 8fe6e45f40..cc2fd03a01 100644 --- a/src/sunadaptcontroller/imexgus/fmod_int64/CMakeLists.txt +++ b/src/sunadaptcontroller/imexgus/fmod_int64/CMakeLists.txt @@ -12,6 +12,12 @@ # SUNDIALS Copyright End # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunadaptcontrollerimexgus_mod SOURCES fsunadaptcontroller_imexgus_mod.f90 fsunadaptcontroller_imexgus_mod.c diff --git a/src/sunadaptcontroller/mrihtol/fmod_int32/CMakeLists.txt b/src/sunadaptcontroller/mrihtol/fmod_int32/CMakeLists.txt index befc6cb2ed..04767bfb2a 100644 --- a/src/sunadaptcontroller/mrihtol/fmod_int32/CMakeLists.txt +++ b/src/sunadaptcontroller/mrihtol/fmod_int32/CMakeLists.txt @@ -12,6 +12,12 @@ # SUNDIALS Copyright End # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunadaptcontrollermrihtol_mod SOURCES fsunadaptcontroller_mrihtol_mod.f90 fsunadaptcontroller_mrihtol_mod.c diff --git a/src/sunadaptcontroller/mrihtol/fmod_int64/CMakeLists.txt b/src/sunadaptcontroller/mrihtol/fmod_int64/CMakeLists.txt index befc6cb2ed..04767bfb2a 100644 --- a/src/sunadaptcontroller/mrihtol/fmod_int64/CMakeLists.txt +++ b/src/sunadaptcontroller/mrihtol/fmod_int64/CMakeLists.txt @@ -12,6 +12,12 @@ # SUNDIALS Copyright End # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunadaptcontrollermrihtol_mod SOURCES fsunadaptcontroller_mrihtol_mod.f90 fsunadaptcontroller_mrihtol_mod.c diff --git a/src/sunadaptcontroller/soderlind/fmod_int32/CMakeLists.txt b/src/sunadaptcontroller/soderlind/fmod_int32/CMakeLists.txt index 81863c3a8c..d9fc3526d3 100644 --- a/src/sunadaptcontroller/soderlind/fmod_int32/CMakeLists.txt +++ b/src/sunadaptcontroller/soderlind/fmod_int32/CMakeLists.txt @@ -12,6 +12,12 @@ # SUNDIALS Copyright End # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunadaptcontrollersoderlind_mod SOURCES fsunadaptcontroller_soderlind_mod.f90 diff --git a/src/sunadaptcontroller/soderlind/fmod_int64/CMakeLists.txt b/src/sunadaptcontroller/soderlind/fmod_int64/CMakeLists.txt index 81863c3a8c..d9fc3526d3 100644 --- a/src/sunadaptcontroller/soderlind/fmod_int64/CMakeLists.txt +++ b/src/sunadaptcontroller/soderlind/fmod_int64/CMakeLists.txt @@ -12,6 +12,12 @@ # SUNDIALS Copyright End # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunadaptcontrollersoderlind_mod SOURCES fsunadaptcontroller_soderlind_mod.f90 diff --git a/src/sundials/fmod_int32/CMakeLists.txt b/src/sundials/fmod_int32/CMakeLists.txt index b9a43aeded..19231349b0 100644 --- a/src/sundials/fmod_int32/CMakeLists.txt +++ b/src/sundials/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 SUNDIALS object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(sundials_SOURCES fsundials_core_mod.c fsundials_core_mod.f90) sundials_add_f2003_library(sundials_fcore_mod SOURCES ${sundials_SOURCES}) diff --git a/src/sundials/fmod_int64/CMakeLists.txt b/src/sundials/fmod_int64/CMakeLists.txt index b9a43aeded..19231349b0 100644 --- a/src/sundials/fmod_int64/CMakeLists.txt +++ b/src/sundials/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 SUNDIALS object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + set(sundials_SOURCES fsundials_core_mod.c fsundials_core_mod.f90) sundials_add_f2003_library(sundials_fcore_mod SOURCES ${sundials_SOURCES}) diff --git a/src/sunlinsol/band/fmod_int32/CMakeLists.txt b/src/sunlinsol/band/fmod_int32/CMakeLists.txt index 4a348ffb70..64f1f4a4bd 100644 --- a/src/sunlinsol/band/fmod_int32/CMakeLists.txt +++ b/src/sunlinsol/band/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 band SUNLinearSolver object library # ---------------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolband_mod SOURCES fsunlinsol_band_mod.f90 fsunlinsol_band_mod.c diff --git a/src/sunlinsol/band/fmod_int64/CMakeLists.txt b/src/sunlinsol/band/fmod_int64/CMakeLists.txt index 759321d170..8fc7299a36 100644 --- a/src/sunlinsol/band/fmod_int64/CMakeLists.txt +++ b/src/sunlinsol/band/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 band SUNLinearSolver object library # ---------------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolband_mod SOURCES fsunlinsol_band_mod.f90 fsunlinsol_band_mod.c diff --git a/src/sunlinsol/band/sunlinsol_band.c b/src/sunlinsol/band/sunlinsol_band.c index d72e37af1c..f51ad62cea 100644 --- a/src/sunlinsol/band/sunlinsol_band.c +++ b/src/sunlinsol/band/sunlinsol_band.c @@ -25,9 +25,7 @@ #include "sundials_macros.h" -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) -#define ROW(i, j, smu) (i - j + smu) +#define ONE SUN_RCONST(1.0) /* * ----------------------------------------------------------------- diff --git a/src/sunlinsol/dense/fmod_int32/CMakeLists.txt b/src/sunlinsol/dense/fmod_int32/CMakeLists.txt index eb904dc764..f22bac8241 100644 --- a/src/sunlinsol/dense/fmod_int32/CMakeLists.txt +++ b/src/sunlinsol/dense/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 dense SUNLinearSolver object library # ---------------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsoldense_mod SOURCES fsunlinsol_dense_mod.f90 fsunlinsol_dense_mod.c diff --git a/src/sunlinsol/dense/fmod_int64/CMakeLists.txt b/src/sunlinsol/dense/fmod_int64/CMakeLists.txt index 8a6401a143..c1e8aacaa6 100644 --- a/src/sunlinsol/dense/fmod_int64/CMakeLists.txt +++ b/src/sunlinsol/dense/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 dense SUNLinearSolver object library # ---------------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsoldense_mod SOURCES fsunlinsol_dense_mod.f90 fsunlinsol_dense_mod.c diff --git a/src/sunlinsol/klu/fmod_int32/CMakeLists.txt b/src/sunlinsol/klu/fmod_int32/CMakeLists.txt index 04a6624e77..5d5d3edbdb 100644 --- a/src/sunlinsol/klu/fmod_int32/CMakeLists.txt +++ b/src/sunlinsol/klu/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 KLU SUNLinearSolver object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolklu_mod SOURCES fsunlinsol_klu_mod.f90 fsunlinsol_klu_mod.c diff --git a/src/sunlinsol/klu/fmod_int64/CMakeLists.txt b/src/sunlinsol/klu/fmod_int64/CMakeLists.txt index c24c56f863..5af53d9068 100644 --- a/src/sunlinsol/klu/fmod_int64/CMakeLists.txt +++ b/src/sunlinsol/klu/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 KLU SUNLinearSolver object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolklu_mod SOURCES fsunlinsol_klu_mod.f90 fsunlinsol_klu_mod.c diff --git a/src/sunlinsol/klu/sunlinsol_klu.c b/src/sunlinsol/klu/sunlinsol_klu.c index b2a1f290e2..1c6646a0fb 100644 --- a/src/sunlinsol/klu/sunlinsol_klu.c +++ b/src/sunlinsol/klu/sunlinsol_klu.c @@ -26,9 +26,7 @@ #include "sundials_macros.h" -#define ZERO SUN_RCONST(0.0) #define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) #define TWOTHIRDS SUN_RCONST(0.666666666666666666666666666666667) /* diff --git a/src/sunlinsol/lapackband/sunlinsol_lapackband.c b/src/sunlinsol/lapackband/sunlinsol_lapackband.c index ce26bb6951..1c95af2ca0 100644 --- a/src/sunlinsol/lapackband/sunlinsol_lapackband.c +++ b/src/sunlinsol/lapackband/sunlinsol_lapackband.c @@ -36,8 +36,7 @@ #error Incompatible sunrealtype for LAPACK; disable LAPACK and rebuild #endif -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) +#define ONE SUN_RCONST(1.0) /* * ----------------------------------------------------------------- diff --git a/src/sunlinsol/lapackdense/fmod_int32/CMakeLists.txt b/src/sunlinsol/lapackdense/fmod_int32/CMakeLists.txt index ed20a78200..7c57da4f04 100644 --- a/src/sunlinsol/lapackdense/fmod_int32/CMakeLists.txt +++ b/src/sunlinsol/lapackdense/fmod_int32/CMakeLists.txt @@ -15,6 +15,12 @@ # object library # ---------------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsollapackdense_mod SOURCES fsunlinsol_lapackdense_mod.f90 fsunlinsol_lapackdense_mod.c diff --git a/src/sunlinsol/lapackdense/fmod_int64/CMakeLists.txt b/src/sunlinsol/lapackdense/fmod_int64/CMakeLists.txt index b2eb2b329b..7742960ba6 100644 --- a/src/sunlinsol/lapackdense/fmod_int64/CMakeLists.txt +++ b/src/sunlinsol/lapackdense/fmod_int64/CMakeLists.txt @@ -15,6 +15,12 @@ # object library # ---------------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsollapackdense_mod SOURCES fsunlinsol_lapackdense_mod.f90 fsunlinsol_lapackdense_mod.c diff --git a/src/sunlinsol/lapackdense/sunlinsol_lapackdense.c b/src/sunlinsol/lapackdense/sunlinsol_lapackdense.c index a13460b035..abf70003b3 100644 --- a/src/sunlinsol/lapackdense/sunlinsol_lapackdense.c +++ b/src/sunlinsol/lapackdense/sunlinsol_lapackdense.c @@ -36,8 +36,7 @@ #error Incompatible sunrealtype for LAPACK; disable LAPACK and rebuild #endif -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) +#define ONE SUN_RCONST(1.0) /* * ----------------------------------------------------------------- diff --git a/src/sunlinsol/pcg/fmod_int32/CMakeLists.txt b/src/sunlinsol/pcg/fmod_int32/CMakeLists.txt index b89dc76f74..53e5a8d960 100644 --- a/src/sunlinsol/pcg/fmod_int32/CMakeLists.txt +++ b/src/sunlinsol/pcg/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 PCG SUNLinearSolver object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolpcg_mod SOURCES fsunlinsol_pcg_mod.f90 fsunlinsol_pcg_mod.c diff --git a/src/sunlinsol/pcg/fmod_int64/CMakeLists.txt b/src/sunlinsol/pcg/fmod_int64/CMakeLists.txt index ad5985e0b8..b4ff2ceb80 100644 --- a/src/sunlinsol/pcg/fmod_int64/CMakeLists.txt +++ b/src/sunlinsol/pcg/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 PCG SUNLinearSolver object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolpcg_mod SOURCES fsunlinsol_pcg_mod.f90 fsunlinsol_pcg_mod.c diff --git a/src/sunlinsol/spbcgs/fmod_int32/CMakeLists.txt b/src/sunlinsol/spbcgs/fmod_int32/CMakeLists.txt index 23db9490eb..864f188d6b 100644 --- a/src/sunlinsol/spbcgs/fmod_int32/CMakeLists.txt +++ b/src/sunlinsol/spbcgs/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 SPBCGS SUNLinearSolver object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolspbcgs_mod SOURCES fsunlinsol_spbcgs_mod.f90 fsunlinsol_spbcgs_mod.c diff --git a/src/sunlinsol/spbcgs/fmod_int64/CMakeLists.txt b/src/sunlinsol/spbcgs/fmod_int64/CMakeLists.txt index 903402f4de..8994ca7e9e 100644 --- a/src/sunlinsol/spbcgs/fmod_int64/CMakeLists.txt +++ b/src/sunlinsol/spbcgs/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 SPBCGS SUNLinearSolver object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolspbcgs_mod SOURCES fsunlinsol_spbcgs_mod.f90 fsunlinsol_spbcgs_mod.c diff --git a/src/sunlinsol/spfgmr/fmod_int32/CMakeLists.txt b/src/sunlinsol/spfgmr/fmod_int32/CMakeLists.txt index 4d52831daa..dfe0e43f5b 100644 --- a/src/sunlinsol/spfgmr/fmod_int32/CMakeLists.txt +++ b/src/sunlinsol/spfgmr/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 SPFGMR SUNLinearSolver object library # ------------------------------------------------------------------------ +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolspfgmr_mod SOURCES fsunlinsol_spfgmr_mod.f90 fsunlinsol_spfgmr_mod.c diff --git a/src/sunlinsol/spfgmr/fmod_int64/CMakeLists.txt b/src/sunlinsol/spfgmr/fmod_int64/CMakeLists.txt index 335cb9a895..57850fe0b1 100644 --- a/src/sunlinsol/spfgmr/fmod_int64/CMakeLists.txt +++ b/src/sunlinsol/spfgmr/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 SPFGMR SUNLinearSolver object library # ------------------------------------------------------------------------ +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolspfgmr_mod SOURCES fsunlinsol_spfgmr_mod.f90 fsunlinsol_spfgmr_mod.c diff --git a/src/sunlinsol/spgmr/fmod_int32/CMakeLists.txt b/src/sunlinsol/spgmr/fmod_int32/CMakeLists.txt index b359729811..08345ce30e 100644 --- a/src/sunlinsol/spgmr/fmod_int32/CMakeLists.txt +++ b/src/sunlinsol/spgmr/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 SPGMR SUNLinearSolver object library # ------------------------------------------------------------------------ +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolspgmr_mod SOURCES fsunlinsol_spgmr_mod.f90 fsunlinsol_spgmr_mod.c diff --git a/src/sunlinsol/spgmr/fmod_int64/CMakeLists.txt b/src/sunlinsol/spgmr/fmod_int64/CMakeLists.txt index bfbb2e11ad..ec493ba372 100644 --- a/src/sunlinsol/spgmr/fmod_int64/CMakeLists.txt +++ b/src/sunlinsol/spgmr/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 SPGMR SUNLinearSolver object library # ------------------------------------------------------------------------ +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolspgmr_mod SOURCES fsunlinsol_spgmr_mod.f90 fsunlinsol_spgmr_mod.c diff --git a/src/sunlinsol/sptfqmr/fmod_int32/CMakeLists.txt b/src/sunlinsol/sptfqmr/fmod_int32/CMakeLists.txt index f38d135a57..ad8cb95856 100644 --- a/src/sunlinsol/sptfqmr/fmod_int32/CMakeLists.txt +++ b/src/sunlinsol/sptfqmr/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 SPTFQMR SUNLinearSolver object library # ------------------------------------------------------------------------ +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolsptfqmr_mod SOURCES fsunlinsol_sptfqmr_mod.f90 fsunlinsol_sptfqmr_mod.c diff --git a/src/sunlinsol/sptfqmr/fmod_int64/CMakeLists.txt b/src/sunlinsol/sptfqmr/fmod_int64/CMakeLists.txt index 00ac061002..7cc48c3475 100644 --- a/src/sunlinsol/sptfqmr/fmod_int64/CMakeLists.txt +++ b/src/sunlinsol/sptfqmr/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 SPTFQMR SUNLinearSolver object library # ------------------------------------------------------------------------ +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunlinsolsptfqmr_mod SOURCES fsunlinsol_sptfqmr_mod.f90 fsunlinsol_sptfqmr_mod.c diff --git a/src/sunlinsol/superludist/sunlinsol_superludist.c b/src/sunlinsol/superludist/sunlinsol_superludist.c index 82c6b20f1d..19145db499 100644 --- a/src/sunlinsol/superludist/sunlinsol_superludist.c +++ b/src/sunlinsol/superludist/sunlinsol_superludist.c @@ -28,7 +28,6 @@ #define ZERO SUN_RCONST(0.0) #define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) /* * ----------------------------------------------------------------- diff --git a/src/sunlinsol/superlumt/sunlinsol_superlumt.c b/src/sunlinsol/superlumt/sunlinsol_superlumt.c index 439a948fed..907bbc4fd8 100644 --- a/src/sunlinsol/superlumt/sunlinsol_superlumt.c +++ b/src/sunlinsol/superlumt/sunlinsol_superlumt.c @@ -29,7 +29,6 @@ #define ZERO SUN_RCONST(0.0) #define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) /* * ----------------------------------------------------------------- diff --git a/src/sunmatrix/band/fmod_int32/CMakeLists.txt b/src/sunmatrix/band/fmod_int32/CMakeLists.txt index 44e9fc667a..d8fbea503b 100644 --- a/src/sunmatrix/band/fmod_int32/CMakeLists.txt +++ b/src/sunmatrix/band/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 band SUNMatrix object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunmatrixband_mod SOURCES fsunmatrix_band_mod.f90 fsunmatrix_band_mod.c diff --git a/src/sunmatrix/band/fmod_int64/CMakeLists.txt b/src/sunmatrix/band/fmod_int64/CMakeLists.txt index 2c4bac0524..4076c86c19 100644 --- a/src/sunmatrix/band/fmod_int64/CMakeLists.txt +++ b/src/sunmatrix/band/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 band SUNMatrix object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunmatrixband_mod SOURCES fsunmatrix_band_mod.f90 fsunmatrix_band_mod.c diff --git a/src/sunmatrix/dense/fmod_int32/CMakeLists.txt b/src/sunmatrix/dense/fmod_int32/CMakeLists.txt index 1bd612002e..20b11b9de2 100644 --- a/src/sunmatrix/dense/fmod_int32/CMakeLists.txt +++ b/src/sunmatrix/dense/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 dense SUNMatrix object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunmatrixdense_mod SOURCES fsunmatrix_dense_mod.f90 fsunmatrix_dense_mod.c diff --git a/src/sunmatrix/dense/fmod_int64/CMakeLists.txt b/src/sunmatrix/dense/fmod_int64/CMakeLists.txt index a4baea3b35..8f2c700027 100644 --- a/src/sunmatrix/dense/fmod_int64/CMakeLists.txt +++ b/src/sunmatrix/dense/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 dense SUNMatrix object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunmatrixdense_mod SOURCES fsunmatrix_dense_mod.f90 fsunmatrix_dense_mod.c diff --git a/src/sunmatrix/slunrloc/sunmatrix_slunrloc.c b/src/sunmatrix/slunrloc/sunmatrix_slunrloc.c index 585f702349..c396cfed24 100644 --- a/src/sunmatrix/slunrloc/sunmatrix_slunrloc.c +++ b/src/sunmatrix/slunrloc/sunmatrix_slunrloc.c @@ -63,15 +63,6 @@ #define SM_FSTROW_SLUNRLOC(A) (SM_SUPERSTORE_SLUNRLOC(A)->fst_row) -#define SM_DATA_SLUNRLOC(A) ((sunrealtype*)SM_SUPERSTORE_SLUNRLOC(A)->nzval) - -#define SM_COLIND_SLUNRLOC(A) (SM_SUPERSTORE_SLUNRLOC(A)->colind) - -#define SM_ROWPTRS_SLUNRLOC(A) (SM_SUPERSTORE_SLUNRLOC(A)->rowptr) - -/* constants */ -#define ZERO SUN_RCONST(0.0) - /* Private function prototypes */ static sunbooleantype SMCompatible_SLUNRloc(SUNMatrix A, SUNMatrix B); diff --git a/src/sunmatrix/sparse/fmod_int32/CMakeLists.txt b/src/sunmatrix/sparse/fmod_int32/CMakeLists.txt index e9792d9e35..499dbf6a71 100644 --- a/src/sunmatrix/sparse/fmod_int32/CMakeLists.txt +++ b/src/sunmatrix/sparse/fmod_int32/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 sparse SUNMatrix object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunmatrixsparse_mod SOURCES fsunmatrix_sparse_mod.f90 fsunmatrix_sparse_mod.c diff --git a/src/sunmatrix/sparse/fmod_int64/CMakeLists.txt b/src/sunmatrix/sparse/fmod_int64/CMakeLists.txt index e7d02abf11..307d13511d 100644 --- a/src/sunmatrix/sparse/fmod_int64/CMakeLists.txt +++ b/src/sunmatrix/sparse/fmod_int64/CMakeLists.txt @@ -14,6 +14,12 @@ # CMakeLists.txt file for the F2003 sparse SUNMatrix object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunmatrixsparse_mod SOURCES fsunmatrix_sparse_mod.f90 fsunmatrix_sparse_mod.c diff --git a/src/sunnonlinsol/fixedpoint/fmod_int32/CMakeLists.txt b/src/sunnonlinsol/fixedpoint/fmod_int32/CMakeLists.txt index 2b695d6ba3..ca3de07596 100644 --- a/src/sunnonlinsol/fixedpoint/fmod_int32/CMakeLists.txt +++ b/src/sunnonlinsol/fixedpoint/fmod_int32/CMakeLists.txt @@ -15,6 +15,12 @@ # object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunnonlinsolfixedpoint_mod SOURCES fsunnonlinsol_fixedpoint_mod.f90 fsunnonlinsol_fixedpoint_mod.c diff --git a/src/sunnonlinsol/fixedpoint/fmod_int64/CMakeLists.txt b/src/sunnonlinsol/fixedpoint/fmod_int64/CMakeLists.txt index 4b064101b2..0e91f50da0 100644 --- a/src/sunnonlinsol/fixedpoint/fmod_int64/CMakeLists.txt +++ b/src/sunnonlinsol/fixedpoint/fmod_int64/CMakeLists.txt @@ -15,6 +15,12 @@ # object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunnonlinsolfixedpoint_mod SOURCES fsunnonlinsol_fixedpoint_mod.f90 fsunnonlinsol_fixedpoint_mod.c diff --git a/src/sunnonlinsol/newton/fmod_int32/CMakeLists.txt b/src/sunnonlinsol/newton/fmod_int32/CMakeLists.txt index 6851b86153..5c93e88051 100644 --- a/src/sunnonlinsol/newton/fmod_int32/CMakeLists.txt +++ b/src/sunnonlinsol/newton/fmod_int32/CMakeLists.txt @@ -15,6 +15,12 @@ # object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunnonlinsolnewton_mod SOURCES fsunnonlinsol_newton_mod.f90 fsunnonlinsol_newton_mod.c diff --git a/src/sunnonlinsol/newton/fmod_int64/CMakeLists.txt b/src/sunnonlinsol/newton/fmod_int64/CMakeLists.txt index 25108f7457..217afe3524 100644 --- a/src/sunnonlinsol/newton/fmod_int64/CMakeLists.txt +++ b/src/sunnonlinsol/newton/fmod_int64/CMakeLists.txt @@ -15,6 +15,12 @@ # object library # --------------------------------------------------------------- +# Disable warnings from unused SWIG macros which we can't control +if(ENABLE_ALL_WARNINGS) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-macros") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-macros") +endif() + sundials_add_f2003_library( sundials_fsunnonlinsolnewton_mod SOURCES fsunnonlinsol_newton_mod.f90 fsunnonlinsol_newton_mod.c diff --git a/test/unit_tests/arkode/CXX_parallel/ark_test_heat2D_mri.cpp b/test/unit_tests/arkode/CXX_parallel/ark_test_heat2D_mri.cpp index c4f9757a29..acfcb96c4f 100644 --- a/test/unit_tests/arkode/CXX_parallel/ark_test_heat2D_mri.cpp +++ b/test/unit_tests/arkode/CXX_parallel/ark_test_heat2D_mri.cpp @@ -35,16 +35,6 @@ #include "sundials/sundials_types.h" // def. of type 'sunrealtype' #include "sunlinsol/sunlinsol_pcg.h" // access to PCG SUNLinearSolver -#if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" -#else -#define GSYM "g" -#define ESYM "e" -#define FSYM "f" -#endif - using namespace std; // accessor macros between (x,y) location and 1D NVector array diff --git a/test/unit_tests/arkode/CXX_serial/ark_test_accumerror_brusselator.cpp b/test/unit_tests/arkode/CXX_serial/ark_test_accumerror_brusselator.cpp index 4c3c1507fc..8c0f3bca5b 100644 --- a/test/unit_tests/arkode/CXX_serial/ark_test_accumerror_brusselator.cpp +++ b/test/unit_tests/arkode/CXX_serial/ark_test_accumerror_brusselator.cpp @@ -93,16 +93,6 @@ #include #include -#if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" -#else -#define GSYM "g" -#define ESYM "e" -#define FSYM "f" -#endif - #define ZERO SUN_RCONST(0.0) #define ONE SUN_RCONST(1.0) #define TWO SUN_RCONST(2.0) diff --git a/test/unit_tests/arkode/CXX_serial/ark_test_accumerror_kpr.cpp b/test/unit_tests/arkode/CXX_serial/ark_test_accumerror_kpr.cpp index f9b3279166..1fa47dcf30 100644 --- a/test/unit_tests/arkode/CXX_serial/ark_test_accumerror_kpr.cpp +++ b/test/unit_tests/arkode/CXX_serial/ark_test_accumerror_kpr.cpp @@ -81,16 +81,6 @@ #include #include -#if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" -#else -#define GSYM "g" -#define ESYM "e" -#define FSYM "f" -#endif - #define ZERO SUN_RCONST(0.0) #define ONE SUN_RCONST(1.0) #define TWO SUN_RCONST(2.0) diff --git a/test/unit_tests/arkode/CXX_serial/ark_test_analytic_sys_mri.cpp b/test/unit_tests/arkode/CXX_serial/ark_test_analytic_sys_mri.cpp index 163881fa4a..ddbac2de4d 100644 --- a/test/unit_tests/arkode/CXX_serial/ark_test_analytic_sys_mri.cpp +++ b/test/unit_tests/arkode/CXX_serial/ark_test_analytic_sys_mri.cpp @@ -35,16 +35,6 @@ #include #include -#if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" -#else -#define GSYM "g" -#define ESYM "e" -#define FSYM "f" -#endif - using namespace std; #define ZERO SUN_RCONST(0.0) diff --git a/test/unit_tests/arkode/CXX_serial/ark_test_dahlquist_ark.cpp b/test/unit_tests/arkode/CXX_serial/ark_test_dahlquist_ark.cpp index cf9c04feb8..06d0d61d41 100644 --- a/test/unit_tests/arkode/CXX_serial/ark_test_dahlquist_ark.cpp +++ b/test/unit_tests/arkode/CXX_serial/ark_test_dahlquist_ark.cpp @@ -33,16 +33,6 @@ #include "arkode/arkode.h" #include "arkode/arkode_butcher.h" -#if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" -#else -#define GSYM "g" -#define ESYM "e" -#define FSYM "f" -#endif - // Constants #define NEG_ONE SUN_RCONST(-1.0) #define ZERO SUN_RCONST(0.0) diff --git a/test/unit_tests/arkode/CXX_serial/ark_test_dahlquist_erk.cpp b/test/unit_tests/arkode/CXX_serial/ark_test_dahlquist_erk.cpp index 525da5509f..27d41890a8 100644 --- a/test/unit_tests/arkode/CXX_serial/ark_test_dahlquist_erk.cpp +++ b/test/unit_tests/arkode/CXX_serial/ark_test_dahlquist_erk.cpp @@ -28,20 +28,9 @@ #include "arkode/arkode_butcher.h" -#if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" -#else -#define GSYM "g" -#define ESYM "e" -#define FSYM "f" -#endif - // Constants #define NEG_ONE SUN_RCONST(-1.0) #define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) #define TWO SUN_RCONST(2.0) enum class interp_type diff --git a/test/unit_tests/arkode/CXX_serial/ark_test_dahlquist_mri.cpp b/test/unit_tests/arkode/CXX_serial/ark_test_dahlquist_mri.cpp index 4134c124bd..f55cd6ba9a 100644 --- a/test/unit_tests/arkode/CXX_serial/ark_test_dahlquist_mri.cpp +++ b/test/unit_tests/arkode/CXX_serial/ark_test_dahlquist_mri.cpp @@ -33,16 +33,6 @@ #include "arkode/arkode_mri_tables_impl.h" -#if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" -#else -#define GSYM "g" -#define ESYM "e" -#define FSYM "f" -#endif - enum class interp_type { none = -1, diff --git a/test/unit_tests/arkode/CXX_serial/ark_test_slowerror_brusselator.cpp b/test/unit_tests/arkode/CXX_serial/ark_test_slowerror_brusselator.cpp index e094279c41..a70ad899a9 100644 --- a/test/unit_tests/arkode/CXX_serial/ark_test_slowerror_brusselator.cpp +++ b/test/unit_tests/arkode/CXX_serial/ark_test_slowerror_brusselator.cpp @@ -92,16 +92,6 @@ #include #include -#if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" -#else -#define GSYM "g" -#define ESYM "e" -#define FSYM "f" -#endif - #define ZERO SUN_RCONST(0.0) #define ONE SUN_RCONST(1.0) #define TWO SUN_RCONST(2.0) diff --git a/test/unit_tests/arkode/CXX_serial/ark_test_slowerror_kpr.cpp b/test/unit_tests/arkode/CXX_serial/ark_test_slowerror_kpr.cpp index a7346214c4..6880e45719 100644 --- a/test/unit_tests/arkode/CXX_serial/ark_test_slowerror_kpr.cpp +++ b/test/unit_tests/arkode/CXX_serial/ark_test_slowerror_kpr.cpp @@ -78,16 +78,6 @@ #include #include -#if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" -#else -#define GSYM "g" -#define ESYM "e" -#define FSYM "f" -#endif - #define ZERO SUN_RCONST(0.0) #define ONE SUN_RCONST(1.0) #define TWO SUN_RCONST(2.0) diff --git a/test/unit_tests/arkode/CXX_serial/ark_test_slowerror_polynomial.cpp b/test/unit_tests/arkode/CXX_serial/ark_test_slowerror_polynomial.cpp index e8826f4de0..c4689d2b59 100644 --- a/test/unit_tests/arkode/CXX_serial/ark_test_slowerror_polynomial.cpp +++ b/test/unit_tests/arkode/CXX_serial/ark_test_slowerror_polynomial.cpp @@ -56,19 +56,8 @@ #include #include -#if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" -#else -#define GSYM "g" -#define ESYM "e" -#define FSYM "f" -#endif - #define ZERO SUN_RCONST(0.0) #define ONE SUN_RCONST(1.0) -#define TWO SUN_RCONST(2.0) using namespace std; diff --git a/test/unit_tests/arkode/C_serial/ark_test_arkstepsetforcing.c b/test/unit_tests/arkode/C_serial/ark_test_arkstepsetforcing.c index 7fdb34daf2..de707fdde6 100644 --- a/test/unit_tests/arkode/C_serial/ark_test_arkstepsetforcing.c +++ b/test/unit_tests/arkode/C_serial/ark_test_arkstepsetforcing.c @@ -36,11 +36,9 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" #define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" #define ESYM "e" -#define FSYM "f" #endif /* User-supplied Functions Called by the Solver */ diff --git a/test/unit_tests/arkode/C_serial/ark_test_innerstepper.c b/test/unit_tests/arkode/C_serial/ark_test_innerstepper.c index 7e16e77946..9311fadc55 100644 --- a/test/unit_tests/arkode/C_serial/ark_test_innerstepper.c +++ b/test/unit_tests/arkode/C_serial/ark_test_innerstepper.c @@ -23,12 +23,6 @@ #include "arkode/arkode_mristep.h" #include "nvector/nvector_serial.h" -#if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#else -#define GSYM "g" -#endif - #define ZERO SUN_RCONST(0.0) #define ONE SUN_RCONST(1.0) diff --git a/test/unit_tests/arkode/C_serial/ark_test_reset.c b/test/unit_tests/arkode/C_serial/ark_test_reset.c index 8574dd31a4..e708f46c17 100644 --- a/test/unit_tests/arkode/C_serial/ark_test_reset.c +++ b/test/unit_tests/arkode/C_serial/ark_test_reset.c @@ -44,12 +44,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* User-supplied Functions Called by the Solver */ diff --git a/test/unit_tests/kinsol/CXX_serial/kin_test_getjac.cpp b/test/unit_tests/kinsol/CXX_serial/kin_test_getjac.cpp index cb3abe9da2..27255343f8 100644 --- a/test/unit_tests/kinsol/CXX_serial/kin_test_getjac.cpp +++ b/test/unit_tests/kinsol/CXX_serial/kin_test_getjac.cpp @@ -59,17 +59,11 @@ #define ONEPTZEROSIX SUN_RCONST(1.06) #define TWO SUN_RCONST(2.0) #define THREE SUN_RCONST(3.0) -#define SIX SUN_RCONST(6.0) #define TEN SUN_RCONST(10.0) #define TWENTY SUN_RCONST(20.0) #define EIGHTYONE SUN_RCONST(81.0) #define PI SUN_RCONST(3.141592653589793238462643383279502884197169) -// Analytic solution -#define XTRUE HALF -#define YTRUE ONE -#define ZTRUE -PI / SIX - #define SQR(x) ((x) * (x)) // ----------------------------------------------------------------------------- diff --git a/test/unit_tests/kinsol/C_serial/kin_test_getuserdata.c b/test/unit_tests/kinsol/C_serial/kin_test_getuserdata.c index 399abb16a3..5e7278ce33 100644 --- a/test/unit_tests/kinsol/C_serial/kin_test_getuserdata.c +++ b/test/unit_tests/kinsol/C_serial/kin_test_getuserdata.c @@ -20,8 +20,7 @@ #include "kinsol/kinsol.h" #include "nvector/nvector_serial.h" -#define ZERO SUN_RCONST(0.0) -#define ONE SUN_RCONST(1.0) +#define ONE SUN_RCONST(1.0) /* Dummy user-supplied function */ static int F(N_Vector u, N_Vector r, void* user_data) { return 0; } diff --git a/test/unit_tests/nvector/test_nvector.c b/test/unit_tests/nvector/test_nvector.c index a7d5741522..9fd34af0c8 100644 --- a/test/unit_tests/nvector/test_nvector.c +++ b/test/unit_tests/nvector/test_nvector.c @@ -36,12 +36,8 @@ #include "test_nvector.h" #if defined(SUNDIALS_EXTENDED_PRECISION) -#define GSYM "Lg" -#define ESYM "Le" #define FSYM "Lf" #else -#define GSYM "g" -#define ESYM "e" #define FSYM ".17f" #endif diff --git a/test/unit_tests/sunlinsol/band/test_sunlinsol_band.c b/test/unit_tests/sunlinsol/band/test_sunlinsol_band.c index c29ce01953..233728102c 100644 --- a/test/unit_tests/sunlinsol/band/test_sunlinsol_band.c +++ b/test/unit_tests/sunlinsol/band/test_sunlinsol_band.c @@ -29,12 +29,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* ---------------------------------------------------------------------- diff --git a/test/unit_tests/sunlinsol/dense/test_sunlinsol_dense.c b/test/unit_tests/sunlinsol/dense/test_sunlinsol_dense.c index 9d33c0452e..7f1cd31b17 100644 --- a/test/unit_tests/sunlinsol/dense/test_sunlinsol_dense.c +++ b/test/unit_tests/sunlinsol/dense/test_sunlinsol_dense.c @@ -29,12 +29,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* ---------------------------------------------------------------------- diff --git a/test/unit_tests/sunlinsol/pcg/parallel/test_sunlinsol_pcg_parallel.c b/test/unit_tests/sunlinsol/pcg/parallel/test_sunlinsol_pcg_parallel.c index 7f2bf07181..63bd13bb0f 100644 --- a/test/unit_tests/sunlinsol/pcg/parallel/test_sunlinsol_pcg_parallel.c +++ b/test/unit_tests/sunlinsol/pcg/parallel/test_sunlinsol_pcg_parallel.c @@ -30,12 +30,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* constants */ diff --git a/test/unit_tests/sunlinsol/pcg/serial/test_sunlinsol_pcg_serial.c b/test/unit_tests/sunlinsol/pcg/serial/test_sunlinsol_pcg_serial.c index 14f07e9d8e..208d398e5a 100644 --- a/test/unit_tests/sunlinsol/pcg/serial/test_sunlinsol_pcg_serial.c +++ b/test/unit_tests/sunlinsol/pcg/serial/test_sunlinsol_pcg_serial.c @@ -29,12 +29,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* constants */ diff --git a/test/unit_tests/sunlinsol/spbcgs/parallel/test_sunlinsol_spbcgs_parallel.c b/test/unit_tests/sunlinsol/spbcgs/parallel/test_sunlinsol_spbcgs_parallel.c index 986a9fc29e..af003dfd02 100644 --- a/test/unit_tests/sunlinsol/spbcgs/parallel/test_sunlinsol_spbcgs_parallel.c +++ b/test/unit_tests/sunlinsol/spbcgs/parallel/test_sunlinsol_spbcgs_parallel.c @@ -30,12 +30,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* constants */ diff --git a/test/unit_tests/sunlinsol/spbcgs/serial/test_sunlinsol_spbcgs_serial.c b/test/unit_tests/sunlinsol/spbcgs/serial/test_sunlinsol_spbcgs_serial.c index 2d9f4e212d..d085c33b63 100644 --- a/test/unit_tests/sunlinsol/spbcgs/serial/test_sunlinsol_spbcgs_serial.c +++ b/test/unit_tests/sunlinsol/spbcgs/serial/test_sunlinsol_spbcgs_serial.c @@ -29,12 +29,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* constants */ diff --git a/test/unit_tests/sunlinsol/spfgmr/parallel/test_sunlinsol_spfgmr_parallel.c b/test/unit_tests/sunlinsol/spfgmr/parallel/test_sunlinsol_spfgmr_parallel.c index dc2479342d..8aed837e09 100644 --- a/test/unit_tests/sunlinsol/spfgmr/parallel/test_sunlinsol_spfgmr_parallel.c +++ b/test/unit_tests/sunlinsol/spfgmr/parallel/test_sunlinsol_spfgmr_parallel.c @@ -30,12 +30,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* constants */ diff --git a/test/unit_tests/sunlinsol/spfgmr/serial/test_sunlinsol_spfgmr_serial.c b/test/unit_tests/sunlinsol/spfgmr/serial/test_sunlinsol_spfgmr_serial.c index a2605ba630..d4d2bf6633 100644 --- a/test/unit_tests/sunlinsol/spfgmr/serial/test_sunlinsol_spfgmr_serial.c +++ b/test/unit_tests/sunlinsol/spfgmr/serial/test_sunlinsol_spfgmr_serial.c @@ -29,12 +29,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* constants */ diff --git a/test/unit_tests/sunlinsol/spgmr/parallel/test_sunlinsol_spgmr_parallel.c b/test/unit_tests/sunlinsol/spgmr/parallel/test_sunlinsol_spgmr_parallel.c index 9ab3ded6e3..d57f65e837 100644 --- a/test/unit_tests/sunlinsol/spgmr/parallel/test_sunlinsol_spgmr_parallel.c +++ b/test/unit_tests/sunlinsol/spgmr/parallel/test_sunlinsol_spgmr_parallel.c @@ -30,12 +30,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* constants */ diff --git a/test/unit_tests/sunlinsol/spgmr/serial/test_sunlinsol_spgmr_serial.c b/test/unit_tests/sunlinsol/spgmr/serial/test_sunlinsol_spgmr_serial.c index 4b76a5ac86..37b3e59f7e 100644 --- a/test/unit_tests/sunlinsol/spgmr/serial/test_sunlinsol_spgmr_serial.c +++ b/test/unit_tests/sunlinsol/spgmr/serial/test_sunlinsol_spgmr_serial.c @@ -29,12 +29,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* constants */ diff --git a/test/unit_tests/sunlinsol/sptfqmr/parallel/test_sunlinsol_sptfqmr_parallel.c b/test/unit_tests/sunlinsol/sptfqmr/parallel/test_sunlinsol_sptfqmr_parallel.c index 4122097535..c2a2ee2014 100644 --- a/test/unit_tests/sunlinsol/sptfqmr/parallel/test_sunlinsol_sptfqmr_parallel.c +++ b/test/unit_tests/sunlinsol/sptfqmr/parallel/test_sunlinsol_sptfqmr_parallel.c @@ -30,12 +30,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* constants */ diff --git a/test/unit_tests/sunlinsol/sptfqmr/serial/test_sunlinsol_sptfqmr_serial.c b/test/unit_tests/sunlinsol/sptfqmr/serial/test_sunlinsol_sptfqmr_serial.c index 00e5955c95..e54aa99b34 100644 --- a/test/unit_tests/sunlinsol/sptfqmr/serial/test_sunlinsol_sptfqmr_serial.c +++ b/test/unit_tests/sunlinsol/sptfqmr/serial/test_sunlinsol_sptfqmr_serial.c @@ -29,12 +29,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* constants */ diff --git a/test/unit_tests/sunmatrix/band/test_sunmatrix_band.c b/test/unit_tests/sunmatrix/band/test_sunmatrix_band.c index 6833724a5c..d58a8f99f5 100644 --- a/test/unit_tests/sunmatrix/band/test_sunmatrix_band.c +++ b/test/unit_tests/sunmatrix/band/test_sunmatrix_band.c @@ -29,12 +29,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* ---------------------------------------------------------------------- diff --git a/test/unit_tests/sunmatrix/dense/test_sunmatrix_dense.c b/test/unit_tests/sunmatrix/dense/test_sunmatrix_dense.c index 168cfabe54..00878ae376 100644 --- a/test/unit_tests/sunmatrix/dense/test_sunmatrix_dense.c +++ b/test/unit_tests/sunmatrix/dense/test_sunmatrix_dense.c @@ -29,12 +29,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* ---------------------------------------------------------------------- diff --git a/test/unit_tests/sunmatrix/test_sunmatrix.c b/test/unit_tests/sunmatrix/test_sunmatrix.c index 47b2cf9296..84737b9f7f 100644 --- a/test/unit_tests/sunmatrix/test_sunmatrix.c +++ b/test/unit_tests/sunmatrix/test_sunmatrix.c @@ -38,7 +38,6 @@ static double get_time(void); int print_time = 0; int print_all_ranks = 0; -#define FMT "%s Time: %22.15e\n\n" #define PRINT_TIME(format, time) \ if (print_time) printf(format, time) diff --git a/test/unit_tests/sunnonlinsol/fixedpoint/test_sunnonlinsol_fixedpoint.c b/test/unit_tests/sunnonlinsol/fixedpoint/test_sunnonlinsol_fixedpoint.c index a9e9c5435e..c0e509a8cf 100644 --- a/test/unit_tests/sunnonlinsol/fixedpoint/test_sunnonlinsol_fixedpoint.c +++ b/test/unit_tests/sunnonlinsol/fixedpoint/test_sunnonlinsol_fixedpoint.c @@ -39,12 +39,8 @@ /* precision specific formatting macros */ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif /* precision specific math function macros */ diff --git a/test/unit_tests/sunnonlinsol/newton/test_sunnonlinsol_newton.c b/test/unit_tests/sunnonlinsol/newton/test_sunnonlinsol_newton.c index 489a3549a0..1860865a6e 100644 --- a/test/unit_tests/sunnonlinsol/newton/test_sunnonlinsol_newton.c +++ b/test/unit_tests/sunnonlinsol/newton/test_sunnonlinsol_newton.c @@ -25,12 +25,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif #define NEQ 3 /* number of equations */ diff --git a/test/unit_tests/sunnonlinsol/petsc/test_sunnonlinsol_petscsnes.c b/test/unit_tests/sunnonlinsol/petsc/test_sunnonlinsol_petscsnes.c index d66fb5526a..f21bc08179 100644 --- a/test/unit_tests/sunnonlinsol/petsc/test_sunnonlinsol_petscsnes.c +++ b/test/unit_tests/sunnonlinsol/petsc/test_sunnonlinsol_petscsnes.c @@ -23,12 +23,8 @@ #if defined(SUNDIALS_EXTENDED_PRECISION) #define GSYM "Lg" -#define ESYM "Le" -#define FSYM "Lf" #else #define GSYM "g" -#define ESYM "e" -#define FSYM "f" #endif #define NEQ 3 /* number of equations */