From 745fb8183e07a44df591c03c9c3cc43af6c4e8dc Mon Sep 17 00:00:00 2001 From: Jakub Strzebonski Date: Fri, 16 Oct 2020 20:08:07 +0200 Subject: [PATCH] #872: add encoding member bits in handler field --- src/vt/handler/handler.cc | 21 ++- src/vt/handler/handler.h | 19 +- src/vt/pipe/callback/cb_union/cb_raw.h | 4 +- src/vt/pipe/callback/cb_union/cb_raw_base.cc | 7 +- src/vt/pipe/callback/cb_union/cb_raw_base.h | 6 +- .../proxy_bcast/callback_proxy_bcast.h | 7 +- .../proxy_bcast/callback_proxy_bcast.impl.h | 3 +- .../proxy_bcast/callback_proxy_bcast_tl.h | 9 +- .../callback_proxy_bcast_tl.impl.h | 3 +- .../callback/proxy_send/callback_proxy_send.h | 11 +- .../proxy_send/callback_proxy_send.impl.h | 5 +- src/vt/pipe/pipe_manager_tl.impl.h | 16 +- .../auto_registry_collection.impl.h | 10 +- src/vt/runnable/collection.h | 1 - src/vt/runnable/collection.impl.h | 8 +- src/vt/vrt/collection/dispatch/dispatch.h | 16 +- .../vrt/collection/dispatch/dispatch.impl.h | 20 +-- src/vt/vrt/collection/manager.h | 65 +++---- src/vt/vrt/collection/manager.impl.h | 170 ++++++++---------- src/vt/vrt/collection/messages/user.h | 4 - src/vt/vrt/collection/messages/user.impl.h | 11 -- .../test_collection_group.extended.cc | 8 +- 22 files changed, 184 insertions(+), 240 deletions(-) diff --git a/src/vt/handler/handler.cc b/src/vt/handler/handler.cc index d9e3db83fd..93698da9e9 100644 --- a/src/vt/handler/handler.cc +++ b/src/vt/handler/handler.cc @@ -48,13 +48,14 @@ namespace vt { /*static*/ HandlerType HandlerManager::makeHandler( - bool is_auto, bool is_functor, HandlerIdentifierType id, bool is_objgroup, - HandlerControlType control, bool is_trace + bool is_auto, bool is_functor, HandlerIdentifierType id, bool is_member, + bool is_objgroup, HandlerControlType control, bool is_trace ) { HandlerType new_han = blank_handler; HandlerManager::setHandlerAuto(new_han, is_auto); HandlerManager::setHandlerObjGroup(new_han, is_objgroup); HandlerManager::setHandlerFunctor(new_han, is_functor); + HandlerManager::setHandlerMember(new_han, is_member); HandlerManager::setHandlerIdentifier(new_han, id); #if vt_check_enabled(trace_enabled) @@ -68,8 +69,9 @@ namespace vt { vt_debug_print( handler, node, "HandlerManager::makeHandler: is_functor={}, is_auto={}, is_objgroup={}," - " id={:x}, control={:x}, han={:x}, is_trace={}\n", - is_functor, is_auto, is_objgroup, id, control, new_han, is_trace + "is_memer={} id={:x}, control={:x}, han={:x}, is_trace={}\n", + is_functor, is_auto, is_objgroup, is_member, id, control, new_han, + is_trace ); return new_han; @@ -123,6 +125,12 @@ namespace vt { BitPackerType::boolSetField(han, is_functor); } +/*static*/ void HandlerManager::setHandlerMember( + HandlerType& han, bool is_member +) { + BitPackerType::boolSetField(han, is_member); +} + /*static*/ bool HandlerManager::isHandlerAuto(HandlerType han) { return BitPackerType::boolGetField(han); } @@ -135,6 +143,10 @@ namespace vt { return BitPackerType::boolGetField(han); } +/*static*/ bool HandlerManager::isHandlerMember(HandlerType han) { + return BitPackerType::boolGetField(han); +} + #if vt_check_enabled(trace_enabled) /*static*/ bool HandlerManager::isHandlerTrace(HandlerType han) { return BitPackerType::boolGetField(han); @@ -148,4 +160,3 @@ namespace vt { #endif } // end namespace vt - diff --git a/src/vt/handler/handler.h b/src/vt/handler/handler.h index 89a5e29cb0..0d70a6fa1c 100644 --- a/src/vt/handler/handler.h +++ b/src/vt/handler/handler.h @@ -70,6 +70,7 @@ static constexpr BitCountType const functor_num_bits = 1; static constexpr BitCountType const objgroup_num_bits = 1; static constexpr BitCountType const trace_num_bits = 1; static constexpr BitCountType const control_num_bits = 20; +static constexpr BitCountType const member_num_bits = 1; static constexpr BitCountType const handler_id_num_bits = BitCounterType::value - ( auto_num_bits @@ -77,17 +78,19 @@ static constexpr BitCountType const handler_id_num_bits = + objgroup_num_bits + control_num_bits + trace_num_bits + + member_num_bits ); // eHandlerBits::ObjGroup identifies the handler as targeting an objgroup; the // control bits are an extensible field used for module-specific sub-handlers enum eHandlerBits { ObjGroup = 0, - Auto = eHandlerBits::ObjGroup + objgroup_num_bits, - Functor = eHandlerBits::Auto + auto_num_bits, - Trace = eHandlerBits::Functor + functor_num_bits, - Control = eHandlerBits::Trace + trace_num_bits, - Identifier = eHandlerBits::Control + control_num_bits + Auto = eHandlerBits::ObjGroup + objgroup_num_bits, + Functor = eHandlerBits::Auto + auto_num_bits, + Trace = eHandlerBits::Functor + functor_num_bits, + Control = eHandlerBits::Trace + trace_num_bits, + Member = eHandlerBits::Control + control_num_bits, + Identifier = eHandlerBits::Member + member_num_bits, }; struct HandlerManager { @@ -97,8 +100,8 @@ struct HandlerManager { static HandlerType makeHandler( bool is_auto, bool is_functor, HandlerIdentifierType id, - bool is_objgroup = false, HandlerControlType control = 0, - bool is_trace = true + bool is_member = false, bool is_objgroup = false, + HandlerControlType control = 0, bool is_trace = true ); static void setHandlerIdentifier(HandlerType& han, HandlerIdentifierType id); static void setHandlerControl(HandlerType& han, HandlerControlType control); @@ -108,9 +111,11 @@ struct HandlerManager { static void setHandlerAuto(HandlerType& han, bool is_auto); static void setHandlerFunctor(HandlerType& han, bool is_functor); static void setHandlerObjGroup(HandlerType& han, bool is_objgroup); + static void setHandlerMember(HandlerType& han, bool is_member); static bool isHandlerAuto(HandlerType han); static bool isHandlerFunctor(HandlerType han); static bool isHandlerObjGroup(HandlerType han); + static bool isHandlerMember(HandlerType han); #if vt_check_enabled(trace_enabled) static void setHandlerTrace(HandlerType& han, bool is_trace); static bool isHandlerTrace(HandlerType han); diff --git a/src/vt/pipe/callback/cb_union/cb_raw.h b/src/vt/pipe/callback/cb_union/cb_raw.h index 0aea3cd7c9..ec1d8957d8 100644 --- a/src/vt/pipe/callback/cb_union/cb_raw.h +++ b/src/vt/pipe/callback/cb_union/cb_raw.h @@ -91,8 +91,8 @@ struct BcastColDirCB : CallbackProxyBcastDirect { BcastColDirCB( HandlerType const& in_handler, CallbackProxyBcastDirect::AutoHandlerType const& in_vrt_handler, - bool const& in_member, VirtualProxyType const& in_proxy - ) : CallbackProxyBcastDirect(in_handler, in_vrt_handler, in_member, in_proxy) + VirtualProxyType const& in_proxy + ) : CallbackProxyBcastDirect(in_handler, in_vrt_handler, in_proxy) { } }; diff --git a/src/vt/pipe/callback/cb_union/cb_raw_base.cc b/src/vt/pipe/callback/cb_union/cb_raw_base.cc index 557b68491e..c58a2bfd64 100644 --- a/src/vt/pipe/callback/cb_union/cb_raw_base.cc +++ b/src/vt/pipe/callback/cb_union/cb_raw_base.cc @@ -76,10 +76,9 @@ CallbackRawBaseSingle::CallbackRawBaseSingle( { } CallbackRawBaseSingle::CallbackRawBaseSingle( - RawBcastColDirTagType, PipeType const& in_pipe, - HandlerType const& in_handler, AutoHandlerType const& in_vrt, - bool const& in_member, VirtualProxyType const& in_proxy -) : pipe_(in_pipe), cb_(BcastColDirCB{in_handler,in_vrt,in_member,in_proxy}) + RawBcastColDirTagType, PipeType const& in_pipe, HandlerType const& in_handler, + AutoHandlerType const& in_vrt, VirtualProxyType const& in_proxy +) : pipe_(in_pipe), cb_(BcastColDirCB{in_handler, in_vrt, in_proxy}) { } CallbackRawBaseSingle::CallbackRawBaseSingle( diff --git a/src/vt/pipe/callback/cb_union/cb_raw_base.h b/src/vt/pipe/callback/cb_union/cb_raw_base.h index b6b19916fa..ae2f3f4db9 100644 --- a/src/vt/pipe/callback/cb_union/cb_raw_base.h +++ b/src/vt/pipe/callback/cb_union/cb_raw_base.h @@ -98,7 +98,7 @@ struct CallbackRawBaseSingle { CallbackRawBaseSingle( RawBcastColDirTagType, PipeType const& in_pipe, HandlerType const& in_handler, AutoHandlerType const& in_vrt, - bool const& in_member, VirtualProxyType const& in_proxy + VirtualProxyType const& in_proxy ); CallbackRawBaseSingle( RawSendColDirTagType, PipeType const& in_pipe, @@ -182,9 +182,9 @@ struct CallbackTyped : CallbackRawBaseSingle { CallbackTyped( RawBcastColDirTagType, PipeType const& in_pipe, HandlerType const& in_handler, AutoHandlerType const& in_vrt, - bool const& in_member, VirtualProxyType const& in_proxy + VirtualProxyType const& in_proxy ) : CallbackRawBaseSingle( - RawBcastColDirTag,in_pipe,in_handler,in_vrt,in_member,in_proxy + RawBcastColDirTag, in_pipe, in_handler, in_vrt, in_proxy ) { } CallbackTyped( diff --git a/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast.h b/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast.h index 1d878ffab7..316f35836b 100644 --- a/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast.h +++ b/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast.h @@ -68,10 +68,8 @@ struct CallbackProxyBcast : CallbackBase> { CallbackProxyBcast(CallbackProxyBcast const&) = default; CallbackProxyBcast(CallbackProxyBcast&&) = default; - CallbackProxyBcast( - HandlerType const& in_handler, ProxyType const& in_proxy, - bool const& in_member - ) : proxy_(in_proxy), handler_(in_handler), member_(in_member) + CallbackProxyBcast(HandlerType const& in_handler, ProxyType const& in_proxy) + : proxy_(in_proxy), handler_(in_handler) { } template @@ -83,7 +81,6 @@ struct CallbackProxyBcast : CallbackBase> { private: ProxyType proxy_ = {}; HandlerType handler_ = uninitialized_handler; - bool member_ = false; }; }}} /* end namespace vt::pipe::callback */ diff --git a/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast.impl.h b/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast.impl.h index 0c7c7858d8..cbada71d10 100644 --- a/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast.impl.h +++ b/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast.impl.h @@ -58,12 +58,11 @@ void CallbackProxyBcast::serialize(SerializerT& s) { CallbackBase::serializer(s); s | proxy_; s | handler_; - s | member_; } template void CallbackProxyBcast::trigger_(SignalDataType* data) { - theCollection()->broadcastMsgWithHan(proxy_,data,handler_,member_,true); + theCollection()->broadcastMsgWithHan(proxy_, data, handler_, true); } }}} /* end namespace vt::pipe::callback */ diff --git a/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast_tl.h b/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast_tl.h index 77988b2466..a591da0f1e 100644 --- a/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast_tl.h +++ b/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast_tl.h @@ -77,9 +77,8 @@ struct CallbackProxyBcastDirect : CallbackBaseTL { CallbackProxyBcastDirect() = default; CallbackProxyBcastDirect( HandlerType const& in_han, AutoHandlerType const& in_vrt, - bool const& in_member, VirtualProxyType const& in_proxy - ) : vrt_dispatch_han_(in_vrt), handler_(in_han), proxy_(in_proxy), - member_(in_member) + VirtualProxyType const& in_proxy + ) : vrt_dispatch_han_(in_vrt), handler_(in_han), proxy_(in_proxy) { } template @@ -89,8 +88,7 @@ struct CallbackProxyBcastDirect : CallbackBaseTL { return other.handler_ == handler_ && other.vrt_dispatch_han_ == vrt_dispatch_han_ && - other.proxy_ == proxy_ && - other.member_ == member_; + other.proxy_ == proxy_; } public: @@ -105,7 +103,6 @@ struct CallbackProxyBcastDirect : CallbackBaseTL { AutoHandlerType vrt_dispatch_han_ = uninitialized_handler; HandlerType handler_ = uninitialized_handler; VirtualProxyType proxy_ = no_vrt_proxy; - bool member_ = false; }; }}} /* end namespace vt::pipe::callback */ diff --git a/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast_tl.impl.h b/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast_tl.impl.h index 5665d41446..d893e7c163 100644 --- a/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast_tl.impl.h +++ b/src/vt/pipe/callback/proxy_bcast/callback_proxy_bcast_tl.impl.h @@ -92,7 +92,6 @@ template void CallbackProxyBcastDirect::serialize(SerializerT& s) { s | handler_; s | vrt_dispatch_han_; - s | member_; s | proxy_; } @@ -108,7 +107,7 @@ void CallbackProxyBcastDirect::trigger(MsgT* msg, PipeType const& pipe) { auto dispatcher = vrt::collection::getDispatcher(vrt_dispatch_han_); auto const& proxy = proxy_; - dispatcher->broadcast(proxy,msg,handler_,member_); + dispatcher->broadcast(proxy, msg, handler_); } }}} /* end namespace vt::pipe::callback */ diff --git a/src/vt/pipe/callback/proxy_send/callback_proxy_send.h b/src/vt/pipe/callback/proxy_send/callback_proxy_send.h index 0d10d22231..cdee8e2dd9 100644 --- a/src/vt/pipe/callback/proxy_send/callback_proxy_send.h +++ b/src/vt/pipe/callback/proxy_send/callback_proxy_send.h @@ -68,17 +68,15 @@ struct CallbackProxySend : CallbackBase> { using MessageType = MsgT; CallbackProxySend( - HandlerType const& in_handler, IndexedProxyType const& in_proxy, - bool const& in_member + HandlerType const& in_handler, IndexedProxyType const& in_proxy ) : proxy_(in_proxy.getCollectionProxy()), - idx_(in_proxy.getElementProxy().getIndex()), - handler_(in_handler), member_(in_member) + idx_(in_proxy.getElementProxy().getIndex()), handler_(in_handler) { } CallbackProxySend( HandlerType const& in_handler, ProxyType const& in_proxy, - IndexType const& in_idx, bool const& in_member - ) : proxy_(in_proxy), idx_(in_idx), handler_(in_handler), member_(in_member) + IndexType const& in_idx + ) : proxy_(in_proxy), idx_(in_idx), handler_(in_handler) { } template @@ -91,7 +89,6 @@ struct CallbackProxySend : CallbackBase> { ProxyType proxy_ = {}; IndexType idx_ = {}; HandlerType handler_ = uninitialized_handler; - bool member_ = false; }; }}} /* end namespace vt::pipe::callback */ diff --git a/src/vt/pipe/callback/proxy_send/callback_proxy_send.impl.h b/src/vt/pipe/callback/proxy_send/callback_proxy_send.impl.h index 97d43adc89..490689316e 100644 --- a/src/vt/pipe/callback/proxy_send/callback_proxy_send.impl.h +++ b/src/vt/pipe/callback/proxy_send/callback_proxy_send.impl.h @@ -58,12 +58,11 @@ void CallbackProxySend::serialize(SerializerT& s) { CallbackBase::serializer(s); s | proxy_ | idx_; s | handler_; - s | member_; } template -void CallbackProxySend::trigger_(SignalDataType* data) { - theCollection()->sendMsgWithHan(proxy_.index(idx_),data,handler_,member_); +void CallbackProxySend::trigger_(SignalDataType* data) { + theCollection()->sendMsgWithHan(proxy_.index(idx_), data, handler_); } }}} /* end namespace vt::pipe::callback */ diff --git a/src/vt/pipe/pipe_manager_tl.impl.h b/src/vt/pipe/pipe_manager_tl.impl.h index a39fe37eb9..189dd99bbc 100644 --- a/src/vt/pipe/pipe_manager_tl.impl.h +++ b/src/vt/pipe/pipe_manager_tl.impl.h @@ -149,12 +149,9 @@ PipeManagerTL::makeCallbackSingleProxySend(typename ColT::ProxyType proxy) { newPipeState(pipe_id,persist,dispatch,-1,-1,0); auto cb = CallbackT(callback::cbunion::RawSendColMsgTag,pipe_id); auto const& handler = auto_registry::makeAutoHandlerCollection(); - bool member = false; addListenerAny( cb.getPipe(), - std::make_unique>( - handler,proxy,member - ) + std::make_unique>(handler, proxy) ); return cb; } @@ -173,12 +170,9 @@ PipeManagerTL::makeCallbackSingleProxySend(typename ColT::ProxyType proxy) { auto cb = CallbackT(callback::cbunion::RawSendColMsgTag,pipe_id); auto const& handler = auto_registry::makeAutoHandlerCollectionMem(); - bool member = true; addListenerAny( cb.getPipe(), - std::make_unique>( - handler,proxy,member - ) + std::make_unique>(handler, proxy) ); return cb; } @@ -253,9 +247,8 @@ PipeManagerTL::makeCallbackSingleProxyBcastDirect(ColProxyType proxy) { auto const& pipe_id = makePipeID(persist,send_back); auto const& handler = auto_registry::makeAutoHandlerCollection(); auto const& vrt_handler = vrt::collection::makeVrtDispatch(); - bool const member = false; auto cb = CallbackT( - callback::cbunion::RawBcastColDirTag,pipe_id,handler,vrt_handler,member, + callback::cbunion::RawBcastColDirTag, pipe_id, handler, vrt_handler, proxy.getProxy() ); return cb; @@ -273,9 +266,8 @@ PipeManagerTL::makeCallbackSingleProxyBcastDirect(ColProxyType proxy) { auto const& handler = auto_registry::makeAutoHandlerCollectionMem(); auto const& vrt_handler = vrt::collection::makeVrtDispatch(); - bool const member = true; auto cb = CallbackT( - callback::cbunion::RawBcastColDirTag,pipe_id,handler,vrt_handler,member, + callback::cbunion::RawBcastColDirTag, pipe_id, handler, vrt_handler, proxy.getProxy() ); return cb; diff --git a/src/vt/registry/auto/collection/auto_registry_collection.impl.h b/src/vt/registry/auto/collection/auto_registry_collection.impl.h index 3f9ad43cfe..6e26ea285e 100644 --- a/src/vt/registry/auto/collection/auto_registry_collection.impl.h +++ b/src/vt/registry/auto/collection/auto_registry_collection.impl.h @@ -63,7 +63,10 @@ inline HandlerType makeAutoHandlerCollection() { using ContainerType = AutoActiveCollectionContainerType; using RegInfoType = AutoRegInfoType; using FuncType = ActiveColFnPtrType; - return RunnableGen::idx; + + auto han = RunnableGen::idx; + HandlerManager::setHandlerMember(han, false); + return han; } inline AutoActiveCollectionMemType getAutoHandlerCollectionMem( @@ -81,7 +84,10 @@ inline HandlerType makeAutoHandlerCollectionMem() { using ContainerType = AutoActiveCollectionMemContainerType; using RegInfoType = AutoRegInfoType; using FuncType = ActiveColMemberFnPtrType; - return RunnableGen::idx; + + auto han = RunnableGen::idx; + HandlerManager::setHandlerMember(han, true); + return han; } template * f> diff --git a/src/vt/runnable/collection.h b/src/vt/runnable/collection.h index 79fb98e72e..28197526d0 100644 --- a/src/vt/runnable/collection.h +++ b/src/vt/runnable/collection.h @@ -53,7 +53,6 @@ template struct RunnableCollection { static void run( HandlerType handler, MsgT* msg, ElementT* elm, NodeType from_node, - bool member, uint64_t idx1 = 0, uint64_t idx2 = 0, uint64_t idx3 = 0, uint64_t idx4 = 0, trace::TraceEventIDType in_trace_event = trace::no_trace_event ); diff --git a/src/vt/runnable/collection.impl.h b/src/vt/runnable/collection.impl.h index 8aa09999a2..63d83e0e3d 100644 --- a/src/vt/runnable/collection.impl.h +++ b/src/vt/runnable/collection.impl.h @@ -58,11 +58,13 @@ namespace vt { namespace runnable { template -/*static*/ void RunnableCollection::run( - HandlerType handler, MsgT* msg, ElementT* elm, NodeType from, - bool member, uint64_t idx1, uint64_t idx2, uint64_t idx3, uint64_t idx4, +/*static*/ void RunnableCollection::run( + HandlerType handler, MsgT* msg, ElementT* elm, NodeType from, uint64_t idx1, + uint64_t idx2, uint64_t idx3, uint64_t idx4, trace::TraceEventIDType in_trace_event ) { + auto const member = HandlerManager::isHandlerMember(handler); + #if vt_check_enabled(trace_enabled) trace::TraceProcessingTag processing_tag; { diff --git a/src/vt/vrt/collection/dispatch/dispatch.h b/src/vt/vrt/collection/dispatch/dispatch.h index f36f2aa3ca..3086bfaafe 100644 --- a/src/vt/vrt/collection/dispatch/dispatch.h +++ b/src/vt/vrt/collection/dispatch/dispatch.h @@ -61,12 +61,10 @@ struct DispatchCollectionBase { DispatchCollectionBase() = default; virtual ~DispatchCollectionBase() {} - virtual void broadcast( - VirtualProxyType proxy, void* msg, HandlerType han, bool member - ) = 0; - virtual void send( - VirtualProxyType proxy, void* idx, void* msg, HandlerType han, bool member - ) = 0; + virtual void + broadcast(VirtualProxyType proxy, void* msg, HandlerType han) = 0; + virtual void + send(VirtualProxyType proxy, void* idx, void* msg, HandlerType han) = 0; template VirtualProxyType getDefaultProxy() const; @@ -81,11 +79,9 @@ struct DispatchCollectionBase { template struct DispatchCollection final : DispatchCollectionBase { private: - void broadcast( - VirtualProxyType proxy, void* msg, HandlerType han, bool member - ) override; + void broadcast(VirtualProxyType proxy, void* msg, HandlerType han) override; void send( - VirtualProxyType proxy, void* idx, void* msg, HandlerType han, bool member + VirtualProxyType proxy, void* idx, void* msg, HandlerType han ) override; }; diff --git a/src/vt/vrt/collection/dispatch/dispatch.impl.h b/src/vt/vrt/collection/dispatch/dispatch.impl.h index d1924f0511..75cc746c1c 100644 --- a/src/vt/vrt/collection/dispatch/dispatch.impl.h +++ b/src/vt/vrt/collection/dispatch/dispatch.impl.h @@ -56,29 +56,27 @@ namespace vt { namespace vrt { namespace collection { template -void DispatchCollection::broadcast( - VirtualProxyType proxy, void* msg, HandlerType han, bool member +void DispatchCollection::broadcast( + VirtualProxyType proxy, void* msg, HandlerType han ) { using IdxT = typename ColT::IndexType; auto const msg_typed = reinterpret_cast(msg); - CollectionProxy typed_proxy{proxy}; - theCollection()->broadcastMsgWithHan( - typed_proxy,msg_typed,han,member,true + CollectionProxy typed_proxy{proxy}; + theCollection()->broadcastMsgWithHan( + typed_proxy, msg_typed, han, true ); } template -void DispatchCollection::send( - VirtualProxyType proxy, void* idx, void* msg, HandlerType han, bool member +void DispatchCollection::send( + VirtualProxyType proxy, void* idx, void* msg, HandlerType han ) { using IdxT = typename ColT::IndexType; auto const msg_typed = reinterpret_cast(msg); auto const idx_typed = reinterpret_cast(idx); auto const& idx_typed_ref = *idx_typed; - VrtElmProxy typed_proxy{proxy,idx_typed_ref}; - theCollection()->sendMsgWithHan( - typed_proxy,msg_typed,han,member - ); + VrtElmProxy typed_proxy{proxy, idx_typed_ref}; + theCollection()->sendMsgWithHan(typed_proxy, msg_typed, han); } template diff --git a/src/vt/vrt/collection/manager.h b/src/vt/vrt/collection/manager.h index ab03e799c8..df3cf4fa2d 100644 --- a/src/vt/vrt/collection/manager.h +++ b/src/vt/vrt/collection/manager.h @@ -540,7 +540,6 @@ struct CollectionManager * \param[in] proxy the collection proxy * \param[in] msg the message * \param[in] handler the handler to run - * \param[in] member whether it's a member handler (or active function) * \param[in] imm_context whether in an immediate context (running a * collection element handler vs. directly in the scheduler)--- if in a * handler, local delivery must be postponed @@ -553,9 +552,8 @@ struct CollectionManager typename IdxT = typename ColT::IndexType > messaging::PendingSend sendMsgUntypedHandler( - VirtualElmProxyType const& proxy, MsgT *msg, - HandlerType const& handler, bool const member, - bool imm_context = true + VirtualElmProxyType const& proxy, MsgT* msg, + HandlerType const& handler, bool imm_context = true ); /** @@ -568,12 +566,11 @@ struct CollectionManager * \param[in] proxy the collection proxy * \param[in] msg the message * \param[in] handler the handler to run - * \param[in] member whether it's a member handler (or active function) */ template IsNotColMsgType sendMsgWithHan( - VirtualElmProxyType const& proxy, MsgT *msg, - HandlerType const& handler, bool const member + VirtualElmProxyType const& proxy, MsgT* msg, + HandlerType const& handler ); /** @@ -585,12 +582,11 @@ struct CollectionManager * \param[in] proxy the collection proxy * \param[in] msg the message * \param[in] handler the handler to run - * \param[in] member whether it's a member handler (or active function) */ template IsColMsgType sendMsgWithHan( - VirtualElmProxyType const& proxy, MsgT *msg, - HandlerType const& handler, bool const member + VirtualElmProxyType const& proxy, MsgT* msg, + HandlerType const& handler ); /** @@ -600,14 +596,13 @@ struct CollectionManager * \param[in] proxy the collection proxy * \param[in] msg the message * \param[in] handler the handler to run - * \param[in] member whether it's a member handler (or active function) * * \return the pending send */ template messaging::PendingSend sendNormalMsg( - VirtualElmProxyType const& proxy, MsgT *msg, - HandlerType const& handler, bool const member + VirtualElmProxyType const& proxy, MsgT* msg, + HandlerType const& handler ); /** @@ -744,12 +739,11 @@ struct CollectionManager * \param[in] msg the message * \param[in] col pointer to collection element * \param[in] han the handler to invoke - * \param[in] member whether it's a member handler * \param[in] from node that sent the message */ template - static IsWrapType collectionMsgDeliver( - MsgT* msg, CollectionBase* col, HandlerType han, bool member, + static IsWrapType collectionMsgDeliver( + MsgT* msg, CollectionBase* col, HandlerType han, NodeType from ); @@ -760,12 +754,11 @@ struct CollectionManager * \param[in] msg the message * \param[in] col pointer to collection element * \param[in] han the handler to invoke - * \param[in] member whether it's a member handler * \param[in] from node that sent the message */ template - static IsNotWrapType collectionMsgDeliver( - MsgT* msg, CollectionBase* col, HandlerType han, bool member, + static IsNotWrapType collectionMsgDeliver( + MsgT* msg, CollectionBase* col, HandlerType han, NodeType from ); @@ -882,15 +875,13 @@ struct CollectionManager * \param[in] proxy the collection proxy * \param[in] msg the message * \param[in] handler the handler to invoke - * \param[in] member whether it's a member handler * \param[in] instrument whether to instrument the broadcast for load * balancing (some system calls use this to disable instrumentation) */ template IsNotColMsgType broadcastMsgWithHan( - CollectionProxyWrapType const& proxy, MsgT *msg, - HandlerType const& handler, bool const member, - bool instrument = true + CollectionProxyWrapType const& proxy, MsgT* msg, + HandlerType const& handler, bool instrument = true ); /** @@ -899,15 +890,13 @@ struct CollectionManager * \param[in] proxy the collection proxy * \param[in] msg the message * \param[in] handler the handler to invoke - * \param[in] member whether it's a member handler * \param[in] instrument whether to instrument the broadcast for load * balancing (some system calls use this to disable instrumentation) */ template IsColMsgType broadcastMsgWithHan( - CollectionProxyWrapType const& proxy, MsgT *msg, - HandlerType const& handler, bool const member, - bool instrument = true + CollectionProxyWrapType const& proxy, MsgT* msg, + HandlerType const& handler, bool instrument = true ); /** @@ -916,7 +905,6 @@ struct CollectionManager * \param[in] proxy the collection proxy * \param[in] msg the message * \param[in] handler the handler to invoke - * \param[in] member whether it's a member handler * \param[in] instrument whether to instrument the broadcast for load * balancing (some system calls use this to disable instrumentation) * @@ -924,9 +912,8 @@ struct CollectionManager */ template messaging::PendingSend broadcastNormalMsg( - CollectionProxyWrapType const& proxy, MsgT *msg, - HandlerType const& handler, bool const member, - bool instrument = true + CollectionProxyWrapType const& proxy, MsgT* msg, + HandlerType const& handler, bool instrument = true ); /** @@ -935,7 +922,6 @@ struct CollectionManager * \param[in] proxy the collection proxy * \param[in] msg the message * \param[in] handler the handler to invoke - * \param[in] member whether it's a member handler * \param[in] instrument whether to instrument the broadcast for load * balancing (some system calls use this to disable instrumentation) * @@ -943,9 +929,8 @@ struct CollectionManager */ template messaging::PendingSend broadcastMsgUntypedHandler( - CollectionProxyWrapType const& proxy, MsgT *msg, - HandlerType const& handler, bool const member, - bool instrument + CollectionProxyWrapType const& proxy, MsgT* msg, + HandlerType const& handler, bool instrument ); /** @@ -1233,13 +1218,12 @@ struct CollectionManager * \param[in] msg the message * \param[in] col the collection element pointer * \param[in] han the handler to invoke - * \param[in] member whether it's a member handler * \param[in] from the node that sent it * \param[in] event the associated trace event */ template - static IsWrapType collectionAutoMsgDeliver( - MsgT* msg, CollectionBase* col, HandlerType han, bool member, + static IsWrapType collectionAutoMsgDeliver( + MsgT* msg, CollectionBase* col, HandlerType han, NodeType from, trace::TraceEventIDType event ); @@ -1250,13 +1234,12 @@ struct CollectionManager * \param[in] msg the message * \param[in] col the collection element pointer * \param[in] han the handler to invoke - * \param[in] member whether it's a member handler * \param[in] from the node that sent it * \param[in] event the associated trace event */ template - static IsNotWrapType collectionAutoMsgDeliver( - MsgT* msg, CollectionBase* col, HandlerType han, bool member, + static IsNotWrapType collectionAutoMsgDeliver( + MsgT* msg, CollectionBase* col, HandlerType han, NodeType from, trace::TraceEventIDType event ); diff --git a/src/vt/vrt/collection/manager.impl.h b/src/vt/vrt/collection/manager.impl.h index cb66f597a5..aabe016dc2 100644 --- a/src/vt/vrt/collection/manager.impl.h +++ b/src/vt/vrt/collection/manager.impl.h @@ -349,10 +349,10 @@ GroupType CollectionManager::createGroupCollection( } template -/*static*/ CollectionManager::IsWrapType +/*static*/ CollectionManager::IsWrapType CollectionManager::collectionAutoMsgDeliver( - MsgT* msg, CollectionBase* base, HandlerType han, bool member, - NodeType from, trace::TraceEventIDType event + MsgT* msg, CollectionBase* base, HandlerType han, NodeType from, + trace::TraceEventIDType event ) { using IdxContextHolder = InsertContextHolder; @@ -378,7 +378,7 @@ CollectionManager::collectionAutoMsgDeliver( IdxContextHolder::set(&idx,proxy); runnable::RunnableCollection::run( - han, user_msg_ptr, ptr, from, member, idx1, idx2, idx3, idx4 + han, user_msg_ptr, ptr, from, idx1, idx2, idx3, idx4 ); // Clear the current index context @@ -386,10 +386,10 @@ CollectionManager::collectionAutoMsgDeliver( } template -/*static*/ CollectionManager::IsNotWrapType +/*static*/ CollectionManager::IsNotWrapType CollectionManager::collectionAutoMsgDeliver( - MsgT* msg, CollectionBase* base, HandlerType han, bool member, - NodeType from, trace::TraceEventIDType event + MsgT* msg, CollectionBase* base, HandlerType han, NodeType from, + trace::TraceEventIDType event ) { using IdxContextHolder = InsertContextHolder; @@ -413,7 +413,7 @@ CollectionManager::collectionAutoMsgDeliver( IdxContextHolder::set(&idx,proxy); runnable::RunnableCollection::run( - han, msg, ptr, from, member, idx1, idx2, idx3, idx4, event + han, msg, ptr, from, idx1, idx2, idx3, idx4, event ); // Clear the current index context @@ -439,12 +439,11 @@ template auto elm_holder = theCollection()->findElmHolder(bcast_proxy); if (elm_holder) { auto const handler = col_msg->getVrtHandler(); - auto const member = col_msg->getMember(); vt_debug_print( vrt_coll, node, "broadcast apply: size={}\n", elm_holder->numElements() ); - elm_holder->foreach([col_msg,msg,handler,member]( + elm_holder->foreach([col_msg, msg, handler]( IndexT const& idx, CollectionBase* base ) { vt_debug_print( @@ -501,7 +500,7 @@ template trace_event = col_msg->getFromTraceEvent(); #endif collectionAutoMsgDeliver( - msg,base,handler,member,from,trace_event + msg, base, handler, from, trace_event ); #if vt_check_enabled(lblite) @@ -667,7 +666,6 @@ template auto& inner_holder = elm_holder->lookup(idx); auto const sub_handler = col_msg->getVrtHandler(); - auto const member = col_msg->getMember(); auto const col_ptr = inner_holder.getCollection(); vt_debug_print( @@ -677,7 +675,7 @@ template vtAssertInfo( col_ptr != nullptr, "Must be valid pointer", - sub_handler, member, cur_epoch, idx, exists + sub_handler, HandlerManager::isHandlerMember(sub_handler), cur_epoch, idx, exists ); @@ -728,7 +726,7 @@ template trace_event = col_msg->getFromTraceEvent(); #endif collectionAutoMsgDeliver( - msg,col_ptr,sub_handler,member,from,trace_event + msg, col_ptr, sub_handler, from, trace_event ); theMsg()->popEpoch(cur_epoch); @@ -860,7 +858,6 @@ messaging::PendingSend CollectionManager::broadcastCollectiveMsg( auto& msgPtr = msg.msg_; msgPtr->setVrtHandler(auto_registry::makeAutoHandlerCollection()); - msgPtr->setMember(false); return broadcastCollectiveMsgImpl(proxy, msgPtr, instrument); } @@ -879,7 +876,6 @@ messaging::PendingSend CollectionManager::broadcastCollectiveMsg( msgPtr->setVrtHandler( auto_registry::makeAutoHandlerCollectionMem() ); - msgPtr->setMember(true); return broadcastCollectiveMsgImpl(proxy, msgPtr, instrument); } @@ -896,12 +892,13 @@ messaging::PendingSend CollectionManager::broadcastCollectiveMsgImpl( #if vt_check_enabled(trace_enabled) // Create the trace creation event for the broadcast here to connect it a // higher semantic level - auto reg_type = msg->getMember() ? + auto const han = msg->getVrtHandler(); + auto reg_type = HandlerManager::isHandlerMember(han) ? auto_registry::RegistryTypeEnum::RegVrtCollectionMember : auto_registry::RegistryTypeEnum::RegVrtCollection; auto msg_size = vt::serialization::MsgSizer::get(msg.get()); auto event = theMsg()->makeTraceCreationSend( - msg, msg->getVrtHandler(), reg_type, msg_size, true + msg, han, reg_type, msg_size, true ); msg->setFromTraceEvent(event); #endif @@ -994,62 +991,57 @@ CollectionManager::broadcastMsg( } template < - typename MsgT, - typename ColT, - ActiveColMemberTypedFnType f + typename MsgT, typename ColT, ActiveColMemberTypedFnType f > messaging::PendingSend CollectionManager::broadcastMsgImpl( - CollectionProxyWrapType const& proxy, MsgT *const msg, bool inst + CollectionProxyWrapType const& proxy, MsgT* const msg, bool inst ) { // register the user's handler - auto const& h = auto_registry::makeAutoHandlerCollectionMem(); - return broadcastMsgUntypedHandler(proxy,msg,h,true,inst); + auto const& h = auto_registry::makeAutoHandlerCollectionMem(); + return broadcastMsgUntypedHandler(proxy, msg, h, inst); } -template *f> +template * f> messaging::PendingSend CollectionManager::broadcastMsgImpl( - CollectionProxyWrapType const& proxy, MsgT *const msg, bool inst + CollectionProxyWrapType const& proxy, MsgT* const msg, bool inst ) { // register the user's handler - auto const& h = auto_registry::makeAutoHandlerCollection(); - return broadcastMsgUntypedHandler(proxy,msg,h,false,inst); + auto const& h = auto_registry::makeAutoHandlerCollection(); + return broadcastMsgUntypedHandler(proxy, msg, h, inst); } template -CollectionManager::IsColMsgType -CollectionManager::broadcastMsgWithHan( - CollectionProxyWrapType const& proxy, MsgT *msg, - HandlerType const& h, bool const mem, bool inst +CollectionManager::IsColMsgType CollectionManager::broadcastMsgWithHan( + CollectionProxyWrapType const& proxy, MsgT* msg, HandlerType const& h, + bool inst ) { using IdxT = typename ColT::IndexType; - return broadcastMsgUntypedHandler(proxy,msg,h,mem,inst); + return broadcastMsgUntypedHandler(proxy, msg, h, inst); } template -CollectionManager::IsNotColMsgType -CollectionManager::broadcastMsgWithHan( - CollectionProxyWrapType const& proxy, MsgT *msg, - HandlerType const& h, bool const mem, bool inst +CollectionManager::IsNotColMsgType CollectionManager::broadcastMsgWithHan( + CollectionProxyWrapType const& proxy, MsgT* msg, HandlerType const& h, + bool inst ) { - return broadcastNormalMsg(proxy,msg,h,mem,inst); + return broadcastNormalMsg(proxy, msg, h, inst); } template messaging::PendingSend CollectionManager::broadcastNormalMsg( - CollectionProxyWrapType const& proxy, MsgT *msg, - HandlerType const& handler, bool const member, - bool instrument + CollectionProxyWrapType const& proxy, MsgT* msg, + HandlerType const& handler, bool instrument ) { - auto wrap_msg = makeMessage>(*msg); - return broadcastMsgUntypedHandler,ColT>( - proxy, wrap_msg.get(), handler, member, instrument + auto wrap_msg = makeMessage>(*msg); + return broadcastMsgUntypedHandler, ColT>( + proxy, wrap_msg.get(), handler, instrument ); } template messaging::PendingSend CollectionManager::broadcastMsgUntypedHandler( - CollectionProxyWrapType const& toProxy, MsgT *raw_msg, - HandlerType const& handler, bool const member, bool instrument + CollectionProxyWrapType const& toProxy, MsgT* raw_msg, + HandlerType const& handler, bool instrument ) { auto const idx = makeVrtDispatch(); auto const col_proxy = toProxy.getProxy(); @@ -1065,12 +1057,11 @@ messaging::PendingSend CollectionManager::broadcastMsgUntypedHandler( msg->setFromNode(theContext()->getNode()); msg->setVrtHandler(handler); msg->setBcastProxy(col_proxy); - msg->setMember(member); # if vt_check_enabled(trace_enabled) // Create the trace creation event for the broadcast here to connect it a // higher semantic level - auto reg_type = member ? + auto reg_type = HandlerManager::isHandlerMember(handler) ? auto_registry::RegistryTypeEnum::RegVrtCollectionMember : auto_registry::RegistryTypeEnum::RegVrtCollection; auto msg_size = vt::serialization::MsgSizer::get(msg.get()); @@ -1273,32 +1264,30 @@ messaging::PendingSend CollectionManager::reduceMsgExpr( } template -CollectionManager::IsNotColMsgType -CollectionManager::sendMsgWithHan( - VirtualElmProxyType const& proxy, MsgT *msg, - HandlerType const& handler, bool const member +CollectionManager::IsNotColMsgType CollectionManager::sendMsgWithHan( + VirtualElmProxyType const& proxy, MsgT* msg, + HandlerType const& handler ) { - return sendNormalMsg(proxy,msg,handler,member); + return sendNormalMsg(proxy, msg, handler); } template -CollectionManager::IsColMsgType -CollectionManager::sendMsgWithHan( - VirtualElmProxyType const& proxy, MsgT *msg, - HandlerType const& handler, bool const member +CollectionManager::IsColMsgType CollectionManager::sendMsgWithHan( + VirtualElmProxyType const& proxy, MsgT* msg, + HandlerType const& handler ) { using IdxT = typename ColT::IndexType; - return sendMsgUntypedHandler(proxy,msg,handler,member); + return sendMsgUntypedHandler(proxy, msg, handler); } template messaging::PendingSend CollectionManager::sendNormalMsg( - VirtualElmProxyType const& proxy, MsgT *msg, - HandlerType const& handler, bool const member + VirtualElmProxyType const& proxy, MsgT* msg, + HandlerType const& handler ) { - auto wrap_msg = makeMessage>(*msg); - return sendMsgUntypedHandler,ColT>( - proxy, wrap_msg.get(), handler, member + auto wrap_msg = makeMessage>(*msg); + return sendMsgUntypedHandler, ColT>( + proxy, wrap_msg.get(), handler ); } @@ -1331,13 +1320,11 @@ CollectionManager::sendMsg( return sendMsgImpl(proxy,msg); } -template *f> +template * f> CollectionManager::IsNotColMsgType -CollectionManager::sendMsg( - VirtualElmProxyType const& proxy, MsgT *msg -) { - auto const& h = auto_registry::makeAutoHandlerCollection(); - return sendNormalMsg(proxy,msg,h,false); +CollectionManager::sendMsg(VirtualElmProxyType const& proxy, MsgT* msg) { + auto const& h = auto_registry::makeAutoHandlerCollection(); + return sendNormalMsg(proxy, msg, h); } template < @@ -1353,43 +1340,37 @@ CollectionManager::sendMsg( } template < - typename MsgT, - typename ColT, - ActiveColMemberTypedFnType f + typename MsgT, typename ColT, ActiveColMemberTypedFnType f > CollectionManager::IsNotColMsgType -CollectionManager::sendMsg( - VirtualElmProxyType const& proxy, MsgT *msg -) { - auto const& h = auto_registry::makeAutoHandlerCollectionMem(); - return sendNormalMsg(proxy,msg,h,true); +CollectionManager::sendMsg(VirtualElmProxyType const& proxy, MsgT* msg) { + auto const& h = auto_registry::makeAutoHandlerCollectionMem(); + return sendNormalMsg(proxy, msg, h); } -template *f> +template * f> messaging::PendingSend CollectionManager::sendMsgImpl( - VirtualElmProxyType const& proxy, MsgT *msg + VirtualElmProxyType const& proxy, MsgT* msg ) { - auto const& h = auto_registry::makeAutoHandlerCollection(); - return sendMsgUntypedHandler(proxy,msg,h,false); + auto const& h = auto_registry::makeAutoHandlerCollection(); + return sendMsgUntypedHandler(proxy, msg, h); } template < - typename MsgT, - typename ColT, - ActiveColMemberTypedFnType f + typename MsgT, typename ColT, + ActiveColMemberTypedFnType f > messaging::PendingSend CollectionManager::sendMsgImpl( - VirtualElmProxyType const& proxy, MsgT *msg + VirtualElmProxyType const& proxy, MsgT* msg ) { - auto const& h = auto_registry::makeAutoHandlerCollectionMem(); - return sendMsgUntypedHandler(proxy,msg,h,true); + auto const& h = auto_registry::makeAutoHandlerCollectionMem(); + return sendMsgUntypedHandler(proxy, msg, h); } template messaging::PendingSend CollectionManager::sendMsgUntypedHandler( - VirtualElmProxyType const& toProxy, MsgT *raw_msg, - HandlerType const& handler, bool const member, - bool imm_context + VirtualElmProxyType const& toProxy, MsgT* raw_msg, + HandlerType const& handler, bool imm_context ) { auto const& col_proxy = toProxy.getCollectionProxy(); auto const& elm_proxy = toProxy.getElementProxy(); @@ -1421,7 +1402,7 @@ messaging::PendingSend CollectionManager::sendMsgUntypedHandler( // level. Do it in the imm_context so we see the send event when the user // actually invokes send on the proxy (not outside the event that actually // sent it) - auto reg_type = member ? + auto reg_type = HandlerManager::isHandlerMember(handler) ? auto_registry::RegistryTypeEnum::RegVrtCollectionMember : auto_registry::RegistryTypeEnum::RegVrtCollection; auto msg_size = vt::serialization::MsgSizer::get(msg.get()); @@ -1435,7 +1416,6 @@ messaging::PendingSend CollectionManager::sendMsgUntypedHandler( msg->setFromNode(theContext()->getNode()); msg->setVrtHandler(handler); msg->setProxy(toProxy); - msg->setMember(member); auto idx = elm_proxy.getIndex(); vt_debug_print( @@ -2920,7 +2900,7 @@ void CollectionManager::elmReadyLB( auto pmsg = promoteMsg(msg); #if !vt_check_enabled(lblite) - theCollection()->sendMsgUntypedHandler(proxy, pmsg.get(), lb_han,true); + theCollection()->sendMsgUntypedHandler(proxy, pmsg.get(), lb_han); return; #endif @@ -2941,8 +2921,8 @@ void CollectionManager::elmReadyLB( ); theTerm()->produce(cur_epoch); - elm_holder->addLBCont(idx,[pmsg,proxy,lb_han,cur_epoch]{ - theCollection()->sendMsgUntypedHandler(proxy,pmsg.get(),lb_han,true); + elm_holder->addLBCont(idx, [pmsg, proxy, lb_han, cur_epoch] { + theCollection()->sendMsgUntypedHandler(proxy, pmsg.get(), lb_han); theTerm()->consume(cur_epoch); }); diff --git a/src/vt/vrt/collection/messages/user.h b/src/vt/vrt/collection/messages/user.h index d459735cc7..27553d6682 100644 --- a/src/vt/vrt/collection/messages/user.h +++ b/src/vt/vrt/collection/messages/user.h @@ -104,9 +104,6 @@ struct CollectionMessage : RoutedMessageType { NodeType getFromNode() const; void setFromNode(NodeType const& node); - bool getMember() const; - void setMember(bool const& member); - bool getWrap() const; void setWrap(bool const& wrap); @@ -136,7 +133,6 @@ struct CollectionMessage : RoutedMessageType { HandlerType vt_sub_handler_ = uninitialized_handler; EpochType bcast_epoch_ = no_epoch; NodeType from_node_ = uninitialized_destination; - bool member_ = false; bool is_wrap_ = false; #if vt_check_enabled(lblite) diff --git a/src/vt/vrt/collection/messages/user.impl.h b/src/vt/vrt/collection/messages/user.impl.h index 6f4c3eaa7e..31a8401e07 100644 --- a/src/vt/vrt/collection/messages/user.impl.h +++ b/src/vt/vrt/collection/messages/user.impl.h @@ -120,7 +120,6 @@ void CollectionMessage::serialize(SerializerT& s) { s | to_proxy_; s | bcast_proxy_; s | bcast_epoch_; - s | member_; s | is_wrap_; #if vt_check_enabled(lblite) @@ -135,16 +134,6 @@ void CollectionMessage::serialize(SerializerT& s) { #endif } -template -bool CollectionMessage::getMember() const { - return member_; -} - -template -void CollectionMessage::setMember(bool const& member) { - member_ = member; -} - template bool CollectionMessage::getWrap() const { return is_wrap_; diff --git a/tests/unit/collection/test_collection_group.extended.cc b/tests/unit/collection/test_collection_group.extended.cc index d03b6b5d9c..ce64d3aac8 100644 --- a/tests/unit/collection/test_collection_group.extended.cc +++ b/tests/unit/collection/test_collection_group.extended.cc @@ -85,7 +85,7 @@ struct ColA : Collection { reduce_test = true; } - void memberHanlder(TestDataMsg* msg) { + void memberHandler(TestDataMsg* msg) { EXPECT_EQ(msg->value_, theContext()->getNode()); --elem_counter; handler_executed = true; @@ -146,7 +146,7 @@ TEST_F(TestCollectionGroup, test_collection_group_2) { // raw msg pointer case runBcastTestHelper([proxy, my_node]{ auto msg = ::vt::makeMessage(my_node); - proxy.broadcastCollectiveMsg( + proxy.broadcastCollectiveMsg( msg.get() ); }); @@ -156,7 +156,7 @@ TEST_F(TestCollectionGroup, test_collection_group_2) { // smart msg pointer case runBcastTestHelper([proxy, my_node]{ auto msg = ::vt::makeMessage(my_node); - proxy.broadcastCollectiveMsg(msg); + proxy.broadcastCollectiveMsg(msg); }); EXPECT_EQ(elem_counter, -numElems); @@ -164,7 +164,7 @@ TEST_F(TestCollectionGroup, test_collection_group_2) { // msg constructed on the fly case runBcastTestHelper([proxy, my_node] { proxy.broadcastCollective< - ColA::TestDataMsg, &ColA::memberHanlder, ColA::TestDataMsg>(my_node); + ColA::TestDataMsg, &ColA::memberHandler, ColA::TestDataMsg>(my_node); }); EXPECT_EQ(elem_counter, -2 * numElems);