Skip to content

Commit

Permalink
Merge pull request #11 from streeve/kokkos_3.7
Browse files Browse the repository at this point in the history
Require Kokkos 3.7 for the math namespace update
  • Loading branch information
steverangel authored Jun 8, 2023
2 parents 3e27de7 + dc7181a commit b9be8dd
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
uses: actions/[email protected]
with:
repository: kokkos/kokkos
ref: 3.6.01
ref: 3.7.01
path: kokkos
- name: Build kokkos
working-directory: kokkos
Expand Down
5 changes: 4 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ project(HACCabana LANGUAGES CXX C)

include(GNUInstallDirs)

find_package(Cabana)
find_package(Cabana REQUIRED)
if(Kokkos_VERSION_MAJOR LESS 4 AND Kokkos_VERSION_MINOR LESS 7)
message( FATAL_ERROR "HACCabana requires Kokkos >= 3.7" )
endif()

add_subdirectory(src)
2 changes: 1 addition & 1 deletion src/ParticleActions.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ void ParticleActions::updateVel(\
if (dist2 < rmax2)
{
const float dist2Err = dist2 + rsm2;
const float tmp = 1.0f/Kokkos::Experimental::sqrt(dist2Err*dist2Err*dist2Err) - FGridEvalPoly(dist2);
const float tmp = 1.0f/Kokkos::sqrt(dist2Err*dist2Err*dist2Err) - FGridEvalPoly(dist2);
force[0] += dx * tmp;
force[1] += dy * tmp;
force[2] += dz * tmp;
Expand Down

0 comments on commit b9be8dd

Please sign in to comment.