Skip to content

Commit

Permalink
Fix atlas_fctest_field_host with ENABLE_CUDA=1 (fixes #216)
Browse files Browse the repository at this point in the history
  • Loading branch information
wdeconinck committed Aug 7, 2024
1 parent ceb25f9 commit 74baa23
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/atlas_f/atlas_f.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

#define ATLAS_HAVE_OMP @atlas_HAVE_OMP_Fortran@
#define ATLAS_HAVE_ACC @atlas_HAVE_ACC@
#define ATLAS_HAVE_CUDA @atlas_HAVE_CUDA@
#define ATLAS_BITS_GLOBAL @ATLAS_BITS_GLOBAL@
#define ATLAS_BITS_LOCAL @ATLAS_BITS_LOCAL@

Expand Down
3 changes: 3 additions & 0 deletions src/tests/field/fctest_field_host.F90
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
! @author Willem Deconinck

#include "fckit/fctest.h"
#include "atlas/atlas_f.h"

! -----------------------------------------------------------------------------

Expand Down Expand Up @@ -49,7 +50,9 @@ module fcta_Field_fxt
call field%data(view)

FCTEST_CHECK( .not. field%host_needs_update() )
#if ! ATLAS_HAVE_CUDA
FCTEST_CHECK( .not. field%device_needs_update() )
#endif

call field%update_device()
FCTEST_CHECK( .not. field%device_needs_update() )
Expand Down

0 comments on commit 74baa23

Please sign in to comment.