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

Preparing V1.9.1 release #6254

Merged
merged 72 commits into from
Jul 10, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
72 commits
Select commit Hold shift + click to select a range
32aa69b
Preparing V1.9.1 release
hkaiser May 22, 2023
d8b0500
Increase timeout threshold for circleci segmented algorithm tests
hkaiser May 25, 2023
9a6986b
Fix long tables and content
dimitraka May 11, 2023
aeee44f
Fix docs build warning: title overline too short
dimitraka May 11, 2023
e56a46d
Give NVCC more information about the type
G-071 May 24, 2023
972b136
Rewriting wait_some to circumvent data races causing hangs
hkaiser May 25, 2023
49b3142
Resolve gcc problems on Windows
hkaiser May 19, 2023
38fd73f
Remove duplicate headers, instead generate those on demand
hkaiser May 21, 2023
ed78082
Cleaning up #includes in hpx/ folder
hkaiser Apr 10, 2023
ccb88f4
Re-enable tests
G-071 May 18, 2023
1e1becb
Fix compute architecture and drop kepler
G-071 May 18, 2023
7d46238
Revert "Re-enable tests"
G-071 May 18, 2023
721a7a1
Disable troublesome tests for current cuda version
G-071 May 18, 2023
074e11f
Allow jenkins hip builds with warnings
G-071 May 18, 2023
3dad652
Remove broken node for testing
G-071 May 18, 2023
2c46a0d
Temporarily switch to rocm/4
G-071 May 19, 2023
203188c
Revert "Temporarily switch to rocm/4"
G-071 May 23, 2023
e088782
Increase test timeout
G-071 May 24, 2023
a49248c
Revert "Increase test timeout"
G-071 May 27, 2023
19dccf0
Test excluding troublesome hip alorithms test
G-071 May 27, 2023
3501af7
Cmake Tests: Delete operator check for size_t arg
SAtacker May 25, 2023
7b1fe66
Add maybe_unused attribute
SAtacker May 26, 2023
2752a07
Fix inspect issues: Add newline to the added test
SAtacker May 26, 2023
cc09711
Fix clang format formatting for Clang format 11
SAtacker May 26, 2023
934a3f1
Fixing wrong command line options in local command line handling
hkaiser May 27, 2023
01019cd
Attempt to resolve occasional hang in run_loop
hkaiser May 29, 2023
2a4b116
Modernize set_thread_name on Windows
hkaiser May 20, 2023
b8f3104
Resolving merge conflicts
hkaiser Jun 15, 2023
f7a6cd0
Attempting to fix migration tests
hkaiser May 30, 2023
d037668
Making sure the future's shared state doesn't go out of scope prematu…
hkaiser Jun 15, 2023
2a2b801
Add migration guide to manual
dimitraka May 25, 2023
f4a3309
Add openmp tasks migration guide
dimitraka Jun 1, 2023
b598287
Re-expose error names
hkaiser Jun 15, 2023
2c38814
Creating directory for file copy
hkaiser Jun 16, 2023
442e60a
Consistently #include unistd.h for _POSIX_VERSION
hkaiser Jun 17, 2023
79cb710
Update release notes
hkaiser Jun 19, 2023
92e782d
add llvm/15, gcc/13 and boost/1.82 to jenkins
akheir Jun 14, 2023
d6a0ffb
Fixing problems reported by clang-15
hkaiser Jun 14, 2023
71f7788
Fixing problems reported by gcc-13
hkaiser Jun 14, 2023
72dec0f
Fixing various feature tests
hkaiser Jun 18, 2023
d702bf8
Re-enable compiling with HPX_WITH_NETWORKING=OFF
hkaiser Jun 24, 2023
2208f1e
Improve LCI parcelport and new performance tests.
JiakunYan May 27, 2023
bad3b6f
Adding user supplied on_finalize
hkaiser Jun 26, 2023
cddb0b1
Improve the MPI parcelport and change the default zero-copy serializa…
JiakunYan Jun 5, 2023
bae0fb2
Fixing error message about use_guard_pages
hkaiser Jul 3, 2023
4e03b0a
Initial hardcoded version
G-071 Jun 19, 2023
6e5e270
Detect number of GPUs
G-071 Jun 19, 2023
ef12f35
Cleanup
G-071 Jun 19, 2023
8b8c6c0
Add missing default value
G-071 Jun 19, 2023
4d698c9
Fix format
G-071 Jun 19, 2023
db64b6a
Add missing format fix
G-071 Jun 19, 2023
20e8492
Add default device arguments
G-071 Jun 19, 2023
3e46951
Fix asserts
G-071 Jun 20, 2023
323ae69
Delete copy/move event pool constructors
G-071 Jun 21, 2023
8d46517
Fix unused parameter warning
G-071 Jun 21, 2023
017109a
Switch to east const
G-071 Jun 23, 2023
3e26df2
Add -1 default parameter for device auto-detection
G-071 Jun 23, 2023
c572755
Fix assert
G-071 Jun 27, 2023
eebcdca
Restore original device after init
G-071 Jun 27, 2023
e1a3ef9
Remove superfluous cudaSetDevice
G-071 Jun 27, 2023
aba2b0e
Put event pool singleton access definition in src
G-071 Jun 28, 2023
c2d81c3
Add basic multi gpu polling test
G-071 Jun 28, 2023
b62a3fe
Fix assert (again)
G-071 Jun 28, 2023
7e82358
Add test for default device ID
G-071 Jun 28, 2023
7da1dd0
Fix some format issues / update file author lists
G-071 Jun 28, 2023
beb233e
Fix test format
G-071 Jun 28, 2023
3b8cd90
Cal setdevice when creating events on-demand
G-071 Jun 29, 2023
afe52e7
Fix format (again)
G-071 Jun 29, 2023
1d59503
Remove superfluous api call
G-071 Jun 29, 2023
a2c6bc3
Fix inspect
G-071 Jul 6, 2023
793e5a6
update(lci pp): update the default version of LCI autofetch to v1.7.5
JiakunYan Jun 29, 2023
bf05f03
Update the documentation for the LCI parcelport.
JiakunYan Jul 2, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,7 @@ jobs:
command: |
ulimit -c unlimited
ctest \
--timeout 180 \
--timeout 270 \
-T test \
--no-compress-output \
--output-on-failure \
Expand Down
1 change: 1 addition & 0 deletions .clang-tidy
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Checks: >
-bugprone-exception-escape,
-bugprone-forward-declaration-namespace,
-bugprone-macro-parentheses,
-bugprone-branch-clone,
modernize-use-nullptr,
misc-assert-side-effect
misc-dangling-handle
Expand Down
1 change: 1 addition & 0 deletions .cmake-format.py
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,7 @@
'nargs': '1+'}},
'add_hpx_module': { 'kwargs': { 'CMAKE_SUBDIRS': '+',
'COMPAT_HEADERS': '+',
'GENERATED_HEADERS': '+',
'DEPENDENCIES': '+',
'EXCLUDE_FROM_GLOBAL_HEADER': '+',
'ADD_TO_GLOBAL_HEADER': '+',
Expand Down
62 changes: 62 additions & 0 deletions .github/workflows/windows_release_gcc_mingw.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# Copyright (c) 2023 The STE||AR-Group
#
# SPDX-License-Identifier: BSL-1.0
# Distributed under the Boost Software License, Version 1.0. (See accompanying
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)

name: Windows CI (Release, gcc/mingw toolset)

on: [pull_request]

jobs:
build:
runs-on: windows-latest

steps:
- uses: actions/checkout@v3
- uses: jwlawson/[email protected]
with:
cmake-version: '3.22.x'
- name: Install dependencies
run: |
choco install ninja -y
md C:\projects
$client = new-object System.Net.WebClient
$client.DownloadFile("https://boostorg.jfrog.io/artifactory/main/release/1.78.0/source/boost_1_78_0.7z","C:\projects\boost_1_78_0.7z")
7z x C:\projects\boost_1_78_0.7z -y -oC:\projects\boost
cd C:\projects\boost\boost_1_78_0
.\bootstrap.bat gcc
.\b2.exe `
link=shared `
variant=release `
architecture=x86 `
address-model=64 `
threading=multi `
--with-iostreams `
--build-type=complete `
install
$client.DownloadFile("https://download.open-mpi.org/release/hwloc/v2.8/hwloc-win64-build-2.8.0.zip","C:\projects\hwloc-win64-build-2.8.0.zip")
7z x C:\projects\hwloc-win64-build-2.8.0.zip -y -oC:\projects
- name: Configure
shell: bash
run: |
cmake . -Bbuild -G'Ninja' \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_CXX_COMPILER=g++ \
-DBOOST_ROOT="C:\Boost" \
-DHWLOC_ROOT="C:\projects\hwloc-win64-build-2.8.0" \
-DHPX_WITH_CXX_STANDARD=20 \
-DHPX_WITH_STATIC_LINKING=ON \
-DHPX_WITH_MALLOC=system \
-DHPX_WITH_FETCH_ASIO=ON \
-DHPX_WITH_PKGCONFIG=OFF \
-DHPX_WITH_TESTS_MAX_THREADS_PER_LOCALITY=2 \
-DHPX_WITH_EXAMPLES=ON \
-DHPX_WITH_TESTS=ON \
-DHPX_WITH_TESTS_UNIT=ON \
-DHPX_WITH_DEPRECATION_WARNINGS=OFF \
-DHPX_WITH_MODULES_AS_STATIC_LIBRARIES=OFF
- name: Build
shell: bash
run: |
cmake --build build --config Release -- -j 2
3 changes: 2 additions & 1 deletion .jenkins/lsu/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@ pipeline {
axes {
axis {
name 'configuration_name'
values 'gcc-9', 'gcc-10', 'gcc-11', 'gcc-12', 'clang-11', 'clang-12', 'clang-13', 'clang-14', 'gcc-10-cuda-11', 'hipcc'
values 'gcc-9', 'gcc-10', 'gcc-11', 'gcc-12', 'clang-11', 'clang-12', 'clang-13', 'clang-14', 'gcc-10-cuda-11', 'gcc-12-cuda-12-dgx', 'hipcc'
values 'gcc-10', 'gcc-11', 'gcc-12', 'gcc-13', 'clang-12', 'clang-13', 'clang-14', 'clang-15', 'gcc-10-cuda-11', 'gcc-12-cuda-12-dgx', 'hipcc'
}
axis {
name 'build_type'
Expand Down
2 changes: 1 addition & 1 deletion .jenkins/lsu/batch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ ulimit -l unlimited

set +e
ctest \
--verbose \
${ctest_extra_args} \
-S ${src_dir}/.jenkins/lsu/ctest.cmake \
-DCTEST_CONFIGURE_EXTRA_OPTIONS="${configure_extra_options}" \
-DCTEST_BUILD_CONFIGURATION_NAME="${configuration_name_with_build_type}" \
Expand Down
1 change: 1 addition & 0 deletions .jenkins/lsu/entry.sh
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ sbatch \
--job-name="${job_name}" \
--nodes="${configuration_slurm_num_nodes}" \
--partition="${configuration_slurm_partition}" \
--exclude="bahram" \
--time="03:00:00" \
--output="jenkins-hpx-${configuration_name_with_build_type}.out" \
--error="jenkins-hpx-${configuration_name_with_build_type}.err" \
Expand Down
36 changes: 36 additions & 0 deletions .jenkins/lsu/env-clang-15.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Copyright (c) 2020 ETH Zurich
#
# SPDX-License-Identifier: BSL-1.0
# Distributed under the Boost Software License, Version 1.0. (See accompanying
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)

module purge
module load cmake
module load llvm/15
module load boost/1.82.0-${build_type,,}
module load hwloc
module load openmpi
module load pwrapi/1.1.1

export HPXRUN_RUNWRAPPER=srun
export CXX_STD="20"

configure_extra_options+=" -DCMAKE_BUILD_TYPE=${build_type}"
configure_extra_options+=" -DHPX_WITH_CXX_STANDARD=${CXX_STD}"
configure_extra_options+=" -DHPX_WITH_MALLOC=system"
configure_extra_options+=" -DHPX_WITH_FETCH_ASIO=ON"
configure_extra_options+=" -DHPX_WITH_COMPILER_WARNINGS=ON"
configure_extra_options+=" -DHPX_WITH_COMPILER_WARNINGS_AS_ERRORS=ON"
configure_extra_options+=" -DHPX_WITH_PARCELPORT_MPI=ON"
configure_extra_options+=" -DHPX_WITH_PARCELPORT_LCI=ON"
configure_extra_options+=" -DHPX_WITH_FETCH_LCI=ON"
configure_extra_options+=" -DHPX_WITH_LOGGING=OFF"
configure_extra_options+=" -DHPX_WITH_DATAPAR_BACKEND=EVE"
configure_extra_options+=" -DHPX_WITH_FETCH_EVE=ON"

# The pwrapi library still needs to be set up properly on rostam
# configure_extra_options+=" -DHPX_WITH_POWER_COUNTER=ON"

# Make sure HWLOC does not report 'cores'. This is purely an option to enable
# testing the topology code under conditions close to those on FreeBSD.
configure_extra_options+=" -DHPX_TOPOLOGY_WITH_ADDITIONAL_HWLOC_TESTING=ON"
2 changes: 2 additions & 0 deletions .jenkins/lsu/env-common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,7 @@ if [ "${build_type}" = "Debug" ]; then
configure_extra_options+=" -DLCI_DEBUG=ON"
fi

ctest_extra_args+=" --verbose "

hostname
module avail
2 changes: 1 addition & 1 deletion .jenkins/lsu/env-gcc-10-cuda-11.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ configure_extra_options+=" -DHPX_WITH_CUDA=ON"
configure_extra_options+=" -DHPX_WITH_NETWORKING=OFF"
configure_extra_options+=" -DHPX_WITH_DISTRIBUTED_RUNTIME=OFF"
configure_extra_options+=" -DHPX_WITH_ASYNC_MPI=ON"
configure_extra_options+=" -DCMAKE_CUDA_ARCHITECTURES='37;70'"
configure_extra_options+=" -DCMAKE_CUDA_ARCHITECTURES='70;80'"
4 changes: 1 addition & 3 deletions .jenkins/lsu/env-gcc-11.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,7 @@ configure_extra_options+=" -DHPX_WITH_MALLOC=system"
configure_extra_options+=" -DHPX_WITH_FETCH_ASIO=ON"
configure_extra_options+=" -DHPX_WITH_COMPILER_WARNINGS=ON"
configure_extra_options+=" -DHPX_WITH_COMPILER_WARNINGS_AS_ERRORS=ON"
configure_extra_options+=" -DHPX_WITH_PARCELPORT_MPI=ON"
configure_extra_options+=" -DHPX_WITH_PARCELPORT_LCI=ON"
configure_extra_options+=" -DHPX_WITH_FETCH_LCI=ON"
configure_extra_options+=" -DHPX_WITH_NETWORKING=OFF"
configure_extra_options+=" -DHPX_WITH_DATAPAR_BACKEND=STD_EXPERIMENTAL_SIMD"

# The pwrapi library still needs to be set up properly on rostam
Expand Down
31 changes: 31 additions & 0 deletions .jenkins/lsu/env-gcc-13.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Copyright (c) 2020 ETH Zurich
#
# SPDX-License-Identifier: BSL-1.0
# Distributed under the Boost Software License, Version 1.0. (See accompanying
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)

module purge
module load cmake
module load gcc/13
module load boost/1.82.0-${build_type,,}
module load hwloc
module load openmpi
module load pwrapi/1.1.1

export HPXRUN_RUNWRAPPER=srun
export CXX_STD="20"

configure_extra_options+=" -DHPX_WITH_CXX_STANDARD=${CXX_STD}"
configure_extra_options+=" -DHPX_WITH_MALLOC=system"
configure_extra_options+=" -DHPX_WITH_FETCH_ASIO=ON"
configure_extra_options+=" -DHPX_WITH_COMPILER_WARNINGS=ON"
configure_extra_options+=" -DHPX_WITH_COMPILER_WARNINGS_AS_ERRORS=ON"
configure_extra_options+=" -DHPX_WITH_PARCELPORT_MPI=ON"
configure_extra_options+=" -DHPX_WITH_PARCELPORT_LCI=ON"
configure_extra_options+=" -DHPX_WITH_FETCH_LCI=ON"
configure_extra_options+=" -DHPX_WITH_DATAPAR_BACKEND=EVE"
configure_extra_options+=" -DHPX_WITH_FETCH_EVE=ON"
configure_extra_options+=" -DHPX_WITH_EVE_TAG=main"

# The pwrapi library still needs to be set up properly on rostam
# configure_extra_options+=" -DHPX_WITH_POWER_COUNTER=ON"
4 changes: 3 additions & 1 deletion .jenkins/lsu/env-hipcc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,6 @@ configure_extra_options+=" -DHPX_WITH_FETCH_ASIO=ON"
configure_extra_options+=" -DHPX_WITH_MAX_CPU_COUNT=128"
configure_extra_options+=" -DHPX_WITH_DEPRECATION_WARNINGS=OFF"
configure_extra_options+=" -DHPX_WITH_COMPILER_WARNINGS=ON"
configure_extra_options+=" -DHPX_WITH_COMPILER_WARNINGS_AS_ERRORS=ON"
configure_extra_options+=" -DHPX_WITH_COMPILER_WARNINGS_AS_ERRORS=OFF"

ctest_extra_args+=" -E tests.unit.modules.algorithms.detail "
8 changes: 8 additions & 0 deletions .jenkins/lsu/slurm-configuration-clang-15.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Copyright (c) 2020 ETH Zurich
#
# SPDX-License-Identifier: BSL-1.0
# Distributed under the Boost Software License, Version 1.0. (See accompanying
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)

configuration_slurm_partition="jenkins-compute"
configuration_slurm_num_nodes="1"
8 changes: 8 additions & 0 deletions .jenkins/lsu/slurm-configuration-gcc-13.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Copyright (c) 2020 ETH Zurich
#
# SPDX-License-Identifier: BSL-1.0
# Distributed under the Boost Software License, Version 1.0. (See accompanying
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)

configuration_slurm_partition="jenkins-compute"
configuration_slurm_num_nodes="1"
36 changes: 25 additions & 11 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,9 @@ endif()
# ##############################################################################
set(HPX_VERSION_MAJOR 1)
set(HPX_VERSION_MINOR 9)
set(HPX_VERSION_SUBMINOR 0)
set(HPX_VERSION_SUBMINOR 1)
set(HPX_VERSION_DATE 20230502)
set(HPX_VERSION_TAG "")
set(HPX_VERSION_TAG "-rc1")

set(HPX_VERSION
"${HPX_VERSION_MAJOR}.${HPX_VERSION_MINOR}.${HPX_VERSION_SUBMINOR}"
Expand Down Expand Up @@ -110,7 +110,7 @@ if(NOT HPX_CMAKE_LOGLEVEL)
endif()

# print initial diagnostics
hpx_info("CMake version: ${CMAKE_VERSION}")
hpx_info("CMake version: ${CMAKE_VERSION}, generator: ${CMAKE_GENERATOR}")
hpx_info("HPX version: ${HPX_VERSION}")

# ##############################################################################
Expand Down Expand Up @@ -373,9 +373,9 @@ endif()
# The cmake Ninja generator runs out of memory if the modules are being built as
# OBJECT libraries. In this case the fallback is to build whole-archive STATIC
# libraries.
set(HPX_WITH_MODULES_AS_STATIC_LIBRARIES_DEFAULT ON)
if("${CMAKE_MAKE_PROGRAM}" STREQUAL "ninja")
set(HPX_WITH_MODULES_AS_STATIC_LIBRARIES_DEFAULT OFF)
set(HPX_WITH_MODULES_AS_STATIC_LIBRARIES_DEFAULT OFF)
if("${CMAKE_GENERATOR}" STREQUAL "Ninja")
set(HPX_WITH_MODULES_AS_STATIC_LIBRARIES_DEFAULT ON)
endif()

hpx_option(
Expand Down Expand Up @@ -655,8 +655,8 @@ endif()
hpx_option(
HPX_WITH_ZERO_COPY_SERIALIZATION_THRESHOLD
STRING
"The threshold in bytes to when perform zero copy optimizations (default: 128)"
"128"
"The threshold in bytes to when perform zero copy optimizations (default: 8192)"
"8192"
ADVANCED
)
hpx_add_config_define(
Expand Down Expand Up @@ -1138,7 +1138,7 @@ if(HPX_WITH_NETWORKING)
ADVANCED
)
hpx_option(
HPX_WITH_LCI_TAG STRING "LCI repository tag or branch" "v1.7.4"
HPX_WITH_LCI_TAG STRING "LCI repository tag or branch" "v1.7.5"
CATEGORY "Build Targets"
ADVANCED
)
Expand Down Expand Up @@ -1754,6 +1754,12 @@ if(WIN32)
hpx_add_target_compile_option(-MP PUBLIC)
# Increase the maximum size of object file sections
hpx_add_target_compile_option(-bigobj PUBLIC)
elseif(MINGW)
if(HPX_CXX11_STD_ATOMIC_LIBRARIES)
target_link_libraries(
hpx_base_libraries INTERFACE ${HPX_CXX11_STD_ATOMIC_LIBRARIES}
)
endif()
endif()

target_link_libraries(hpx_base_libraries INTERFACE psapi shlwapi)
Expand Down Expand Up @@ -1834,8 +1840,6 @@ if(HPX_WITH_COMPILER_WARNINGS)

else() # Trial and error approach for any other compiler ...
hpx_add_compile_flag_if_available(-Wall)
hpx_add_compile_flag_if_available(-Wextra)
hpx_add_compile_flag_if_available(-Wpedantic)
hpx_add_compile_flag_if_available(-Wno-strict-aliasing)
hpx_add_compile_flag_if_available(-Wno-sign-promo)
hpx_add_compile_flag_if_available(-Wno-attributes)
Expand All @@ -1848,6 +1852,16 @@ if(HPX_WITH_COMPILER_WARNINGS)
# caused by the use of std::destructive_interference_size
hpx_add_compile_flag_if_available(-Wno-interference-size)
endif()
if("${CMAKE_CXX_COMPILER_VERSION}" VERSION_GREATER_EQUAL "13.0")
# gcc V13.x is overeager to report dangling references where there are
# none
hpx_add_compile_flag_if_available(-Wextra)
hpx_add_compile_flag_if_available(-Wpedantic)
hpx_add_compile_flag_if_available(-Wno-self-move)
endif()
else()
hpx_add_compile_flag_if_available(-Wextra)
hpx_add_compile_flag_if_available(-Wpedantic)
endif()

# We do not in general guarantee ABI compatibility between C++ standards, so
Expand Down
36 changes: 32 additions & 4 deletions cmake/HPX_AddConfigTest.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -278,6 +278,15 @@ function(hpx_check_for_cxx11_std_atomic)
unset(HPX_CXX11_STD_ATOMIC_LIBRARIES CACHE)
endif()

# we shouldn't delete this key if the user has pre-set the atomic libraries to
# use
if(HPX_CXX11_STD_ATOMIC_LIBRARIES)
set(__std_atomic_libraries
TRUE
CACHE STRING "std::atomics need separate library" FORCE
)
endif()

# first see if we can build atomics with no -latomics
add_hpx_config_test(
HPX_WITH_CXX11_ATOMIC
Expand All @@ -301,12 +310,18 @@ function(hpx_check_for_cxx11_std_atomic)
LIBRARIES ${HPX_CXX11_STD_ATOMIC_LIBRARIES}
FILE ${ARGN}
)
if(NOT HPX_WITH_CXX11_ATOMIC)
unset(HPX_CXX11_STD_ATOMIC_LIBRARIES CACHE)
unset(HPX_WITH_CXX11_ATOMIC CACHE)
if(HPX_WITH_CXX11_ATOMIC)
set(__std_atomic_libraries
TRUE
CACHE STRING "std::atomics need separate library" FORCE
)
endif()
endif()
endif()

if(NOT HPX_WITH_CXX11_ATOMIC)
hpx_error("HPX needs support for C++11 std::atomic")
endif()
endfunction()

# Separately check for 128 bit atomics
Expand Down Expand Up @@ -334,11 +349,15 @@ function(hpx_check_for_cxx11_std_atomic_128bit)
)
if(NOT HPX_WITH_CXX11_ATOMIC_128BIT)
# Adding -latomic did not help, so we don't attempt to link to it later
unset(HPX_CXX11_STD_ATOMIC_LIBRARIES CACHE)
# but only if normal atomics don't require it
if(NOT __std_atomic_libraries)
unset(HPX_CXX11_STD_ATOMIC_LIBRARIES CACHE)
endif()
unset(HPX_WITH_CXX11_ATOMIC_128BIT CACHE)
endif()
endif()
endif()
unset(__std_atomic_libraries CACHE)
endfunction()

# ##############################################################################
Expand All @@ -350,6 +369,15 @@ function(hpx_check_for_cxx11_std_shared_ptr_lwg3018)
)
endfunction()

# ##############################################################################
function(hpx_check_for_cxx14_delete_operator_with_size)
add_hpx_config_test(
HPX_WITH_CXX14_DELETE_OPERATOR_WITH_SIZE
SOURCE cmake/tests/cxx_14_delete_operator_with_size.cpp
FILE ${ARGN}
)
endfunction()

# ##############################################################################
function(hpx_check_for_c11_aligned_alloc)
add_hpx_config_test(
Expand Down
Loading