Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CI: Update Jenkins #568

Merged
merged 65 commits into from
Sep 10, 2024
Merged
Show file tree
Hide file tree
Changes from 55 commits
Commits
Show all changes
65 commits
Select commit Hold shift + click to select a range
b6eea87
comment out spack and TPL setup
gardner48 Aug 28, 2024
09a18ee
update output files
gardner48 Aug 28, 2024
1025002
update f2003 output files
gardner48 Aug 28, 2024
185179e
enable cuda
gardner48 Aug 30, 2024
e748764
set cuda arch
gardner48 Aug 30, 2024
56d306c
update TPL versions
gardner48 Aug 30, 2024
2236d71
fix spack specs
gardner48 Aug 30, 2024
8af72bb
switch to xbraid 3.0.0
gardner48 Aug 30, 2024
a2eed54
serial builds
gardner48 Aug 30, 2024
1fc6568
use trilinos+cuda
gardner48 Aug 30, 2024
8513596
test with kokkos~cuda and trilinos~cuda
gardner48 Aug 30, 2024
ead0aab
kokkos +cuda and trilinos ~cuda
gardner48 Aug 30, 2024
19d8a6f
kokkos~cuda and trilinos+cuda
gardner48 Aug 30, 2024
b155d4f
use trilinos imported targets, comment out compile check
gardner48 Aug 30, 2024
00712f7
remove trilinos interface options
gardner48 Sep 4, 2024
a2b76f8
update compile test
gardner48 Sep 4, 2024
377afa3
update link libraries
gardner48 Sep 5, 2024
ea8d9c3
comment out trilinos and ginkgo
gardner48 Sep 5, 2024
66a93f5
update jenkins readme
gardner48 Sep 6, 2024
dfd569d
disable some warnings in benchmarks
gardner48 Sep 6, 2024
cb36dc7
update for RAJA 2024+
gardner48 Sep 6, 2024
92fa5c0
remove set commands
gardner48 Sep 6, 2024
7526c7f
update some tpl output files
gardner48 Sep 6, 2024
e8a2635
get hypre version and init/finalize hypre
gardner48 Sep 6, 2024
fb04a81
fix hypre version macros
gardner48 Sep 6, 2024
542a8e4
fix build
gardner48 Sep 6, 2024
d70fb55
fix xbraid build
gardner48 Sep 6, 2024
1b146fe
update some hypre output files
gardner48 Sep 7, 2024
aaff29e
add hypre init/finalize to mri example
gardner48 Sep 7, 2024
2eed9d5
define KLUSolverFn based on SuiteSparse version
gardner48 Sep 7, 2024
c615fc2
update out files
gardner48 Sep 7, 2024
3c1b2a3
update out files
gardner48 Sep 7, 2024
c77fd9b
fix compiler warnings
gardner48 Sep 7, 2024
baad49b
fix msglen
gardner48 Sep 8, 2024
7a8f933
rename output files to avoid collision with C_parallel example
gardner48 Sep 8, 2024
e035035
update out file
gardner48 Sep 8, 2024
0c46dee
exclude some ida test with 64-bit ints
gardner48 Sep 8, 2024
c347004
kokkos +cuda
gardner48 Sep 8, 2024
78e23d6
enable ginkgo tests, avoid deprecated functions
gardner48 Sep 9, 2024
926001f
update ginkgo output files
gardner48 Sep 9, 2024
6cbf057
fix identity construction
gardner48 Sep 9, 2024
ae5327c
do not test bicgstab with openmp
gardner48 Sep 9, 2024
95cd627
fix trilinos cuda build, only test cpu builds
gardner48 Sep 9, 2024
41706a6
fix spec
gardner48 Sep 9, 2024
f7e71a4
remove Trilinos compile test
gardner48 Sep 9, 2024
d9c17f9
fix compiler warning
gardner48 Sep 9, 2024
10580de
update trilinos output file
gardner48 Sep 9, 2024
ed0b746
test trilinos with int32 global indexing
gardner48 Sep 10, 2024
6381b29
update env file
gardner48 Sep 10, 2024
e774837
fix spelling
gardner48 Sep 10, 2024
01c4311
apply formatting
gardner48 Sep 10, 2024
897e352
enable parallel builds, update comments
gardner48 Sep 10, 2024
3cddacc
add Trilinos CMake options
gardner48 Sep 10, 2024
411c1a8
update recent changes
gardner48 Sep 10, 2024
5f19f78
Update doc/shared/RecentChanges.rst
gardner48 Sep 10, 2024
a610b0f
Update doc/shared/RecentChanges.rst
gardner48 Sep 10, 2024
93b0470
Update CHANGELOG.md
gardner48 Sep 10, 2024
f464f0c
update SUNDIALSConfig to use find_dependency for Trilinos
gardner48 Sep 10, 2024
a5d767d
fix capitalization
gardner48 Sep 10, 2024
3182824
disable Trilinos in GitHub tests
gardner48 Sep 10, 2024
76c3701
fix warnings with long double
gardner48 Sep 10, 2024
109f622
update ginkgo comment
gardner48 Sep 10, 2024
403eea9
apply formatting
gardner48 Sep 10, 2024
c5e348e
update answer submodule
gardner48 Sep 10, 2024
eb8883a
update answer submodule commit
gardner48 Sep 10, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,23 @@ Volta GPUs while the automatically selected value will vary across compilers and
compiler versions. As such, users are encouraged to override this value with the
architecture for their system.

The Trilinos Teptra NVector interface has been updated to utilized CMake
gardner48 marked this conversation as resolved.
Show resolved Hide resolved
imported targets added in Trilinos 14 to improve support for different Kokkos
backends with Trilinos. As such, Trilinos 14 or newer is required and the
`Trilinos_INTERFACE_*` CMake options have been removed.

Example programs using *hypre* have been updated to support v2.20 and newer.

### Bug Fixes

Fixed the loading of ARKStep's default first order explicit method.

Fixed a CMake bug regarding usage of missing "print_warning" macro
that was only triggered when the deprecated `CUDA_ARCH` option was used.

Fixed compilation errors when building the Trilinos Teptra NVector with CUDA
support.

### Deprecation Notices

## Changes to SUNDIALS in release 7.1.1
Expand Down
6 changes: 4 additions & 2 deletions benchmarks/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,10 @@ sundials_option(BENCHMARK_NVECTOR BOOL "NVector benchmarks are on" ON)

# Disable some warnings for benchmarks
if(ENABLE_ALL_WARNINGS)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-parameter")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-parameter")
set(CMAKE_C_FLAGS
"${CMAKE_C_FLAGS} -Wno-unused-parameter -Wno-unused-function")
set(CMAKE_CXX_FLAGS
"${CMAKE_CXX_FLAGS} -Wno-unused-parameter -Wno-unused-function")
endif()

# ----------------------------------------
Expand Down
15 changes: 13 additions & 2 deletions benchmarks/advection_reaction_3D/raja/backends.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -114,12 +114,23 @@ using XYZ_KERNEL_POL =

#else
#define NVECTOR_ID_STRING "Serial"
using EXEC_POLICY = RAJA::seq_exec;
using XYZ_KERNEL_POL = RAJA::KernelPolicy<RAJA::statement::For<

#if RAJA_VERSION_MAJOR < 2024
using EXEC_POLICY = RAJA::seq_exec;
using XYZ_KERNEL_POL = RAJA::KernelPolicy<RAJA::statement::For<
2, RAJA::loop_exec,
RAJA::statement::For<
1, RAJA::loop_exec,
RAJA::statement::For<0, RAJA::loop_exec, RAJA::statement::Lambda<0>>>>>;
#else
using EXEC_POLICY = RAJA::seq_exec;
using XYZ_KERNEL_POL = RAJA::KernelPolicy<RAJA::statement::For<
2, RAJA::seq_exec,
RAJA::statement::For<
1, RAJA::seq_exec,
RAJA::statement::For<0, RAJA::seq_exec, RAJA::statement::Lambda<0>>>>>;
#endif

constexpr auto LocalNvector = N_VNew_Serial;
#define CopyVecFromDevice(v)

Expand Down
2 changes: 1 addition & 1 deletion cmake/SundialsBuildOptionsPost.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ list(APPEND SUNDIALS_BUILD_LIST "BUILD_NVECTOR_RAJA")
sundials_option(
BUILD_NVECTOR_TRILINOS BOOL
"Build the NVECTOR_TRILINOS module (requires Trilinos)" ON
DEPENDS_ON ENABLE_TRILINOS Trilinos_WORKS
DEPENDS_ON ENABLE_TRILINOS
ADVANCED)
list(APPEND SUNDIALS_BUILD_LIST "BUILD_NVECTOR_TRILINOS")

Expand Down
2 changes: 1 addition & 1 deletion cmake/SundialsSetupConfig.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ foreach(tpl ${SUNDIALS_TPL_LIST})
endforeach()

# prepare substitution variable SUNDIALS_TRILINOS_HAVE_MPI for sundials_config.h
if(Trilinos_MPI)
if(ENABLE_MPI)
set(SUNDIALS_TRILINOS_HAVE_MPI TRUE)
endif()

Expand Down
36 changes: 0 additions & 36 deletions cmake/SundialsTPLOptions.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -269,42 +269,6 @@ sundials_option(ENABLE_TRILINOS BOOL "Enable Trilinos support" OFF)
sundials_option(Trilinos_DIR PATH "Path to root of Trilinos installation"
"${Trilinos_DIR}" DEPENDS_ON ENABLE_TRILINOS)

sundials_option(
Trilinos_INTERFACE_CXX_COMPILER STRING "C++ compiler for Trilinos interface"
"${Trilinos_CXX_COMPILER}"
DEPENDS_ON ENABLE_TRILINOS
ADVANCED)

sundials_option(
Trilinos_INTERFACE_C_COMPILER STRING "C compiler for Trilinos interface"
"${Trilinos_C_COMPILER}"
DEPENDS_ON ENABLE_TRILINOS
ADVANCED)

sundials_option(
Trilinos_INTERFACE_CXX_COMPILER_FLAGS STRING
"C++ compiler flags for Trilinos interface" "${Trilinos_CXX_COMPILER_FLAGS}"
DEPENDS_ON ENABLE_TRILINOS
ADVANCED)

sundials_option(
Trilinos_INTERFACE_C_COMPILER_FLAGS STRING
"C compiler flags for Trilinos interface" "${Trilinos_C_COMPILER_FLAGS}"
DEPENDS_ON ENABLE_TRILINOS
ADVANCED)

sundials_option(
Trilinos_INTERFACE_MPIEXEC STRING "MPI executable for Trilinos interface"
"${Trilinos_MPI_EXEC}"
DEPENDS_ON ENABLE_TRILINOS
ADVANCED)

sundials_option(
Trilinos_WORKS BOOL
"Set to ON to force CMake to accept a given Trilinos configuration" OFF
DEPENDS_ON ENABLE_TRILINOS
ADVANCED)

# ---------------------------------------------------------------
# Enable XBraid support?
# ---------------------------------------------------------------
Expand Down
21 changes: 19 additions & 2 deletions cmake/tpl/FindHYPRE.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ else()
HYPRE_LIBRARY
NAMES ${HYPRE_LIBRARY_NAMES}
HINTS "${HYPRE_DIR}" "${HYPRE_DIR}/lib" "${HYPRE_DIR}/lib64"
"${HYPRE_LIBRARY_DIR}"
NO_DEFAULT_PATH)
"${HYPRE_LIBRARY_DIR}")
endif()
mark_as_advanced(HYPRE_LIBRARY)

Expand All @@ -71,6 +70,23 @@ if(_idx EQUAL -1)
CACHE STRING "" FORCE)
endif()

# Extract version parts from the version information
if(HYPRE_INCLUDE_DIR)

# HYPRE_config.h file added in at least v2.11.0 (possibly sooner)
find_file(HYPRE_CONFIG_FILE HYPRE_config.h PATHS "${HYPRE_INCLUDE_DIR}")

file(STRINGS "${HYPRE_CONFIG_FILE}" _hypre_release_version
REGEX "HYPRE_RELEASE_VERSION")
string(REGEX MATCH "[0-9]+\.[0-9]+\.[0-9]+" HYPRE_VERSION
"${_hypre_release_version}")
string(REGEX MATCHALL "[0-9]+" _hypre_version_numbers "${HYPRE_VERSION}")
list(GET _hypre_version_numbers 0 HYPRE_VERSION_MAJOR)
list(GET _hypre_version_numbers 1 HYPRE_VERSION_MINOR)
list(GET _hypre_version_numbers 2 HYPRE_VERSION_PATCH)

endif()

# set a more informative error message in case the library was not found
set(HYPRE_NOT_FOUND_MESSAGE
"\
Expand All @@ -83,6 +99,7 @@ ERROR: Could not find HYPRE. Please check the variables:\n\
find_package_handle_standard_args(
HYPRE
REQUIRED_VARS HYPRE_LIBRARY HYPRE_LIBRARIES HYPRE_INCLUDE_DIR
VERSION_VAR HYPRE_VERSION
FAIL_MESSAGE "${HYPRE_NOT_FOUND_MESSAGE}")

# Create target for HYPRE
Expand Down
49 changes: 0 additions & 49 deletions cmake/tpl/FindTrilinos.cmake

This file was deleted.

152 changes: 12 additions & 140 deletions cmake/tpl/SundialsTrilinos.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,7 @@
# Section 1: Include guard
# -----------------------------------------------------------------------------

if(NOT DEFINED SUNDIALS_TRILINOS_INCLUDED)
set(SUNDIALS_TRILINOS_INCLUDED)
else()
return()
endif()
include_guard(GLOBAL)

# -----------------------------------------------------------------------------
# Section 2: Check to make sure options are compatible
Expand All @@ -41,144 +37,20 @@ endif()
# -----------------------------------------------------------------------------

# Find Trilinos
find_package(Trilinos REQUIRED)
find_package(
Trilinos REQUIRED
COMPONENTS Tpetra HINTS "${Trilinos_DIR}/lib/cmake/Trilinos"
"${Trilinos_DIR}")

# Check if Trilinos was built with MPI Starting with TriBITS 2022-10-16
# <Project_TPL_LIST> is no longer defined so we base MPI support on ENABLE_MPI
if(Trilinos_TPL_LIST)
if(";${Trilinos_TPL_LIST};" MATCHES ";MPI;")
set(Trilinos_MPI TRUE)
else()
set(Trilinos_MPI FALSE)
endif()
else()
if(ENABLE_MPI)
set(Trilinos_MPI TRUE)
else()
set(Trilinos_MPI FALSE)
endif()
endif()

# For XSDK compatibility, only use the user/spack provided compiler and flags to
# build SUNDIALS modules that use Trilinos. If we are not in XSDK mode, we can
# use the imported Trilinos compiler and flags by default, but allow the user to
# change it through CMake the Trilinos_INTERFACE_* options.

if(USE_XSDK_DEFAULTS)
if(Trilinos_MPI AND MPI_CXX_FOUND)
force_variable(Trilinos_INTERFACE_CXX_COMPILER STRING
"C++ compiler for Trilinos interface" "${MPI_CXX_COMPILER}")
set(Trilinos_INTERFACE_MPI_CXX_FOUND
${Trilinos_MPI}
CACHE INTERNAL "Is Trilinos interface C++ compiler MPI")
else()
force_variable(Trilinos_INTERFACE_CXX_COMPILER STRING
"C compiler for Trilinos interface" "${CMAKE_CXX_COMPILER}")
set(Trilinos_INTERFACE_MPI_CXX_FOUND
FALSE
CACHE INTERNAL "Is Trilinos interface C++ compiler MPI")
endif()
if(Trilinos_MPI AND MPI_C_FOUND)
force_variable(Trilinos_INTERFACE_C_COMPILER STRING
"C compiler for Trilinos interface" "${MPI_C_COMPILER}")
set(Trilinos_INTERFACE_MPI_C_FOUND
${Trilinos_MPI}
CACHE INTERNAL "Is Trilinos interface C compiler MPI")
else()
force_variable(Trilinos_INTERFACE_C_COMPILER STRING
"C compiler for Trilinos interface" "${CMAKE_C_COMPILER}")
set(Trilinos_INTERFACE_MPI_C_FOUND
FALSE
CACHE INTERNAL "Is Trilinos interface C compiler MPI")
endif()
force_variable(Trilinos_INTERFACE_CXX_COMPILER_FLAGS STRING
"C++ compiler flags specific to Trilinos interface" "")
force_variable(Trilinos_INTERFACE_C_COMPILER_FLAGS STRING
"C compiler flags specific to Trilinos interface" "")
force_variable(
Trilinos_INTERFACE_MPIEXEC STRING "MPI executable for Trilinos interface"
"${MPIEXEC_EXECUTABLE}")
else()
force_variable(
Trilinos_INTERFACE_CXX_COMPILER STRING
"C++ compiler for Trilinos interface" "${Trilinos_CXX_COMPILER}")
force_variable(Trilinos_INTERFACE_C_COMPILER STRING
"C compiler for Trilinos interface" "${Trilinos_C_COMPILER}")
force_variable(
Trilinos_INTERFACE_CXX_COMPILER_FLAGS STRING
"C++ compiler flags for Trilinos interface"
"${Trilinos_CXX_COMPILER_FLAGS}")
force_variable(
Trilinos_INTERFACE_C_COMPILER_FLAGS STRING
"C compiler flags for Trilinos interface" "${Trilinos_C_COMPILER_FLAGS}")
force_variable(Trilinos_INTERFACE_MPIEXEC STRING
"MPI executable for Trilinos interface" "${Trilinos_MPI_EXEC}")
set(Trilinos_INTERFACE_MPI_CXX_FOUND
${Trilinos_MPI}
CACHE INTERNAL "Is Trilinos interface C++ compiler MPI")
set(Trilinos_INTERFACE_MPI_C_FOUND
${Trilinos_MPI}
CACHE INTERNAL "Is Trilinos interface C compiler MPI")
endif()

message(STATUS "Trilinos_MPI: ${Trilinos_MPI}")
message(STATUS "Trilinos_LIBRARIES: ${Trilinos_LIBRARIES}")
message(STATUS "Trilinos_INCLUDE_DIRS: ${Trilinos_INCLUDE_DIRS}")
message(STATUS "Trilinos Libraries: ${Trilinos_LIBRARIES}")
message(STATUS "Trilinos Includes: ${Trilinos_INCLUDE_DIRS}")
message(STATUS "Trilinos Devices: ${Kokkos_DEVICES}")

# -----------------------------------------------------------------------------
# Section 4: Test the TPL
# -----------------------------------------------------------------------------

if(Trilinos_FOUND AND (NOT Trilinos_WORKS))
# Do any checks which don't require compilation first.

# Create the Trilinos_TEST directory
set(Trilinos_TEST_DIR ${PROJECT_BINARY_DIR}/Trilinos_TEST)
file(MAKE_DIRECTORY ${Trilinos_TEST_DIR})

# Create a CMakeLists.txt file
file(
WRITE ${Trilinos_TEST_DIR}/CMakeLists.txt
"CMAKE_MINIMUM_REQUIRED(VERSION ${CMAKE_VERSION})\n"
"PROJECT(ltest CXX)\n"
"SET(CMAKE_VERBOSE_MAKEFILE ON)\n"
"SET(CMAKE_BUILD_TYPE \"${CMAKE_BUILD_TYPE}\")\n"
"SET(CMAKE_CXX_COMPILER \"${Trilinos_INTERFACE_CXX_COMPILER}\")\n"
"SET(CMAKE_CXX_STANDARD \"${CMAKE_CXX_STANDARD}\")\n"
"SET(CMAKE_CXX_FLAGS \"${Trilinos_INTERFACE_CXX_COMPILER_FLAGS}\")\n"
"SET(Trilinos_DIR \"${Trilinos_DIR}\")\n"
"INCLUDE(FindPackageHandleStandardArgs)\n"
"INCLUDE(${PROJECT_SOURCE_DIR}/cmake/tpl/FindTrilinos.cmake)\n"
"ADD_EXECUTABLE(ltest ltest.cpp)\n"
"TARGET_LINK_LIBRARIES(ltest SUNDIALS::TRILINOS)\n")

# Create a C++ source file which calls a Trilinos function
file(WRITE ${Trilinos_TEST_DIR}/ltest.cpp
"#include <Tpetra_Version.hpp>\n" "int main(void) {\n"
"std::cout << Tpetra::version() << std::endl;\n" "return(0);\n" "}\n")

# Attempt to build and link the "ltest" executable
try_compile(
COMPILE_OK ${Trilinos_TEST_DIR}
${Trilinos_TEST_DIR} ltest
OUTPUT_VARIABLE COMPILE_OUTPUT)

# Process test result
if(COMPILE_OK)
message(STATUS "Checking if Trilinos works with SUNDIALS... OK")
set(Trilinos_WORKS
TRUE
CACHE BOOL "Trilinos works with SUNDIALS as configured" FORCE)
else()
message(STATUS "Checking if Trilinos works with SUNDIALS... FAILED")
message(STATUS "Check output: ")
message("${COMPILE_OUTPUT}")
message(FATAL_ERROR "SUNDIALS interface to Trilinos is not functional.")
endif()

elseif(Trilinos_FOUND AND Trilinos_WORKS)
message(
STATUS
"Skipped Trilinos tests, assuming Trilinos works with SUNDIALS. Set Trilinos_WORKS=FALSE to (re)run compatibility test."
)
endif()
# Does not currently work with Trilinos imported targets due to an error from
# evaluating generator expression: $<LINK_LANGUAGE:CXX> may only be used with
# binary targets to specify link libraries, link directories, link options and
# link depends.
Loading
Loading