@@ -82,13 +82,13 @@ auto kamping::Communicator<DefaultContainerType, Plugins...>::iallreduce(Args...
82
82
);
83
83
84
84
// Get the send buffer and deduce the send and recv value types.
85
- auto && send_buf = select_parameter_type<ParameterType::send_buf>(args...).construct_buffer_or_rebind ();
85
+ auto send_buf = select_parameter_type<ParameterType::send_buf>(args...).construct_buffer_or_rebind ();
86
86
using send_value_type = typename std::remove_reference_t <decltype (send_buf)>::value_type;
87
87
using default_recv_value_type = std::remove_const_t <send_value_type>;
88
88
89
89
// Deduce the recv buffer type and get (if provided) the recv buffer or allocate one (if not provided).
90
90
using default_recv_buf_type = decltype (kamping::recv_buf (alloc_new<DefaultContainerType<default_recv_value_type>>));
91
- auto && recv_buf =
91
+ auto recv_buf =
92
92
select_parameter_type_or_default<ParameterType::recv_buf, default_recv_buf_type>(std::tuple (), args...)
93
93
.template construct_buffer_or_rebind <DefaultContainerType>();
94
94
using recv_value_type = typename std::remove_reference_t <decltype (recv_buf)>::value_type;
@@ -98,7 +98,7 @@ auto kamping::Communicator<DefaultContainerType, Plugins...>::iallreduce(Args...
98
98
);
99
99
100
100
// Get the send_recv_type.
101
- auto && send_recv_type = determine_mpi_send_recv_datatype<send_value_type, decltype (recv_buf)>(args...);
101
+ auto send_recv_type = determine_mpi_send_recv_datatype<send_value_type, decltype (recv_buf)>(args...);
102
102
[[maybe_unused]] constexpr bool send_recv_type_is_in_param = !has_to_be_computed<decltype (send_recv_type)>;
103
103
104
104
// Get the operation used for the reduction. The signature of the provided function is checked while
@@ -114,10 +114,10 @@ auto kamping::Communicator<DefaultContainerType, Plugins...>::iallreduce(Args...
114
114
BufferResizePolicy::no_resize>(std::move (op));
115
115
}();
116
116
using default_send_recv_count_type = decltype (kamping::send_recv_count_out ());
117
- auto && send_recv_count = internal::select_parameter_type_or_default<
118
- internal::ParameterType::send_recv_count,
119
- default_send_recv_count_type>({}, args...)
120
- .construct_buffer_or_rebind ();
117
+ auto send_recv_count = internal::select_parameter_type_or_default<
118
+ internal::ParameterType::send_recv_count,
119
+ default_send_recv_count_type>({}, args...)
120
+ .construct_buffer_or_rebind ();
121
121
if constexpr (has_to_be_computed<decltype (send_recv_count)>) {
122
122
send_recv_count.underlying () = asserting_cast<int >(send_buf.size ());
123
123
}
0 commit comments