Skip to content

Commit

Permalink
#1009: memory footprinting: do not use countBytes when | operator is …
Browse files Browse the repository at this point in the history
…available
  • Loading branch information
cz4rs committed Nov 24, 2020
1 parent 5faf0bd commit f424afb
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 19 deletions.
5 changes: 2 additions & 3 deletions src/vt/topos/location/cache/cache.h
Original file line number Diff line number Diff line change
Expand Up @@ -78,9 +78,8 @@ struct LocationCache {
template <typename Serializer>
void serialize(Serializer& s) {
s | cache_
| max_size_;

s.countBytes(lookup_);
| max_size_
| lookup_;
}

private:
Expand Down
8 changes: 4 additions & 4 deletions src/vt/trace/trace_log.h
Original file line number Diff line number Diff line change
Expand Up @@ -189,10 +189,10 @@ struct Log final {
reset();
}

template <typename Serializer>
void serialize(Serializer& s) {
s.countBytes(*this);
}
template <typename Serializer>
void serialize(Serializer& s) {
s.countBytes(*this);
}

private:

Expand Down
5 changes: 2 additions & 3 deletions src/vt/utils/container/concurrent_deque_locked.h
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,8 @@ struct ConcurrentDequeLocked {
template <typename Serializer>
void serialize(Serializer& s) {
s | needs_lock_
| container_;

s.countBytes(container_mutex_);
| container_
| container_mutex_;
}

private:
Expand Down
5 changes: 2 additions & 3 deletions src/vt/utils/container/process_ready_buffer.h
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,8 @@ struct ProcessBuffer {
s | buffer_
| needs_lock_
| worker_
| process_fn_;

s.countBytes(mutex_);
| process_fn_
| mutex_;
}

private:
Expand Down
5 changes: 2 additions & 3 deletions src/vt/worker/worker_group.h
Original file line number Diff line number Diff line change
Expand Up @@ -100,9 +100,8 @@ struct WorkerGroupAny
void serialize(SerializerT& s) {
s | finished_fn_
| initialized_
| num_workers_;

s.countBytes(workers_);
| num_workers_
| workers_;
}

private:
Expand Down
5 changes: 2 additions & 3 deletions src/vt/worker/worker_group_omp.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,8 @@ struct WorkerGroupOMP
| ready_
| initialized_
| num_workers_
| worker_state_;

s.countBytes(enqueue_worker_mutex_);
| worker_state_
| enqueue_worker_mutex_;
}

private:
Expand Down

0 comments on commit f424afb

Please sign in to comment.