diff options
author | schnetter <> | 2002-01-14 13:59:00 +0000 |
---|---|---|
committer | schnetter <> | 2002-01-14 13:59:00 +0000 |
commit | 73ec4cfa7dc629b3f8c57503a5f22985a61d7489 (patch) | |
tree | 5e9001b63b9cc80aeb4a5c8b1047f2f8a67eacad /Carpet | |
parent | 45a9266999b72677844cd2761ff733727e62344e (diff) |
Added explicit type conversions to make it compile with gcc 3.0.
darcs-hash:20020114135924-07bb3-96fa13db24c22b0b6ed8e8672548fff5a3800a35.gz
Diffstat (limited to 'Carpet')
-rw-r--r-- | Carpet/Carpet/src/Initialise.cc | 7 | ||||
-rw-r--r-- | Carpet/Carpet/src/SetupGH.cc | 7 | ||||
-rw-r--r-- | Carpet/CarpetRegrid/src/regrid.cc | 16 |
3 files changed, 20 insertions, 10 deletions
diff --git a/Carpet/Carpet/src/Initialise.cc b/Carpet/Carpet/src/Initialise.cc index 24127da2f..e885280e3 100644 --- a/Carpet/Carpet/src/Initialise.cc +++ b/Carpet/Carpet/src/Initialise.cc @@ -9,7 +9,7 @@ #include "carpet.hh" -static const char* rcsid = "$Header: /home/eschnett/C/carpet/Carpet/Carpet/Carpet/src/Initialise.cc,v 1.6 2002/01/11 17:19:45 schnetter Exp $"; +static const char* rcsid = "$Header: /home/eschnett/C/carpet/Carpet/Carpet/Carpet/src/Initialise.cc,v 1.7 2002/01/14 14:59:24 schnetter Exp $"; @@ -21,12 +21,17 @@ namespace Carpet { int Initialise (tFleshConfig* fc) { + cout << "zwei..." << endl; DECLARE_CCTK_PARAMETERS; + cout << "zwei..." << endl; // Initialise stuff const int convlev = 0; + cout << "zwei..." << endl; cGH* const cgh = CCTK_SetupGH (fc, convlev); + cout << "zwei..." << endl; CCTKi_AddGH (fc, convlev, cgh); + cout << "zwei..." << endl; // Delay checkpoint until MPI has been initialised Waypoint ("starting Initialise..."); diff --git a/Carpet/Carpet/src/SetupGH.cc b/Carpet/Carpet/src/SetupGH.cc index 5fec5e2ae..a8f7ce2d3 100644 --- a/Carpet/Carpet/src/SetupGH.cc +++ b/Carpet/Carpet/src/SetupGH.cc @@ -12,7 +12,7 @@ #include "carpet.hh" -static const char* rcsid = "$Header: /home/eschnett/C/carpet/Carpet/Carpet/Carpet/src/SetupGH.cc,v 1.21 2002/01/11 17:19:46 schnetter Exp $"; +static const char* rcsid = "$Header: /home/eschnett/C/carpet/Carpet/Carpet/Carpet/src/SetupGH.cc,v 1.22 2002/01/14 14:59:24 schnetter Exp $"; @@ -24,17 +24,22 @@ namespace Carpet { void* SetupGH (tFleshConfig* fc, int convLevel, cGH* cgh) { + cout << "eins..." << endl; DECLARE_CCTK_PARAMETERS; + cout << "eins..." << endl; assert (cgh->cctk_dim == dim); // Not sure what to do with that assert (convLevel==0); + cout << "eins..." << endl; dist::pseudoinit(); + cout << "eins..." << endl; CCTK_VInfo (CCTK_THORNSTRING, "Carpet is running on %d processors", CCTK_nProcs(cgh)); + cout << "eins..." << endl; Waypoint ("starting SetupGH..."); diff --git a/Carpet/CarpetRegrid/src/regrid.cc b/Carpet/CarpetRegrid/src/regrid.cc index fc2a62d75..a8417a1f3 100644 --- a/Carpet/CarpetRegrid/src/regrid.cc +++ b/Carpet/CarpetRegrid/src/regrid.cc @@ -19,7 +19,7 @@ #include "carpet.hh" #include "regrid.hh" -static const char* rcsid = "$Header: /home/eschnett/C/carpet/Carpet/Carpet/CarpetRegrid/src/regrid.cc,v 1.6 2002/01/11 17:37:13 schnetter Exp $"; +static const char* rcsid = "$Header: /home/eschnett/C/carpet/Carpet/Carpet/CarpetRegrid/src/regrid.cc,v 1.7 2002/01/14 14:59:27 schnetter Exp $"; @@ -126,7 +126,7 @@ namespace CarpetRegrid { assert (vi-v1 < (int)arrdata[gi].data.size()); assert (arrdata[gi].data[vi-v1]); const gf<CCTK_REAL,dim>& error - = *(const gf<CCTK_REAL,dim>*)arrdata[gi].data[vi-v1]; + = *dynamic_cast<const gf<CCTK_REAL,dim>*>(arrdata[gi].data[vi-v1]); MakeRegions_Adaptively (cctkGH, minwidth, minfraction, maxerror, error, bbl); @@ -303,8 +303,8 @@ namespace CarpetRegrid { const int rl = reflevel+1; - const vect<int,dim> ilower = map(floor, (lower[rl-1] - global_lower) / (global_upper - global_lower) * global_extent + 0.5); - const vect<int,dim> iupper = map(floor, (upper[rl-1] - global_lower) / (global_upper - global_lower) * global_extent + 0.5); + const vect<int,dim> ilower = vect<int,dim>(map((CCTK_REAL(*)(CCTK_REAL))(floor), (lower[rl-1] - global_lower) / (global_upper - global_lower) * vect<CCTK_REAL,dim>(global_extent) + 0.5)); + const vect<int,dim> iupper = vect<int,dim>(map((CCTK_REAL(*)(CCTK_REAL))(floor), (upper[rl-1] - global_lower) / (global_upper - global_lower) * vect<CCTK_REAL,dim>(global_extent) + 0.5)); MakeRegions_AsSpecified_OneLevel (cctkGH, reflevels, ilower, iupper, bbl); } @@ -430,7 +430,7 @@ namespace CarpetRegrid { ibb1 = bbl1.erase(ibb1); ibb2 = bbl2.erase(ibb2); ++numcombinedboxes; - cout << "MRA: Combining along " << "xyz"[dir] << " to " << bbl.back() << " size " << bbl.back().num_points() << endl; +// cout << "MRA: Combining along " << "xyz"[dir] << " to " << bbl.back() << " size " << bbl.back().num_points() << endl; goto continue_search; } @@ -504,7 +504,7 @@ namespace CarpetRegrid { const vect<int,dim> up(region.upper()); const vect<int,dim> str(region.stride()); bbl.push_back (bbox<int,dim>(lo,up+str-str/reffact,str/reffact)); - cout << "MRA: Refining to " << bbl.back() << " size " << bbl.back().num_points() << " fraction " << fraction << endl; +// cout << "MRA: Refining to " << bbl.back() << " size " << bbl.back().num_points() << " fraction " << fraction << endl; } else { // Split the region and check recursively const int dir = maxloc(region.shape()); @@ -557,7 +557,7 @@ namespace CarpetRegrid { const int tl = 0; const int ml = 0; - cout << endl << "MRA: Choosing regions to refine in " << hh->components(rl) << " components" << endl; +// cout << endl << "MRA: Choosing regions to refine in " << hh->components(rl) << " components" << endl; for (int c=0; c<hh->components(rl); ++c) { const bbox<int,dim> region = hh->extents[rl][c][ml]; @@ -573,7 +573,7 @@ namespace CarpetRegrid { for (list<bbox<int,dim> >::const_iterator ibb = bbl.begin(); ibb != bbl.end(); ++ibb) { numpoints += ibb->num_points(); } - cout << "MRA: Chose " << bbl.size() << " regions with a total size of " << numpoints << " to refine." << endl << endl; +// cout << "MRA: Chose " << bbl.size() << " regions with a total size of " << numpoints << " to refine." << endl << endl; } } // namespace CarpetRegrid |