Skip to content

Reply To: SuperLatticePhysHeatFlux3D Different Results on GPU vs CPU

Due to recent bot attacks we have chanced the sign-up process. If you want to participate in our forum, first register on this website and then send a message via our contact form.

Forums on OpenLB Bug Reports SuperLatticePhysHeatFlux3D Different Results on GPU vs CPU Reply To: SuperLatticePhysHeatFlux3D Different Results on GPU vs CPU

#7818
Adrian
Keymaster

Glad to hear it.

Just adding to your hint: While it makes sense to synchronize the entire state to CPU for post processing results (i.e. call sLattice.setProcessingContext(ProcessingContext::Evaluation)), doing the “copy-to-CPU-update-copy-to-GPU” roundtrip is often not necessary and can reduce performance.
E.g. if you only update the inflow velocity it can be sufficient to update the data on CPU and copy only the relevant field to GPU. There also is the option of using background processing to hide IO while the simulation continues. See e.g. the turbulence/nozzle3d case for an application of these concepts.