[Commits] [svn:einsteintoolkit] GRHydro/trunk/src/ (Rev. 646)
schnetter at cct.lsu.edu
schnetter at cct.lsu.edu
Wed Apr 23 04:45:34 CDT 2014
User: eschnett
Date: 2014/04/23 04:45 AM
Modified:
/trunk/src/
GRHydro_PPMReconstruct_drv_opt.cc, GRHydro_Reconstruct.cc, GRHydro_Reconstruct_drv_cxx.hh, GRHydro_Reconstruct_drv_impl.hh, make.code.defn
Log:
Make code compile with IBM C++ compiler
IBM's C++ compiler is apparently more picky than GCC or Intel:
Do not pass cctkGH as reference (except when passing to Fortran).
cctkGH is a pointer; passing it as reference has no benefit.
Change some "& restrict" to "&". The meaning of "restrict" in C++ is
not standardized, and apparently IBM's C++ compiler does not like this
usage.
File Changes:
Directory: /trunk/src/
======================
File [modified]: GRHydro_PPMReconstruct_drv_opt.cc
Delta lines: +1 -1
===================================================================
--- trunk/src/GRHydro_PPMReconstruct_drv_opt.cc 2014-04-15 19:52:25 UTC (rev 645)
+++ trunk/src/GRHydro_PPMReconstruct_drv_opt.cc 2014-04-23 09:45:34 UTC (rev 646)
@@ -46,7 +46,7 @@
*/
extern "C"
-void CCTK_FNAME(GRHydro_PPMReconstruct_drv_opt)(cGH const * const restrict & restrict cctkGH)
+void CCTK_FNAME(GRHydro_PPMReconstruct_drv_opt)(cGH const * const restrict & /*restrict*/ cctkGH)
{
DECLARE_CCTK_ARGUMENTS;
DECLARE_CCTK_PARAMETERS;
File [modified]: GRHydro_Reconstruct.cc
Delta lines: +3 -3
===================================================================
--- trunk/src/GRHydro_Reconstruct.cc 2014-04-15 19:52:25 UTC (rev 645)
+++ trunk/src/GRHydro_Reconstruct.cc 2014-04-23 09:45:34 UTC (rev 646)
@@ -41,10 +41,10 @@
This is needed right now because we want to also call this from Fotran
*/
extern "C"
-void CCTK_FCALL CCTK_FNAME(GRHydro_PPMReconstruct_drv_opt)(cGH const * const restrict & restrict cctkGH);
+void CCTK_FCALL CCTK_FNAME(GRHydro_PPMReconstruct_drv_opt)(cGH /*const*/ * const restrict & /*restrict*/ cctkGH);
extern "C"
-void CCTK_FCALL CCTK_FNAME(primitive2conservativeM)(cGH const * const restrict & restrict cctkGH);
+void CCTK_FCALL CCTK_FNAME(primitive2conservativeM)(cGH /*const*/ * const restrict & /*restrict*/ cctkGH);
/**
@@ -58,7 +58,7 @@
const bool do_temp,
const bool reconstruct_Wv,
const bool clean_divergence,
- cGH const * const restrict & restrict cctkGH)
+ cGH const * const restrict cctkGH)
{
if (!do_mhd && !do_Ye && !do_temp && reconstruct_Wv)
GRHydro_Reconstruct_drv_cxx <false, false, false, true, false, RECONSTRUCT > (cctkGH);
File [modified]: GRHydro_Reconstruct_drv_cxx.hh
Delta lines: +13 -13
===================================================================
--- trunk/src/GRHydro_Reconstruct_drv_cxx.hh 2014-04-15 19:52:25 UTC (rev 645)
+++ trunk/src/GRHydro_Reconstruct_drv_cxx.hh 2014-04-23 09:45:34 UTC (rev 646)
@@ -19,46 +19,46 @@
bool do_reconstruct_Wv,
bool do_clean_divergence,
class RECONSTRUCT> // the reconstruction operator
-void GRHydro_Reconstruct_drv_cxx(cGH const * const restrict & restrict cctkGH);
+void GRHydro_Reconstruct_drv_cxx(cGH const * const restrict cctkGH);
// helper macro to instantiate all required permuations of the template options
// this must match GRHydro_Reconstruct's reconstruct::select routine
#define INSTANTIATE_RECONSTRUCTION_OPERATOR(RECONSTRUCT) \
template void \
GRHydro_Reconstruct_drv_cxx <false, false, false, true, false, RECONSTRUCT> ( \
- cGH const * const restrict & restrict cctkGH); \
+ cGH const * const restrict cctkGH); \
template void \
GRHydro_Reconstruct_drv_cxx <true, false, false, true, false, RECONSTRUCT> ( \
- cGH const * const restrict & restrict cctkGH); \
+ cGH const * const restrict cctkGH); \
template void \
GRHydro_Reconstruct_drv_cxx <true, true, true, true, false, RECONSTRUCT> ( \
- cGH const * const restrict & restrict cctkGH); \
+ cGH const * const restrict cctkGH); \
template void \
GRHydro_Reconstruct_drv_cxx <true, false, false, true, true, RECONSTRUCT> ( \
- cGH const * const restrict & restrict cctkGH); \
+ cGH const * const restrict cctkGH); \
template void \
GRHydro_Reconstruct_drv_cxx <true, true, true, true, true, RECONSTRUCT> ( \
- cGH const * const restrict & restrict cctkGH); \
+ cGH const * const restrict cctkGH); \
template void \
GRHydro_Reconstruct_drv_cxx <false, true, true, true, false, RECONSTRUCT> ( \
- cGH const * const restrict & restrict cctkGH); \
+ cGH const * const restrict cctkGH); \
template void \
GRHydro_Reconstruct_drv_cxx <false, false, false, false, false, RECONSTRUCT> ( \
- cGH const * const restrict & restrict cctkGH); \
+ cGH const * const restrict cctkGH); \
template void \
GRHydro_Reconstruct_drv_cxx <true, false, false, false, false, RECONSTRUCT> ( \
- cGH const * const restrict & restrict cctkGH); \
+ cGH const * const restrict cctkGH); \
template void \
GRHydro_Reconstruct_drv_cxx <true, true, true, false, false, RECONSTRUCT> ( \
- cGH const * const restrict & restrict cctkGH); \
+ cGH const * const restrict cctkGH); \
template void \
GRHydro_Reconstruct_drv_cxx <true, false, false, false, true, RECONSTRUCT> ( \
- cGH const * const restrict & restrict cctkGH); \
+ cGH const * const restrict cctkGH); \
template void \
GRHydro_Reconstruct_drv_cxx <true, true, true, false, true, RECONSTRUCT> ( \
- cGH const * const restrict & restrict cctkGH); \
+ cGH const * const restrict cctkGH); \
template void \
GRHydro_Reconstruct_drv_cxx <false, true, true, false, false, RECONSTRUCT> ( \
- cGH const * const restrict & restrict cctkGH);
+ cGH const * const restrict cctkGH);
#endif // _GRHYDRO_RECONSTRUCT_DRV_CXX_H
File [modified]: GRHydro_Reconstruct_drv_impl.hh
Delta lines: +1 -1
===================================================================
--- trunk/src/GRHydro_Reconstruct_drv_impl.hh 2014-04-15 19:52:25 UTC (rev 645)
+++ trunk/src/GRHydro_Reconstruct_drv_impl.hh 2014-04-23 09:45:34 UTC (rev 646)
@@ -120,7 +120,7 @@
bool do_reconstruct_Wv,
bool do_clean_divergence,
class RECONSTRUCT> // the reconstruction operator
-void GRHydro_Reconstruct_drv_cxx(cGH const * const restrict & restrict cctkGH)
+void GRHydro_Reconstruct_drv_cxx(cGH const * const restrict cctkGH)
{
DECLARE_CCTK_ARGUMENTS;
DECLARE_CCTK_PARAMETERS;
File [modified]: make.code.defn
Delta lines: +1 -1
===================================================================
--- trunk/src/make.code.defn 2014-04-15 19:52:25 UTC (rev 645)
+++ trunk/src/make.code.defn 2014-04-23 09:45:34 UTC (rev 646)
@@ -92,7 +92,7 @@
GRHydro_MP5Reconstruct.cc \
GRHydro_Wrappers.F90 \
GRHydro_HLLE.cc \
- GRHydro_Source.cc \
+ GRHydro_Source.cc \
GRHydro_Source.F90
More information about the Commits
mailing list