Skip to content
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
1 change: 1 addition & 0 deletions .codacy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,6 @@ exclude_paths:
tools:
duplication:
exclude:
- "examples/**"
- "tests/**"
- "**/tests/**"
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,11 @@

#include <hpx/config.hpp>
#include <hpx/assert.hpp>
#include <hpx/distribution_policies/container_distribution_policy.hpp>
#include <hpx/distribution_policies/explicit_container_distribution_policy.hpp>
#include <hpx/modules/actions_base.hpp>
#include <hpx/modules/async_base.hpp>
#include <hpx/modules/async_combinators.hpp>
#include <hpx/modules/components.hpp>
#include <hpx/modules/distribution_policies.hpp>
#include <hpx/modules/functional.hpp>
#include <hpx/modules/runtime_components.hpp>
#include <hpx/modules/type_support.hpp>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,12 @@

#include <hpx/config.hpp>
#include <hpx/assert.hpp>
#include <hpx/distribution_policies/container_distribution_policy.hpp>
#include <hpx/distribution_policies/explicit_container_distribution_policy.hpp>
#include <hpx/modules/actions_base.hpp>
#include <hpx/modules/async_base.hpp>
#include <hpx/modules/async_combinators.hpp>
#include <hpx/modules/async_distributed.hpp>
#include <hpx/modules/components.hpp>
#include <hpx/modules/distribution_policies.hpp>
#include <hpx/modules/errors.hpp>
#include <hpx/modules/execution.hpp>
#include <hpx/modules/runtime_components.hpp>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@

#pragma once

#include <hpx/distribution_policies/container_distribution_policy.hpp>
#include <hpx/distribution_policies/explicit_container_distribution_policy.hpp>
#include <hpx/modules/distribution_policies.hpp>

#include <hpx/components/containers/partitioned_vector/export_definitions.hpp>
#include <hpx/components/containers/partitioned_vector/partitioned_vector_component_decl.hpp>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@
#include <hpx/config.hpp>

#if !defined(HPX_HAVE_STATIC_LINKING)
#include <hpx/distribution_policies/container_distribution_policy.hpp>
#include <hpx/distribution_policies/explicit_container_distribution_policy.hpp>
#include <hpx/modules/distribution_policies.hpp>

#include <hpx/components/containers/partitioned_vector/export_definitions.hpp>
#include <hpx/components/containers/partitioned_vector/partitioned_vector.hpp>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@
#include <hpx/config.hpp>

#if !defined(HPX_HAVE_STATIC_LINKING)
#include <hpx/distribution_policies/container_distribution_policy.hpp>
#include <hpx/distribution_policies/explicit_container_distribution_policy.hpp>
#include <hpx/modules/distribution_policies.hpp>

#include <hpx/components/containers/partitioned_vector/export_definitions.hpp>
#include <hpx/components/containers/partitioned_vector/partitioned_vector.hpp>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@
#include <hpx/config.hpp>

#if !defined(HPX_HAVE_STATIC_LINKING)
#include <hpx/distribution_policies/container_distribution_policy.hpp>
#include <hpx/distribution_policies/explicit_container_distribution_policy.hpp>
#include <hpx/modules/distribution_policies.hpp>

#include <hpx/components/containers/partitioned_vector/export_definitions.hpp>
#include <hpx/components/containers/partitioned_vector/partitioned_vector.hpp>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@

#include <hpx/config.hpp>
#include <hpx/assert.hpp>
#include <hpx/distribution_policies/container_distribution_policy.hpp>
#include <hpx/modules/actions_base.hpp>
#include <hpx/modules/async_combinators.hpp>
#include <hpx/modules/components.hpp>
#include <hpx/modules/components_base.hpp>
#include <hpx/modules/distribution_policies.hpp>
#include <hpx/modules/functional.hpp>
#include <hpx/modules/runtime_components.hpp>
#include <hpx/modules/serialization.hpp>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,10 @@
#if defined(HPX_HAVE_NETWORKING) && defined(HPX_HAVE_PARCEL_COALESCING)
#include <hpx/modules/functional.hpp>
#include <hpx/modules/hashing.hpp>
#include <hpx/modules/performance_counters.hpp>
#include <hpx/modules/synchronization.hpp>
#include <hpx/modules/type_support.hpp>

#include <hpx/performance_counters/counters_fwd.hpp>

#include <cstdint>
#include <string>
#include <unordered_map>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
#if defined(HPX_HAVE_NETWORKING) && defined(HPX_HAVE_PARCEL_COALESCING)
#include <hpx/modules/errors.hpp>
#include <hpx/modules/util.hpp>
#include <hpx/modules/performance_counters.hpp>

#include <hpx/parcel_coalescing/counter_registry.hpp>
#include <hpx/performance_counters/registry.hpp>

#include <cstdint>
#include <mutex>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,9 @@
#include <hpx/modules/string_util.hpp>

#include <hpx/modules/components_base.hpp>
#include <hpx/modules/performance_counters.hpp>

#include <hpx/parcel_coalescing/counter_registry.hpp>
#include <hpx/performance_counters/counter_creators.hpp>
#include <hpx/performance_counters/counters.hpp>
#include <hpx/performance_counters/manage_counter_type.hpp>

#include <cstdint>
#include <exception>
Expand Down
4 changes: 2 additions & 2 deletions components/performance_counters/io/src/io_counters.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,15 @@

#include <hpx/config.hpp>
#include <hpx/modules/components_base.hpp>
#include <hpx/modules/errors.hpp>
#include <hpx/modules/format.hpp>
#include <hpx/modules/functional.hpp>
#include <hpx/modules/performance_counters.hpp>
#include <hpx/modules/runtime_configuration.hpp>
#include <hpx/modules/runtime_local.hpp>
#include <hpx/performance_counters/manage_counter_type.hpp>

#include <hpx/components/performance_counters/io/io_counters.hpp>

#include <hpx/modules/errors.hpp>
#include <boost/fusion/include/define_struct.hpp>
#include <boost/fusion/include/io.hpp>
#include <boost/phoenix/core.hpp>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
#include <hpx/config.hpp>
#include <hpx/modules/components_base.hpp>
#include <hpx/modules/functional.hpp>
#include <hpx/modules/performance_counters.hpp>
#include <hpx/modules/runtime_configuration.hpp>
#include <hpx/modules/runtime_local.hpp>
#include <hpx/performance_counters/manage_counter_type.hpp>

#include <hpx/components/performance_counters/memory_counters/mem_counter.hpp>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
#if defined(HPX_HAVE_PAPI)

#include <hpx/modules/components_base.hpp>
#include <hpx/modules/performance_counters.hpp>
#include <hpx/modules/runtime_local.hpp>
#include <hpx/performance_counters/server/base_performance_counter.hpp>

#include <cstdint>
#include <map>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
#include <hpx/modules/errors.hpp>
#include <hpx/modules/format.hpp>
#include <hpx/modules/iterator_support.hpp>
#include <hpx/modules/performance_counters.hpp>
#include <hpx/modules/program_options.hpp>
#include <hpx/performance_counters/counters.hpp>

#include <cstdint>
#include <cstring>
Expand Down
15 changes: 7 additions & 8 deletions components/performance_counters/papi/src/papi_startup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,17 @@
#include <hpx/config.hpp>

#if defined(HPX_HAVE_PAPI)

#include <hpx/components/performance_counters/papi/server/papi.hpp>
#include <hpx/components/performance_counters/papi/util/papi.hpp>
#include <hpx/modules/components_base.hpp>
#include <hpx/modules/errors.hpp>
#include <hpx/modules/functional.hpp>
#include <hpx/modules/iterator_support.hpp>
#include <hpx/modules/performance_counters.hpp>
#include <hpx/modules/program_options.hpp>
#include <hpx/modules/runtime_configuration.hpp>
#include <hpx/modules/runtime_local.hpp>
#include <hpx/performance_counters/counter_creators.hpp>
#include <hpx/performance_counters/manage_counter_type.hpp>

#include <hpx/components/performance_counters/papi/server/papi.hpp>
#include <hpx/components/performance_counters/papi/util/papi.hpp>

#include <cctype>
#include <cstdint>
Expand Down Expand Up @@ -289,11 +288,11 @@ namespace hpx { namespace performance_counters { namespace papi {
using namespace hpx::performance_counters;

// define & install generic PAPI counter type
generic_counter_type_data const papi_cnt_type = {"/papi",
constexpr generic_counter_type_data papi_cnt_type = {"/papi",
counter_type::raw,
"the current count of occurrences of a specific PAPI event",
HPX_PERFORMANCE_COUNTER_V1, &create_papi_counter,
&discover_papi_counters, ""};
performance_counters::HPX_PERFORMANCE_COUNTER_V1,
&create_papi_counter, &discover_papi_counters, ""};
install_counter_types(&papi_cnt_type, 1);

// deferred options
Expand Down
2 changes: 1 addition & 1 deletion components/performance_counters/power/src/power.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
#include <hpx/config.hpp>
#include <hpx/modules/components_base.hpp>
#include <hpx/modules/functional.hpp>
#include <hpx/modules/performance_counters.hpp>
#include <hpx/modules/runtime_configuration.hpp>
#include <hpx/modules/runtime_local.hpp>
#include <hpx/performance_counters/manage_counter_type.hpp>

#include <hpx/components/performance_counters/power/power_counter.hpp>

Expand Down
5 changes: 3 additions & 2 deletions examples/performance_counters/sine/sine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,8 @@ namespace performance_counters { namespace sine {
{"/sine/immediate/explicit", counter_type::raw,
"returns the current value of a sine wave calculated over "
"an arbitrary time line (explicit, hand-rolled version)",
HPX_PERFORMANCE_COUNTER_V1, &explicit_sine_counter_creator,
hpx::performance_counters::HPX_PERFORMANCE_COUNTER_V1,
&explicit_sine_counter_creator,
&explicit_sine_counter_discoverer, ""},
// We assume that valid counter names have the following scheme:
//
Expand All @@ -237,7 +238,7 @@ namespace performance_counters { namespace sine {
"returns the current value of a sine wave calculated over "
"an arbitrary time line (implicit version, using HPX "
"facilities)",
HPX_PERFORMANCE_COUNTER_V1,
hpx::performance_counters::HPX_PERFORMANCE_COUNTER_V1,
hpx::bind(
&hpx::performance_counters::locality_raw_counter_creator,
_1, &immediate_sine, _2),
Expand Down
3 changes: 2 additions & 1 deletion libs/full/actions/include/hpx/actions/macros.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@
#pragma once

#include <hpx/config.hpp>
#include <hpx/actions_base/macros.hpp>
#include <hpx/modules/preprocessor.hpp>

#include <hpx/actions_base/macros.hpp>

#include <type_traits>

#if defined(HPX_HAVE_NETWORKING)
Expand Down
1 change: 1 addition & 0 deletions libs/full/collectives/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ add_hpx_module(
hpx_components
hpx_components_base
hpx_naming_base
hpx_performance_counters
hpx_runtime_components
hpx_runtime_distributed
CMAKE_SUBDIRS examples tests
Expand Down
5 changes: 3 additions & 2 deletions libs/full/collectives/src/latch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,19 @@
// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)

#include <hpx/assert.hpp>
#include <hpx/collectives/latch.hpp>
#include <hpx/modules/actions.hpp>
#include <hpx/modules/actions_base.hpp>
#include <hpx/modules/async_distributed.hpp>
#include <hpx/modules/components.hpp>
#include <hpx/modules/futures.hpp>
#include <hpx/modules/performance_counters.hpp>
#include <hpx/modules/runtime_components.hpp>
#include <hpx/modules/runtime_local.hpp>
#include <hpx/modules/type_support.hpp>
#include <hpx/performance_counters/counters.hpp>
#include <hpx/runtime_distributed/find_here.hpp>

#include <hpx/collectives/latch.hpp>

#include <cstddef>
#include <exception>
#include <utility>
Expand Down
7 changes: 5 additions & 2 deletions libs/full/distribution_policies/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) 2019-2021 The STE||AR-Group
# Copyright (c) 2019-2026 The STE||AR-Group
#
# SPDX-License-Identifier: BSL-1.0
# Distributed under the Boost Software License, Version 1.0. (See accompanying
Expand Down Expand Up @@ -31,12 +31,15 @@ set(distribution_policies_compat_headers
)
# cmake-format: on

set(distribution_policies_sources binpacking_distribution_policy.cpp)
set(distribution_policies_sources binpacking_distribution_policy.cpp
distribution_policies.cpp
)

include(HPX_AddModule)
add_hpx_module(
full distribution_policies
GLOBAL_HEADER_GEN ON
GLOBAL_HEADER_MODULE_GEN ON
SOURCES ${distribution_policies_sources}
HEADERS ${distribution_policies_headers}
COMPAT_HEADERS ${distribution_policies_compat_headers}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) 2007-2023 Hartmut Kaiser
// Copyright (c) 2007-2026 Hartmut Kaiser
//
// SPDX-License-Identifier: BSL-1.0
// Distributed under the Boost Software License, Version 1.0. (See accompanying
Expand All @@ -17,9 +17,9 @@
#include <hpx/modules/futures.hpp>
#include <hpx/modules/naming_base.hpp>
#include <hpx/modules/pack_traversal.hpp>
#include <hpx/modules/performance_counters.hpp>
#include <hpx/modules/runtime_components.hpp>
#include <hpx/modules/serialization.hpp>
#include <hpx/performance_counters/performance_counter.hpp>

#include <algorithm>
#include <cstddef>
Expand All @@ -32,8 +32,9 @@

namespace hpx::components {

inline constexpr char const* const default_binpacking_counter_name =
"/runtime{locality/total}/count/component@";
HPX_CXX_EXPORT inline constexpr char const* const
default_binpacking_counter_name =
"/runtime{locality/total}/count/component@";

namespace detail {

Expand Down Expand Up @@ -150,7 +151,7 @@ namespace hpx::components {
/// each of the localities will equalize the number of overall objects of
/// this type based on a given criteria (by default this criteria is the
/// overall number of objects of this type).
struct binpacking_distribution_policy
HPX_CXX_EXPORT struct binpacking_distribution_policy
{
public:
/// Default-construct a new instance of a \a binpacking_distribution_policy.
Expand Down Expand Up @@ -372,14 +373,15 @@ namespace hpx::components {

/// A predefined instance of the binpacking \a distribution_policy. It will
/// represent the local locality and will place all items to create here.
static binpacking_distribution_policy const binpacked{};
HPX_CXX_EXPORT HPX_EXPORT extern binpacking_distribution_policy const
binpacked;
} // namespace hpx::components

/// \cond NOINTERNAL
namespace hpx {

using hpx::components::binpacked;
using hpx::components::binpacking_distribution_policy;
HPX_CXX_EXPORT using hpx::components::binpacked;
HPX_CXX_EXPORT using hpx::components::binpacking_distribution_policy;

template <>
struct traits::is_distribution_policy<
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) 2014-2024 Hartmut Kaiser
// Copyright (c) 2014-2026 Hartmut Kaiser
//
// SPDX-License-Identifier: BSL-1.0
// Distributed under the Boost Software License, Version 1.0. (See accompanying
Expand Down Expand Up @@ -31,7 +31,7 @@ namespace hpx::components {
/// This class specifies the parameters for a distribution policy to use
/// for creating a given number of items on the locality where a given
/// object is currently placed.
struct colocating_distribution_policy
HPX_CXX_EXPORT struct colocating_distribution_policy
{
/// Default-construct a new instance of a \a colocating_distribution_policy.
/// This policy will represent the local locality.
Expand Down Expand Up @@ -364,14 +364,15 @@ namespace hpx::components {
/// A predefined instance of the co-locating \a distribution_policy. It
/// will represent the local locality and will place all items to create
/// here.
static colocating_distribution_policy const colocated{};
HPX_CXX_EXPORT HPX_EXPORT extern colocating_distribution_policy const
colocated;
} // namespace hpx::components

/// \cond NOINTERNAL
namespace hpx {

using hpx::components::colocated;
using hpx::components::colocating_distribution_policy;
HPX_CXX_EXPORT using hpx::components::colocated;
HPX_CXX_EXPORT using hpx::components::colocating_distribution_policy;

template <>
struct traits::is_distribution_policy<
Expand Down
Loading
Loading