Skip to content

Commit

Permalink
Merge branch 'master' into inspect_assert
Browse files Browse the repository at this point in the history
  • Loading branch information
hkaiser committed Aug 30, 2017
2 parents 6008bec + 8acb6a7 commit 7d07859
Show file tree
Hide file tree
Showing 281 changed files with 12,071 additions and 6,040 deletions.
2 changes: 1 addition & 1 deletion .clang-format
Expand Up @@ -61,7 +61,7 @@ ConstructorInitializerAllOnOneLineOrOnePerLine: false
ConstructorInitializerIndentWidth: 2
ContinuationIndentWidth: 4
Cpp11BracedListStyle: true
DerivePointerAlignment: true
DerivePointerAlignment: false
ExperimentalAutoDetectBinPacking: true
FixNamespaceComments: false
# ForEachMacros: ['']
Expand Down
27 changes: 27 additions & 0 deletions CMakeLists.txt
Expand Up @@ -646,6 +646,21 @@ foreach(_scheduler ${HPX_WITH_THREAD_SCHEDULERS_UC})
unset(_all)
endforeach()

## Experimental settings
hpx_option(HPX_WITH_IO_POOL BOOL
"Disable internal IO thread pool, do not change if not absolutely necessary (default: ON)"
ON CATEGORY "Thread Manager" ADVANCED)
if(HPX_WITH_IO_POOL)
hpx_add_config_define(HPX_HAVE_IO_POOL)
endif()

hpx_option(HPX_WITH_TIMER_POOL BOOL
"Disable internal timer thread pool, do not change if not absolutely necessary (default: ON)"
ON CATEGORY "Thread Manager" ADVANCED)
if(HPX_WITH_TIMER_POOL)
hpx_add_config_define(HPX_HAVE_TIMER_POOL)
endif()

## AGAS related build options
hpx_option(HPX_WITH_AGAS_DUMP_REFCNT_ENTRIES BOOL
"Enable dumps of the AGAS refcnt tables to logs (default: OFF)"
Expand Down Expand Up @@ -808,6 +823,14 @@ hpx_option(HPX_WITH_THREAD_DESCRIPTION_FULL BOOL
OFF
CATEGORY "Debugging" ADVANCED)

hpx_option(HPX_WITH_ATTACH_DEBUGGER_ON_TEST_FAILURE BOOL
"Break the debugger if a test has failed (default: OFF)"
OFF
CATEGORY "Debugging" ADVANCED)
if(HPX_WITH_ATTACH_DEBUGGER_ON_TEST_FAILURE)
hpx_add_config_define(HPX_HAVE_ATTACH_DEBUGGER_ON_TEST_FAILURE)
endif()

# If APEX is defined, the action timers need thread debug info.
if(HPX_WITH_APEX)
hpx_add_config_define(HPX_HAVE_THREAD_DESCRIPTION)
Expand Down Expand Up @@ -1172,6 +1195,10 @@ if(NOT WIN32)
##############################################################################
# System libraries
##############################################################################
if(NOT MSVC)
hpx_libraries(atomic)
endif()

if(NOT ${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD")
hpx_libraries(dl)
endif()
Expand Down
21 changes: 20 additions & 1 deletion appveyor.yml
Expand Up @@ -9,8 +9,10 @@ environment:
matrix:
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
MSVC_GENERATOR: Visual Studio 14 2015
MSVC_GENERATOR_SHORT: VS2015
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
MSVC_GENERATOR: Visual Studio 15 2017
MSVC_GENERATOR_SHORT: VS2017

configuration:
- Debug
Expand All @@ -33,11 +35,28 @@ before_build:

build_script:
- cmd: cmake --build build --config %CONFIGURATION% --target core -- /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll" /verbosity:minimal /maxcpucount:2 /nologo
- cmd: |
7z a "hpx-master-redist-%MSVC_GENERATOR_SHORT%-%CONFIGURATION%.7z" -y "build\Debug\bin\*.dll" "build\Debug\bin\hpx\*.dll" "build\Debug\bin\*.pdb" "build\Debug\bin\hpx\*.pdb" >NUL
7z a "hpx-master-redist-%MSVC_GENERATOR_SHORT%-%CONFIGURATION%.7z" -y "build\Debug\lib\*.lib" "build\Debug\lib\hpx\*.lib" "build\src\hpx_init.dir\Debug\hpx_init.pdb" >NUL
7z a "hpx-master-redist-%MSVC_GENERATOR_SHORT%-%CONFIGURATION%.7z" -y "build\lib\cmake\HPX\*.cmake" "build\hpx\config\*.hpp" "build\hpx\runtime\parcelset\*.hpp" "hpx" "cmake\*.cmake" >NUL
- cmd: cmake --build build --config %CONFIGURATION% --target examples -- /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll" /verbosity:minimal /maxcpucount:2 /nologo
# - cmd: cmake --build build --config %CONFIGURATION% --target tests/regressions -- /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll" /verbosity:minimal /maxcpucount:2 /nologo

test_script:
- cmd: |
set PATH=%PATH%;C:\projects\vcpkg\installed\x64-windows\debug\bin
python build\bin\hpxrun.py -l2 -t2 build\Debug\bin\hello_world.exe -- --hpx:bind=none
artifacts:
- path: hpx-master-redist-$(MSVC_GENERATOR_SHORT)-$(configuration).7z
name: hpx-master-redist-$(MSVC_GENERATOR_SHORT)-$(configuration)

deploy:
provider: FTP
on:
branch: master
protocol: ftp
host: ftp.stellar-group.org
username: appveyor-ci@stellar-group.org
password:
secure: tsfxuDuvSntD/aqRcuxSvkU4lqQck85OI7e7nhDhIr4=
beta: true
8 changes: 8 additions & 0 deletions cmake/HPX_AddConfigTest.cmake
Expand Up @@ -389,6 +389,14 @@ macro(hpx_check_for_cxx11_std_array)
FILE ${ARGN})
endmacro()

###############################################################################
macro(hpx_check_for_cxx11_std_atomic)
add_hpx_config_test(HPX_WITH_CXX11_ATOMIC
SOURCE cmake/tests/cxx11_std_atomic.cpp
LIBRARIES "-latomic"
FILE ${ARGN})
endmacro()

###############################################################################
macro(hpx_check_for_cxx11_std_chrono)
add_hpx_config_test(HPX_WITH_CXX11_CHRONO
Expand Down
3 changes: 3 additions & 0 deletions cmake/HPX_PerformCxxFeatureTests.cmake
Expand Up @@ -83,6 +83,9 @@ macro(hpx_perform_cxx_feature_tests)
hpx_check_for_cxx11_std_array(
DEFINITIONS HPX_HAVE_CXX11_STD_ARRAY)

hpx_check_for_cxx11_std_atomic(
REQUIRED "HPX needs support for C++11 std::atomic")

hpx_check_for_cxx11_std_chrono(
REQUIRED "HPX needs support for C++11 std::chrono")

Expand Down
1 change: 1 addition & 0 deletions cmake/templates/HPXConfig.cmake.in
Expand Up @@ -19,6 +19,7 @@ set(HPX_INCLUDE_DIRS "@HPX_CMAKE_CONF_INCLUDE_DIRS@")
set(HPX_LIBRARIES "@HPX_CONF_LIBRARIES@")
set(HPX_LIBRARY_DIR "@HPX_CONF_LIBRARY_DIR@")

set(HPX_VERSION_STRING "@HPX_VERSION@")
set(HPX_MAJOR_VERSION @HPX_MAJOR_VERSION@)
set(HPX_MINOR_VERSION @HPX_MINOR_VERSION@)
set(HPX_PATCH_LEVEL @HPX_PATCH_LEVEL@)
Expand Down
26 changes: 26 additions & 0 deletions cmake/tests/cxx11_std_atomic.cpp
@@ -0,0 +1,26 @@
////////////////////////////////////////////////////////////////////////////////
// Copyright (c) 2017 Agustin Berge
//
// 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)
////////////////////////////////////////////////////////////////////////////////

#include <atomic>

int main()
{
std::atomic_flag af = ATOMIC_FLAG_INIT;
if (af.test_and_set())
af.clear();

std::atomic<int> ai;
ai.store(0);
int i = ai.load();

std::memory_order mo;
mo = std::memory_order_relaxed;
mo = std::memory_order_acquire;
mo = std::memory_order_release;
mo = std::memory_order_acq_rel;
mo = std::memory_order_seq_cst;
}
1 change: 1 addition & 0 deletions docs/CMakeLists.txt
Expand Up @@ -183,6 +183,7 @@ set(doxygen_dependencies
"${PROJECT_SOURCE_DIR}/hpx/lcos/wait_each.hpp"
"${PROJECT_SOURCE_DIR}/hpx/lcos/when_each.hpp"
"${PROJECT_SOURCE_DIR}/hpx/traits/is_execution_policy.hpp"
"${PROJECT_SOURCE_DIR}/hpx/util/debugging.hpp"
"${PROJECT_SOURCE_DIR}/hpx/util/invoke.hpp"
"${PROJECT_SOURCE_DIR}/hpx/util/invoke_fused.hpp"
"${PROJECT_SOURCE_DIR}/hpx/util/pack_traversal.hpp"
Expand Down
3 changes: 3 additions & 0 deletions docs/hpx.idx
Expand Up @@ -526,6 +526,9 @@ when_each_n "" "header\.hpx\.lcos\.when_each.*"
wait_each "" "header\.hpx\.lcos\.wait_each.*"
wait_each_n "" "header\.hpx\.lcos\.wait_each.*"

# hpx/util/debugging.hpp
attach_debugger "" "header\.hpx\.util\.attach_debugger.*"

# hpx/util/invoke.hpp
invoke "" "header\.hpx\.util\.invoke.*"
invoke_r "" "header\.hpx\.util\.invoke_r.*"
Expand Down

0 comments on commit 7d07859

Please sign in to comment.