Skip to content

per process output from --osh-time sorted function is mixed together on stdout #92

@cwsmith

Description

@cwsmith

Running with more than one rank and --osh-time produces TOP FUNCTIONS output from each rank that gets mixed together on stdout making the results hard to read.

It appears that building with -DOmega_h_DBG=on may resolve this as the TASK_0_cout macro gets defined:

# define TASK_0_cout if(DBG_COMM && (0 == DBG_COMM->rank())) std::cout

But, for collecting performance data, specifically with a run using GPUs, enabling that build option may not work, and, if it does, it may increase runtime. This needs to be tested.

for (auto i : sorted_result) {
auto cflags( std::cout.flags() );
double val = i.second[TOP_AVE];
if (val*100.0/total_runtime_ave >= h.chop) {
TASK_0_cout << std::right
<< std::setw(width) << val*scale << percent
<< std::setw(width) << i.second[TOP_MIN]*scale << percent
<< std::setw(width) << i.second[TOP_MAX]*scale << percent
<< std::setw(width) << i.second[TOP_MAX]/i.second[TOP_MIN] << " ";
std::cout.flags(cflags);
TASK_0_cout << i.first << std::endl;
}
std::cout.flags(coutflags);
}
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueGood for newcomershelp wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions