From 2e1e040ded0f0bf0aa0ecd74eb29b28df42e79ac Mon Sep 17 00:00:00 2001 From: Ann Almgren Date: Tue, 9 Jul 2024 10:45:09 -0700 Subject: [PATCH] fix compilation error (#1672) --- Source/IO/ERF_WriteScalarProfiles.cpp | 4 ++-- Source/Initialization/InputSoundingData.H | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Source/IO/ERF_WriteScalarProfiles.cpp b/Source/IO/ERF_WriteScalarProfiles.cpp index 48285c369..c4ca7a0e5 100644 --- a/Source/IO/ERF_WriteScalarProfiles.cpp +++ b/Source/IO/ERF_WriteScalarProfiles.cpp @@ -203,14 +203,14 @@ ERF::cloud_fraction (Real time) AMREX_ASSERT(numpts < Long(std::numeric_limits::max)); #if 1 - if (amrex::UseGpuAwareMpi()) { + if (ParallelDescriptor::UseGpuAwareMpi()) { ParallelDescriptor::ReduceIntMax(p,static_cast(numpts)); } else { Gpu::PinnedVector hv(numpts); Gpu::copyAsync(Gpu::deviceToHost, p, p+numpts, hv.data()); Gpu::streamSynchronize(); ParallelDescriptor::ReduceIntMax(hv.data(),static_cast(numpts)); - Gpu::copyAsync(Gpu::hostToDevice, hv,data(), hv.data()+numpts, p); + Gpu::copyAsync(Gpu::hostToDevice, hv.data(), hv.data()+numpts, p); } // Sum over component 0 diff --git a/Source/Initialization/InputSoundingData.H b/Source/Initialization/InputSoundingData.H index 495e1e84e..05bcfb72e 100644 --- a/Source/Initialization/InputSoundingData.H +++ b/Source/Initialization/InputSoundingData.H @@ -148,7 +148,7 @@ public: // = rho_d(1 + q_v) R_d T_v // integrate from surface to domain top - amrex::Real qv, dz; + amrex::Real dz; #if 1 // Printing // In this absence of moisture, this moist profile will match the // following dry profile