MCPcopy Create free account
hub / github.com/AMReX-Codes/amrex / WriteHeader

Function WriteHeader

Src/Base/AMReX_BLProfiler.cpp:505–533  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

503namespace BLProfilerUtils {
504
505void WriteHeader(std::ostream &ios, const int colWidth,
506 const Real maxlen, const bool bwriteavg)
507{
508 int maxlenI = int(maxlen);
509
510 if(bwriteavg) {
511 ios << std::setfill('-') << std::setw(maxlenI+4 + 7 * (colWidth+2))
512 << std::left << "Total times " << '\n';
513 ios << std::right << std::setfill(' ');
514 ios << std::setw(maxlenI + 2) << "Function Name"
515 << std::setw(colWidth + 2) << "NCalls"
516 << std::setw(colWidth + 2) << "Min"
517 << std::setw(colWidth + 2) << "Avg"
518 << std::setw(colWidth + 2) << "Max"
519 << std::setw(colWidth + 2) << "StdDev"
520 << std::setw(colWidth + 2) << "CoeffVar"
521 << std::setw(colWidth + 4) << "Percent %"
522 << '\n';
523 } else {
524 ios << std::setfill('-') << std::setw(maxlenI+4 + 3 * (colWidth+2))
525 << std::left << "Total times " << '\n';
526 ios << std::right << std::setfill(' ');
527 ios << std::setw(maxlenI + 2) << "Function Name"
528 << std::setw(colWidth + 2) << "NCalls"
529 << std::setw(colWidth + 2) << "Time"
530 << std::setw(colWidth + 4) << "Percent %"
531 << '\n';
532 }
533}
534
535
536void WriteRow(std::ostream &ios, const std::string &fname,

Callers 3

WriteStatsFunction · 0.85
WriteMethod · 0.85
WriteOnlyHeaderMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected