Skip to content

Commit

Permalink
#883 Test commit
Browse files Browse the repository at this point in the history
  • Loading branch information
JacobDomagala committed Jan 22, 2021
1 parent c8b5015 commit a518499
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 12 deletions.
4 changes: 0 additions & 4 deletions src/vt/messaging/active.cc
Original file line number Diff line number Diff line change
Expand Up @@ -386,10 +386,6 @@ EventType ActiveMessenger::sendMsgBytes(
);
}

vtWarnIf(
!(dest != theContext()->getNode() || is_bcast),
"Destination {} should != this node"
);
vtAbortIf(
dest >= theContext()->getNumNodes() || dest < 0, "Invalid destination: {}"
);
Expand Down
4 changes: 1 addition & 3 deletions tests/unit/active/test_active_bcast_put.cc
Original file line number Diff line number Diff line change
Expand Up @@ -131,9 +131,7 @@ TEST_P(TestActiveBroadcastPut, test_type_safe_active_fn_bcast2) {
}
});

if (my_node != root) {
ASSERT_TRUE(handler_count == num_msg_sent);
}
ASSERT_TRUE(handler_count == num_msg_sent);
}

// Spin here so test_vec does not go out of scope before the send completes
Expand Down
4 changes: 2 additions & 2 deletions tutorial/tutorial_1e.h
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ static inline void activeMessageGroupRoot() {
// list of nodes. The lambda is executed once the group is created. By
// setting the group in the envelope of the message and broadcasting the
// message will arrive on the set of nodes included in the group
auto id = theGroup()->newGroup(std::move(range), [](GroupType group_id){
fmt::print("Group is created: id={:x}\n", group_id);
auto id = theGroup()->newGroup(std::move(range), [this_node](GroupType group_id){
fmt::print("{}: Rooted Group is created: id={:x}\n", this_node, group_id);
auto msg = makeMessage<MySimpleMsg>();
envelopeSetGroup(msg->env, group_id);
theMsg()->broadcastMsg<MySimpleMsg,msgHandlerGroupA>(msg);
Expand Down
6 changes: 4 additions & 2 deletions tutorial/tutorial_1f.h
Original file line number Diff line number Diff line change
Expand Up @@ -74,11 +74,12 @@ static inline void activeMessageGroupCollective() {
* spanning tree based on the filter and rebalance it depending on outcomes.
*/

fmt::print("{}: activeMessageGroupCollective start\n", this_node);
auto const& is_even_node = this_node % 2 == 0;

auto group = theGroup()->newGroupCollective(
is_even_node, [](GroupType group_id){
fmt::print("Group is created: id={:x}\n", group_id);
is_even_node, [this_node](GroupType group_id){
fmt::print("{}: Colective Group is created: id={:x}\n", this_node, group_id);

// In this example, node 1 broadcasts to the group of even nodes
auto const my_node = ::vt::theContext()->getNode();
Expand All @@ -89,6 +90,7 @@ static inline void activeMessageGroupCollective() {
}
}
);
fmt::print("{}: activeMessageGroupCollective end\n", this_node);
(void)group; // don't warn about unused variable
}

Expand Down
4 changes: 4 additions & 0 deletions tutorial/tutorial_1h.h
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,8 @@ static inline void activeMessageReduce() {

NodeType const root_reduce_node = 0;

fmt::print("{}: activeMessageReduce start\n", this_node);

auto reduce_msg = ::vt::makeMessage<ReduceDataMsg>();

// Get a reference to the value to set it in this reduce msg
Expand All @@ -94,6 +96,8 @@ static inline void activeMessageReduce() {
default_proxy.reduceMsg<ReduceOp, ReduceResult>(
root_reduce_node, reduce_msg.get()
);

fmt::print("{}: activeMessageReduce end\n", this_node);
}
/// [Tutorial1H]

Expand Down
2 changes: 1 addition & 1 deletion tutorial/tutorial_main.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ int main(int argc, char** argv) {
activeMessageSerialization();

// Invoke tutorial 1d: active message broadcast
activeMessageBroadcast();
//activeMessageBroadcast();

// Invoke tutorial 1e: active message group rooted
activeMessageGroupRoot();
Expand Down

0 comments on commit a518499

Please sign in to comment.