Skip to content

Commit e3478c7

Browse files
committed
Handle inline data in broadcast
Signed-off-by: Joseph Schuchart <joseph.schuchart@stonybrook.edu>
1 parent 25cce08 commit e3478c7

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

ttg/ttg/parsec/ttg.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2155,6 +2155,7 @@ namespace ttg_parsec {
21552155
const std::set<ttg::device::Device>& deviceset,
21562156
ReleaseFn&& release) {
21572157
int32_t num_iovecs = msg->tt_id.num_iovecs;
2158+
bool inline_data = msg->tt_id.inline_data;
21582159
uint64_t pos = 0;
21592160
//bool inline_data = msg->inline_data;
21602161
detail::ttg_data_copy_t *copy;
@@ -2175,7 +2176,7 @@ namespace ttg_parsec {
21752176
pos = unpack(*static_cast<ValueT *>(copy->get_ptr()), msg->bytes, pos);
21762177
}
21772178

2178-
if (num_iovecs == 0) {
2179+
if (num_iovecs == 0 && !inline_data) {
21792180
release(copy);
21802181
//set_arg_from_msg_keylist<i, ValueT>(ttg::span<keyT>(&keylist[0], num_keys), copy);
21812182
} else {
@@ -2308,7 +2309,7 @@ namespace ttg_parsec {
23082309
}
23092310
}
23102311

2311-
assert(num_iovecs == nv);
2312+
assert(inline_data || num_iovecs == nv);
23122313

23132314
if (inline_data) {
23142315
release(copy);
@@ -3291,8 +3292,6 @@ namespace ttg_parsec {
32913292
auto local_begin = keylist_sorted.end();
32923293
auto local_end = keylist_sorted.end();
32933294

3294-
int32_t num_iovs = 0;
3295-
32963295
detail::ttg_data_copy_t *copy;
32973296
copy = detail::find_copy_in_task(detail::parsec_ttg_caller, &value);
32983297
assert(nullptr != copy);
@@ -3310,6 +3309,7 @@ namespace ttg_parsec {
33103309
std::vector<std::pair<int32_t, std::shared_ptr<void>>> memregs;
33113310
memregs = register_bcast_data(value, inline_data, msg, pos);
33123311

3312+
int32_t num_iovs = memregs.size();
33133313
msg->tt_id.num_iovecs = num_iovs;
33143314

33153315
std::size_t save_pos = pos;

0 commit comments

Comments
 (0)