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

Changes for lassen clang10-cuda11.2 and clang13-cuda11.6 #279

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
5 changes: 3 additions & 2 deletions benchmarks/benchmarkHelpers.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -162,9 +162,10 @@ void initialize( ArraySlice< T, NDIM, USD, INDEX_TYPE > const slice, int & iter
} );
}


// Return type is RajaView< T, PERMUTATION >,
// unexpected function type error on CUDA > 11.2 without auto
template< typename T, typename PERMUTATION >
RajaView< T, PERMUTATION > makeRajaView( ArrayT< T, PERMUTATION > const & array )
auto makeRajaView( ArrayT< T, PERMUTATION > const & array )
{
constexpr int NDIM = typeManipulation::getDimension< PERMUTATION >;
std::array< INDEX_TYPE, NDIM > sizes;
Expand Down
2 changes: 1 addition & 1 deletion host-configs/LLNL/lassen-clang10-cuda11.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ set(CMAKE_CXX_FLAGS_DEBUG "-O0 -g" CACHE STRING "")

# Set up the tpls
set(GEOSX_TPL_ROOT_DIR /usr/gapps/GEOSX/thirdPartyLibs CACHE PATH "")
set(GEOSX_TPL_DIR ${GEOSX_TPL_ROOT_DIR}/2022-11-12/install-${CONFIG_NAME}-release CACHE PATH "")
set(GEOSX_TPL_DIR ${GEOSX_TPL_ROOT_DIR}/2023-01-23/install-${CONFIG_NAME}-release CACHE PATH "")

set(CAMP_DIR ${GEOSX_TPL_DIR}/raja CACHE PATH "")
set(RAJA_DIR ${GEOSX_TPL_DIR}/raja CACHE PATH "")
Expand Down
2 changes: 1 addition & 1 deletion host-configs/LLNL/lassen-clang13-cuda11.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ set(CHAI_DIR ${GEOSX_TPL_DIR}/chai CACHE PATH "")
set(ENABLE_CALIPER ON CACHE BOOL "")
set(CALIPER_DIR ${GEOSX_TPL_DIR}/caliper CACHE PATH "")

set(ENABLE_ADDR2LINE ON CACHE BOOL "")
set(ENABLE_ADDR2LINE OFF CACHE BOOL "")

# Cuda options
set(ENABLE_CUDA ON CACHE BOOL "")
Expand Down
11 changes: 9 additions & 2 deletions src/ArrayOfArraysView.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -729,8 +729,15 @@ class ArrayOfArraysView
// capacities + numSubArrays,
// m_offsets.data() + 1 );

RAJA::inclusive_scan< POLICY >( RAJA::make_span< INDEX_TYPE const * >( capacities, numSubArrays ),
RAJA::make_span< INDEX_TYPE * >( m_offsets.data()+1, numSubArrays ) );
// RAJA::inclusive_scan< POLICY >( RAJA::make_span< INDEX_TYPE const * >( capacities, numSubArrays ),
// RAJA::make_span< INDEX_TYPE * >( m_offsets.data()+1, numSubArrays ) );

// Perform a prefix-sum to get the capacities
// (RAJA's Inclusive scan produces garbage values with CUDA 11.2.2)
for( int i = 1; i <= numSubArrays; i++ )
{
m_offsets[i] = capacities[i - 1] + m_offsets[i - 1];
}
};
resizeFromOffsetsImpl( numSubArrays, fillOffsets, buffers ... );
}
Expand Down