A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use (const) references with range-based for loops.
[simgrid.git]
/
src
/
instr
/
instr_paje_trace.cpp
diff --git
a/src/instr/instr_paje_trace.cpp
b/src/instr/instr_paje_trace.cpp
index
c7c4f7c
..
6e9df55
100644
(file)
--- a/
src/instr/instr_paje_trace.cpp
+++ b/
src/instr/instr_paje_trace.cpp
@@
-68,14
+68,14
@@
void TRACE_paje_dump_buffer (int force)
return;
XBT_DEBUG("%s: dump until %f. starts", __FUNCTION__, TRACE_last_timestamp_to_dump);
if (force){
return;
XBT_DEBUG("%s: dump until %f. starts", __FUNCTION__, TRACE_last_timestamp_to_dump);
if (force){
- for (auto
event : buffer)
{
+ for (auto
const& event : buffer)
{
event->print();
delete event;
}
buffer.clear();
}else{
std::vector<PajeEvent*>::iterator i = buffer.begin();
event->print();
delete event;
}
buffer.clear();
}else{
std::vector<PajeEvent*>::iterator i = buffer.begin();
- for (auto
event :buffer)
{
+ for (auto
const& event : buffer)
{
double head_timestamp = event->timestamp;
if (head_timestamp > TRACE_last_timestamp_to_dump)
break;
double head_timestamp = event->timestamp;
if (head_timestamp > TRACE_last_timestamp_to_dump)
break;
@@
-92,7
+92,7
@@
void buffer_debug(std::vector<PajeEvent*> *buf);
void buffer_debug(std::vector<PajeEvent*> *buf) {
return;
XBT_DEBUG(">>>>>> Dump the state of the buffer. %zu events", buf->size());
void buffer_debug(std::vector<PajeEvent*> *buf) {
return;
XBT_DEBUG(">>>>>> Dump the state of the buffer. %zu events", buf->size());
- for (auto
event :*buf)
{
+ for (auto
const& event : *buf)
{
event->print();
XBT_DEBUG("%p %s", event, stream.str().c_str());
stream.str("");
event->print();
XBT_DEBUG("%p %s", event, stream.str().c_str());
stream.str("");
@@
-667,11
+667,13
@@
void PushStateEvent::print() {
fprintf(trace_file, "%d ", extra->recvcounts[i]);
fprintf(trace_file, "%d %s %s\n", extra->root, extra->datatype1, extra->datatype2);
break;
fprintf(trace_file, "%d ", extra->recvcounts[i]);
fprintf(trace_file, "%d %s %s\n", extra->root, extra->datatype1, extra->datatype2);
break;
+ case TRACING_ALLGATHER: // rank allgather sendcount recvcounts (sendtype) (recvtype)
+ fprintf(trace_file, "%s allGather %d %d %s %s", process_id, extra->send_size, extra->recv_size, extra->datatype1, extra->datatype2);
+ break;
case TRACING_WAITANY:
case TRACING_SENDRECV:
case TRACING_SCATTER:
case TRACING_SCATTERV:
case TRACING_WAITANY:
case TRACING_SENDRECV:
case TRACING_SCATTER:
case TRACING_SCATTERV:
- case TRACING_ALLGATHER:
case TRACING_SCAN:
case TRACING_EXSCAN:
case TRACING_COMM_SIZE:
case TRACING_SCAN:
case TRACING_EXSCAN:
case TRACING_COMM_SIZE: