Skip to content

Commit

Permalink
Merge #6213 #6227
Browse files Browse the repository at this point in the history
6213: Modernize and streamline MPI parcelport r=hkaiser a=hkaiser

- adding more locking where needed, more sanity tests
- adding more logging in the parcel layer
- allowing for all logging to go to the same file (`HPX_LOGGING_WITH_SEPARATE_DESTINATIONS`), the default is the old behavior of having separate logging destinations

This attempts to resolve deadlock situations during startup of the MPI parcelport under high contention.

6227: Reliably disable background work when no networking is enabled r=hkaiser a=hkaiser



Co-authored-by: Hartmut Kaiser <[email protected]>
  • Loading branch information
StellarBot and hkaiser committed Apr 20, 2023
3 parents 42d6642 + 98e219d + c82e8f3 commit 8a577a9
Show file tree
Hide file tree
Showing 52 changed files with 1,045 additions and 754 deletions.
1 change: 1 addition & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,7 @@ jobs:
-DHPX_WITH_TESTS_DEBUG_LOG_DESTINATION=/hpx/build/debug-log.txt \
-DHPX_WITH_SPINLOCK_DEADLOCK_DETECTION=On \
-DHPX_WITH_CHECK_MODULE_DEPENDENCIES=On \
-DHPX_LOGGING_WITH_SEPARATE_DESTINATIONS=Off \
-DCMAKE_EXPORT_COMPILE_COMMANDS=On \
-DHPX_WITH_DOCUMENTATION=On \
-DHPX_WITH_DOCUMENTATION_OUTPUT_FORMATS="${DOCUMENTATION_OUTPUT_FORMATS}"
Expand Down
4 changes: 2 additions & 2 deletions cmake/HPX_AddDefinitions.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -185,15 +185,15 @@ function(write_config_defines_file)
if(NOT OPTION_TEMPLATE)
string(TOUPPER ${OPTION_NAMESPACE} NAMESPACE_UPPER)
set(PREAMBLE
"// Copyright (c) 2019-2020 STE||AR Group\n"
"// Copyright (c) 2019-2023 STE||AR Group\n"
"//\n"
"// SPDX-License-Identifier: BSL-1.0\n"
"// Distributed under the Boost Software License, Version 1.0. (See accompanying\n"
"// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)\n"
"\n"
"// Do not edit this file! It has been generated by the cmake configuration step.\n"
"\n"
"#pragma once"
"#pragma once\n"
)
set(TEMP_FILENAME
"${PROJECT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/${NAMESPACE_UPPER}"
Expand Down
2 changes: 1 addition & 1 deletion libs/core/assertion/include/hpx/modules/assertion.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ namespace hpx::assertion {

#define HPX_ASSERT_LOCKED_(l, expr, msg) \
(!!(expr) ? void() : \
(l.unlock(), \
((l).unlock(), \
::hpx::assertion::detail::handle_assert( \
HPX_CURRENT_SOURCE_LOCATION(), HPX_PP_STRINGIZE(expr), \
msg))) /**/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ namespace hpx::local::detail {
hpx::program_options::variables_map& vm,
std::vector<std::string>& ini_config);

void enable_logging_settings(hpx::program_options::variables_map& vm,
static void enable_logging_settings(
hpx::program_options::variables_map& vm,
std::vector<std::string>& ini_config);

void store_command_line(int argc, char** argv);
Expand All @@ -85,8 +86,8 @@ namespace hpx::local::detail {
hpx::program_options::variables_map& prevm);

void handle_high_priority_threads(
hpx::program_options::variables_map& vm,
std::vector<std::string>& ini_config);
hpx::program_options::variables_map const& vm,
std::vector<std::string>& ini_config) const;
};

///////////////////////////////////////////////////////////////////////////
Expand All @@ -98,8 +99,9 @@ namespace hpx::local::detail {

HPX_CORE_EXPORT std::string convert_to_log_file(std::string const& dest);

HPX_CORE_EXPORT std::size_t handle_num_cores(util::manage_config& cfgmap,
hpx::program_options::variables_map& vm, std::size_t num_threads,
HPX_CORE_EXPORT std::size_t handle_num_cores_default(
util::manage_config& cfgmap,
hpx::program_options::variables_map const& vm, std::size_t num_threads,
std::size_t num_default_cores);

HPX_CORE_EXPORT std::size_t get_number_of_default_threads(
Expand Down
Loading

0 comments on commit 8a577a9

Please sign in to comment.