From b1ad3c03ffce1dbfdfb38fd4709fb0f63bc9ec8b Mon Sep 17 00:00:00 2001 From: Prabhat Kumar <89051199+prkkumar@users.noreply.github.com> Date: Fri, 5 May 2023 15:48:05 -0700 Subject: More Managed Memory Fixes: Diagnostics (#3899) * Interpolate on GPU * another fix in Diagnostics --- Source/Utils/Interpolate.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Source/Utils/Interpolate.cpp') diff --git a/Source/Utils/Interpolate.cpp b/Source/Utils/Interpolate.cpp index 3483284ec..9d20e7485 100644 --- a/Source/Utils/Interpolate.cpp +++ b/Source/Utils/Interpolate.cpp @@ -51,14 +51,15 @@ namespace Interpolate if ( F_fp.is_nodal() ){ amrex::IntVect refinement_vector{AMREX_D_DECL(r_ratio[0], r_ratio[1], r_ratio[2])}; node_bilinear_interp.interp(cfab, 0, ffab, 0, 1, - finebx, refinement_vector, {}, {}, {}, 0, 0, RunOn::Cpu); + finebx, refinement_vector, {}, {}, {}, 0, 0, RunOn::Device); } else { amrex::Abort("Unknown field staggering."); } // Add temporary array to the returned structure const Box& bx = (*interpolated_F)[mfi].box(); - (*interpolated_F)[mfi].plus(ffab, bx, bx, 0, 0, 1); + (*interpolated_F)[mfi].plus(ffab, bx, bx, 0, 0, 1); + amrex::Gpu::streamSynchronize(); } } return interpolated_F; -- cgit v1.2.3