1748 lines
48 KiB
Diff
1748 lines
48 KiB
Diff
--- src/libpcp_pmc/examples/fixed.c++
|
|
+++ src/libpcp_pmc/examples/fixed.c++
|
|
@@ -19,7 +19,7 @@
|
|
* Mountain View, CA 94043, USA, or: http://www.sgi.com
|
|
*/
|
|
|
|
-#include <iostream.h>
|
|
+#include <iostream>
|
|
#include "Group.h"
|
|
#include "Metric.h"
|
|
|
|
--- src/libpcp_pmc/examples/hotproc.c++
|
|
+++ src/libpcp_pmc/examples/hotproc.c++
|
|
@@ -19,7 +19,7 @@
|
|
* Mountain View, CA 94043, USA, or: http://www.sgi.com
|
|
*/
|
|
|
|
-#include <iostream.h>
|
|
+#include <iostream>
|
|
#include <stdlib.h>
|
|
#include <stdarg.h>
|
|
#include <unistd.h>
|
|
@@ -85,7 +85,7 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0)
|
|
- cerr << "interrupt detected - exiting..." << endl;
|
|
+ std::cerr << "interrupt detected - exiting..." << std::endl;
|
|
#endif
|
|
|
|
printf("\n");
|
|
@@ -432,8 +432,8 @@
|
|
if (name->error(c) < 0) {
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0)
|
|
- cerr << "Proc " << cpu->instName(c) << ": "
|
|
- << pmErrStr(cpu->error(c)) << endl;
|
|
+ std::cerr << "Proc " << cpu->instName(c) << ": "
|
|
+ << pmErrStr(cpu->error(c)) << std::endl;
|
|
#endif
|
|
continue;
|
|
}
|
|
@@ -483,9 +483,9 @@
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL2) {
|
|
fflush(stdout);
|
|
- cpu->dump(cerr);
|
|
- cerr << endl;
|
|
- cerr.flush();
|
|
+ cpu->dump(std::cerr);
|
|
+ std::cerr << std::endl;
|
|
+ std::cerr.flush();
|
|
}
|
|
#endif
|
|
|
|
@@ -498,8 +498,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0)
|
|
- cerr << "Indom has changed, had " << name->numInst()
|
|
- << " instances" << endl;
|
|
+ std::cerr << "Indom has changed, had " << name->numInst()
|
|
+ << " instances" << std::endl;
|
|
#endif
|
|
|
|
user->updateIndom();
|
|
@@ -515,17 +515,17 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0)
|
|
- cerr << "Indom updated, have " << name->numInst()
|
|
+ std::cerr << "Indom updated, have " << name->numInst()
|
|
<< " instances (nprocs = " << nprocs->value(0)
|
|
- << ')' << endl;
|
|
+ << ')' << std::endl;
|
|
#endif
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0) {
|
|
- cerr << "Indom updated and fetched, got "
|
|
- << nprocs->value(0) << " procs" << endl;
|
|
- name->dump(cerr);
|
|
- name->indom()->dump(cerr);
|
|
+ std::cerr << "Indom updated and fetched, got "
|
|
+ << nprocs->value(0) << " procs" << std::endl;
|
|
+ name->dump(std::cerr);
|
|
+ name->indom()->dump(std::cerr);
|
|
}
|
|
#endif
|
|
}
|
|
@@ -554,7 +554,7 @@
|
|
if (diff < 0.0) { // We missed an update
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0) {
|
|
- cerr << "Need to slip " << -diff << " seconds" << endl;
|
|
+ std::cerr << "Need to slip " << -diff << " seconds" << std::endl;
|
|
}
|
|
#endif
|
|
do {
|
|
@@ -566,7 +566,7 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL1) {
|
|
- cerr << "Napping for " << diff << " seconds" << endl;
|
|
+ std::cerr << "Napping for " << diff << " seconds" << std::endl;
|
|
}
|
|
#endif
|
|
|
|
--- src/libpcp_pmc/src/Context.c++
|
|
+++ src/libpcp_pmc/src/Context.c++
|
|
@@ -21,7 +21,7 @@
|
|
|
|
#ident "$Id: Context.c++,v 1.5 2005/05/10 01:59:58 kenmcd Exp $"
|
|
|
|
-#include <iostream.h>
|
|
+#include <iostream>
|
|
#include <limits.h>
|
|
#include "Context.h"
|
|
#include "Metric.h"
|
|
@@ -94,8 +94,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Context::lookupDesc: Matched \"" << name
|
|
- << "\" to id " << pmIDStr(id) << endl;
|
|
+ std::cerr << "PMC_Context::lookupDesc: Matched \"" << name
|
|
+ << "\" to id " << pmIDStr(id) << std::endl;
|
|
#endif
|
|
break;
|
|
}
|
|
@@ -155,8 +155,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC) {
|
|
- cerr << "PMC_Context::lookupDesc: Add descriptor for "
|
|
- << pmIDStr(descPtr->id()) << endl;
|
|
+ std::cerr << "PMC_Context::lookupDesc: Add descriptor for "
|
|
+ << pmIDStr(descPtr->id()) << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
@@ -166,8 +166,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC) {
|
|
- cerr << "PMC_Context::lookupDesc: Reusing descriptor "
|
|
- << pmIDStr(descPtr->id()) << endl;
|
|
+ std::cerr << "PMC_Context::lookupDesc: Reusing descriptor "
|
|
+ << pmIDStr(descPtr->id()) << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
@@ -192,8 +192,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC) {
|
|
- cerr << "PMC_Context::lookupDesc: Add indom for "
|
|
- << pmInDomStr(indomPtr->id()) << endl;
|
|
+ std::cerr << "PMC_Context::lookupDesc: Add indom for "
|
|
+ << pmInDomStr(indomPtr->id()) << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
@@ -204,8 +204,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC) {
|
|
- cerr << "PMC_Context::lookupDesc: Reusing indom "
|
|
- << pmInDomStr(indomPtr->id()) << endl;
|
|
+ std::cerr << "PMC_Context::lookupDesc: Reusing indom "
|
|
+ << pmInDomStr(indomPtr->id()) << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
@@ -214,8 +214,8 @@
|
|
return sts;
|
|
}
|
|
|
|
-ostream&
|
|
-operator<<(ostream &os, const PMC_Context &cntx)
|
|
+std::ostream&
|
|
+operator<<(std::ostream &os, const PMC_Context &cntx)
|
|
{
|
|
os << cntx.source().desc() << " has "
|
|
<< cntx._metrics.length() << " metrics";
|
|
@@ -231,20 +231,20 @@
|
|
}
|
|
|
|
void
|
|
-PMC_Context::dump(ostream& os)
|
|
+PMC_Context::dump(std::ostream& os)
|
|
{
|
|
os << "Context " << _context << " has " << _names.length()
|
|
- << " metric names for source:" << endl;
|
|
+ << " metric names for source:" << std::endl;
|
|
_source->dump(os);
|
|
}
|
|
|
|
void
|
|
-PMC_Context::dumpMetrics(ostream& os)
|
|
+PMC_Context::dumpMetrics(std::ostream& os)
|
|
{
|
|
uint_t i;
|
|
for (i = 0; i < _metrics.length(); i++)
|
|
os << " [" << i << "] "
|
|
- << _metrics[i]->spec(PMC_false, PMC_true) << endl;
|
|
+ << _metrics[i]->spec(PMC_false, PMC_true) << std::endl;
|
|
}
|
|
|
|
void
|
|
@@ -294,8 +294,8 @@
|
|
}
|
|
#ifdef PCP_DEBUG
|
|
else if (pmDebug & DBG_TRACE_OPTFETCH)
|
|
- cerr << "PMC_Context::fetch: Unable to switch to this context: "
|
|
- << pmErrStr(sts) << endl;
|
|
+ std::cerr << "PMC_Context::fetch: Unable to switch to this context: "
|
|
+ << pmErrStr(sts) << std::endl;
|
|
#endif
|
|
|
|
if (sts >= 0 && _needReconnect) {
|
|
@@ -307,15 +307,15 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC) {
|
|
- cerr << "PMC_Context::fetch: Reconnected context \""
|
|
- << *_source << endl;
|
|
+ std::cerr << "PMC_Context::fetch: Reconnected context \""
|
|
+ << *_source << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
#ifdef PCP_DEBUG
|
|
else if (pmDebug & DBG_TRACE_PMC) {
|
|
- cerr << "PMC_Context::fetch: Reconnect failed: "
|
|
- << pmErrStr(sts) << endl;
|
|
+ std::cerr << "PMC_Context::fetch: Reconnect failed: "
|
|
+ << pmErrStr(sts) << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
@@ -324,8 +324,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_OPTFETCH)
|
|
- cerr << "PMC_Context::fetch: fetching context " << *this
|
|
- << endl;
|
|
+ std::cerr << "PMC_Context::fetch: fetching context " << *this
|
|
+ << std::endl;
|
|
#endif
|
|
|
|
sts = pmFetch(_pmids.length(),
|
|
@@ -352,8 +352,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_OPTFETCH)
|
|
- cerr << "PMC_Context::fetch: pmFetch: " << pmErrStr(sts)
|
|
- << endl;
|
|
+ std::cerr << "PMC_Context::fetch: pmFetch: " << pmErrStr(sts)
|
|
+ << std::endl;
|
|
#endif
|
|
|
|
for (i = 0; i < _metrics.length(); i++) {
|
|
@@ -371,7 +371,7 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_OPTFETCH)
|
|
- cerr << "PMC_Context::fetch: Updating metrics" << endl;
|
|
+ std::cerr << "PMC_Context::fetch: Updating metrics" << std::endl;
|
|
#endif
|
|
|
|
for (i = 0; i < _metrics.length(); i++) {
|
|
@@ -384,7 +384,7 @@
|
|
}
|
|
#ifdef PCP_DEBUG
|
|
else if (pmDebug & DBG_TRACE_OPTFETCH)
|
|
- cerr << "PMC_Context::fetch: nothing to fetch" << endl;
|
|
+ std::cerr << "PMC_Context::fetch: nothing to fetch" << std::endl;
|
|
#endif
|
|
|
|
return sts;
|
|
@@ -409,12 +409,12 @@
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC) {
|
|
if (sts >= 0) {
|
|
- cerr << "PMC_Context::traverse: Found " << list.length()
|
|
- << " names from " << name << endl;
|
|
+ std::cerr << "PMC_Context::traverse: Found " << list.length()
|
|
+ << " names from " << name << std::endl;
|
|
}
|
|
else
|
|
- cerr << "PMC_Context::traverse: Failed: " << pmErrStr(sts)
|
|
- << endl;
|
|
+ std::cerr << "PMC_Context::traverse: Failed: " << pmErrStr(sts)
|
|
+ << std::endl;
|
|
}
|
|
#endif
|
|
|
|
--- src/libpcp_pmc/src/Context.h
|
|
+++ src/libpcp_pmc/src/Context.h
|
|
@@ -32,7 +32,7 @@
|
|
#endif
|
|
#endif
|
|
|
|
-#include <iostream.h>
|
|
+#include <iostream>
|
|
|
|
#include "PMC.h"
|
|
#include "Vector.h"
|
|
@@ -157,13 +157,13 @@
|
|
int traverse(char const* name, PMC_StrList& list);
|
|
|
|
// Output the source description
|
|
- friend ostream &operator<<(ostream &os, const PMC_Context & rhs);
|
|
+ friend std::ostream &operator<<(std::ostream &os, const PMC_Context & rhs);
|
|
|
|
// Dump debugging information
|
|
- void dump(ostream& os);
|
|
+ void dump(std::ostream& os);
|
|
|
|
// Dump list of metrics
|
|
- void dumpMetrics(ostream& os);
|
|
+ void dumpMetrics(std::ostream& os);
|
|
|
|
private:
|
|
|
|
--- src/libpcp_pmc/src/Desc.c++
|
|
+++ src/libpcp_pmc/src/Desc.c++
|
|
@@ -21,7 +21,7 @@
|
|
|
|
#ident "$Id: Desc.c++,v 1.2 2005/05/10 00:46:37 kenmcd Exp $"
|
|
|
|
-#include <iostream.h>
|
|
+#include <iostream>
|
|
#include "Desc.h"
|
|
|
|
PMC_Desc::PMC_Desc(pmID pmid)
|
|
@@ -34,8 +34,8 @@
|
|
}
|
|
#ifdef PCP_DEBUG
|
|
else if (pmDebug & DBG_TRACE_PMC) {
|
|
- cerr << "PMC_Desc::PMC_Desc: unable to lookup "
|
|
- << pmIDStr(_pmid) << ": " << pmErrStr(_sts) << endl;
|
|
+ std::cerr << "PMC_Desc::PMC_Desc: unable to lookup "
|
|
+ << pmIDStr(_pmid) << ": " << pmErrStr(_sts) << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
--- src/libpcp_pmc/src/Group.c++
|
|
+++ src/libpcp_pmc/src/Group.c++
|
|
@@ -156,8 +156,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC) {
|
|
- cerr << "PMC_Group::use: No direct match for context \"" << source
|
|
- << "\"." << endl;
|
|
+ std::cerr << "PMC_Group::use: No direct match for context \"" << source
|
|
+ << "\"." << std::endl;
|
|
}
|
|
#endif
|
|
|
|
@@ -205,8 +205,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC) {
|
|
- cerr << "PMC_Group::use: Creating new context for \"" << source
|
|
- << '\"' << endl;
|
|
+ std::cerr << "PMC_Group::use: Creating new context for \"" << source
|
|
+ << '\"' << std::endl;
|
|
}
|
|
#endif
|
|
|
|
@@ -255,8 +255,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Group::use: Added context " << _use << ": "
|
|
- << *newContext << endl;
|
|
+ std::cerr << "PMC_Group::use: Added context " << _use << ": "
|
|
+ << *newContext << std::endl;
|
|
#endif
|
|
}
|
|
|
|
@@ -274,15 +274,15 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Group::use: Using existing context " << _use
|
|
- << " for " << which()->source().desc() << endl;
|
|
+ std::cerr << "PMC_Group::use: Using existing context " << _use
|
|
+ << " for " << which()->source().desc() << std::endl;
|
|
#endif
|
|
}
|
|
#ifdef PCP_DEBUG
|
|
else if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Group::use: Using current context " << _use
|
|
+ std::cerr << "PMC_Group::use: Using current context " << _use
|
|
<< " (hndl = " << which()->hndl() << ") for "
|
|
- << which()->source().desc() << endl;
|
|
+ << which()->source().desc() << std::endl;
|
|
#endif
|
|
|
|
return which()->hndl();
|
|
@@ -299,9 +299,9 @@
|
|
_tzGroupIndex = _use;
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Group::useTZ: Using timezone of "
|
|
+ std::cerr << "PMC_Group::useTZ: Using timezone of "
|
|
<< which()->source().desc()
|
|
- << " (" << _tzGroupIndex << ')' << endl;
|
|
+ << " (" << _tzGroupIndex << ')' << std::endl;
|
|
#endif
|
|
}
|
|
return sts;
|
|
@@ -320,8 +320,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC) {
|
|
- cerr << "PMC_Group::useTZ: Switching timezones to \"" << tz
|
|
- << "\" (" << _tzUserStr << ')' << endl;
|
|
+ std::cerr << "PMC_Group::useTZ: Switching timezones to \"" << tz
|
|
+ << "\" (" << _tzUserStr << ')' << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
@@ -340,7 +340,7 @@
|
|
_tzDefault = _tzLocal;
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Group::useTZ: Using timezone of host \"localhost\"" << endl;
|
|
+ std::cerr << "PMC_Group::useTZ: Using timezone of host \"localhost\"" << std::endl;
|
|
#endif
|
|
}
|
|
}
|
|
@@ -404,12 +404,12 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (_localSource->status() < 0 && pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Group::createLocalContext: Default context to "
|
|
+ std::cerr << "PMC_Group::createLocalContext: Default context to "
|
|
<< _localSource->desc() << " failed: "
|
|
- << pmErrStr(_localSource->status()) << endl;
|
|
+ << pmErrStr(_localSource->status()) << std::endl;
|
|
else if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Group::createLocalContext: Default context to "
|
|
- << _localSource->desc() << endl;
|
|
+ std::cerr << "PMC_Group::createLocalContext: Default context to "
|
|
+ << _localSource->desc() << std::endl;
|
|
#endif
|
|
|
|
PMC_Context *newContext = new PMC_Context(_localSource);
|
|
@@ -453,15 +453,15 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC) {
|
|
- cerr << "PMC_Group::getTimeBounds: start = " << _timeStart.tv_sec
|
|
+ std::cerr << "PMC_Group::getTimeBounds: start = " << _timeStart.tv_sec
|
|
<< '.' << _timeStart.tv_usec << ", end = "
|
|
- << _timeEnd.tv_sec << '.' << _timeEnd.tv_usec << endl;
|
|
+ << _timeEnd.tv_sec << '.' << _timeEnd.tv_usec << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
|
|
void
|
|
-PMC_Group::dump(ostream &os)
|
|
+PMC_Group::dump(std::ostream &os)
|
|
{
|
|
uint_t i;
|
|
|
|
@@ -495,11 +495,11 @@
|
|
break;
|
|
}
|
|
|
|
- os << "\": " << endl;
|
|
+ os << "\": " << std::endl;
|
|
|
|
- os << " " << numContexts() << " contexts:" << endl;
|
|
+ os << " " << numContexts() << " contexts:" << std::endl;
|
|
for (i = 0; i < numContexts(); i++) {
|
|
- os << " [" << i << "] " << *(_contexts[i]) << endl;
|
|
+ os << " [" << i << "] " << *(_contexts[i]) << std::endl;
|
|
_contexts[i]->dumpMetrics(os);
|
|
}
|
|
}
|
|
@@ -542,7 +542,7 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Group::fetch: " << numContexts() << " contexts" << endl;
|
|
+ std::cerr << "PMC_Group::fetch: " << numContexts() << " contexts" << std::endl;
|
|
#endif
|
|
|
|
for (i = 0; i < numContexts(); i++)
|
|
@@ -553,7 +553,7 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Group::fetch: Done" << endl;
|
|
+ std::cerr << "PMC_Group::fetch: Done" << std::endl;
|
|
#endif
|
|
|
|
return sts;
|
|
--- src/libpcp_pmc/src/Group.h
|
|
+++ src/libpcp_pmc/src/Group.h
|
|
@@ -26,7 +26,7 @@
|
|
|
|
#ident "$Id: Group.h,v 1.4 2005/05/10 01:59:58 kenmcd Exp $"
|
|
|
|
-#include <iostream.h>
|
|
+#include <iostream>
|
|
#include "PMC.h"
|
|
#include "List.h"
|
|
#include "String.h"
|
|
@@ -167,7 +167,7 @@
|
|
// Determine the archive start and finish times
|
|
void updateBounds();
|
|
|
|
- void dump(ostream &os);
|
|
+ void dump(std::ostream &os);
|
|
|
|
private:
|
|
|
|
--- src/libpcp_pmc/src/Indom.c++
|
|
+++ src/libpcp_pmc/src/Indom.c++
|
|
@@ -21,7 +21,7 @@
|
|
|
|
#ident "$Id: Indom.c++,v 1.9 2005/05/10 01:59:58 kenmcd Exp $"
|
|
|
|
-#include <iostream.h>
|
|
+#include <iostream>
|
|
#include <ctype.h>
|
|
#include "Indom.h"
|
|
#include "Desc.h"
|
|
@@ -107,8 +107,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_INDOM) {
|
|
- cerr << "PMC_Indom::PMC_Indom: indom ";
|
|
- dump(cerr);
|
|
+ std::cerr << "PMC_Indom::PMC_Indom: indom ";
|
|
+ dump(std::cerr);
|
|
}
|
|
#endif
|
|
|
|
@@ -116,10 +116,10 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
else if (_sts < 0 && pmDebug & DBG_TRACE_PMC) {
|
|
- cerr << "PMC_Indom::PMC_Indom: unable to lookup "
|
|
+ std::cerr << "PMC_Indom::PMC_Indom: unable to lookup "
|
|
<< pmInDomStr(_id) << " from "
|
|
<< (_type == PM_CONTEXT_ARCHIVE ? "archive" : "host/local")
|
|
- << " source: " << pmErrStr(_sts) << endl;
|
|
+ << " source: " << pmErrStr(_sts) << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
@@ -163,9 +163,9 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Indom::lookup: inst \"" << name << "\"(" << i
|
|
+ std::cerr << "PMC_Indom::lookup: inst \"" << name << "\"(" << i
|
|
<< ") matched to \"" << _instances[i]._name << "\"(" << i
|
|
- << ')' << endl;
|
|
+ << ')' << std::endl;
|
|
#endif
|
|
|
|
if (_instances[i]._refCount == 0) {
|
|
@@ -207,9 +207,9 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Metric::setupDesc: numerical inst \""
|
|
+ std::cerr << "PMC_Metric::setupDesc: numerical inst \""
|
|
<< name << " matched to \"" << _instances[i]._name
|
|
- << "\"(" << i << ')' << endl;
|
|
+ << "\"(" << i << ')' << std::endl;
|
|
#endif
|
|
|
|
if (_instances[i]._refCount == 0) {
|
|
@@ -332,13 +332,13 @@
|
|
if (pmDebug & DBG_TRACE_PMC ||
|
|
pmDebug & DBG_TRACE_INDOM ||
|
|
pmDebug & DBG_TRACE_PROFILE) {
|
|
- cerr << "PMC_Indom::genProfile: id = " << _id << ", count = "
|
|
+ std::cerr << "PMC_Indom::genProfile: id = " << _id << ", count = "
|
|
<< _count << ", numInsts = " << numInsts() << ", active = "
|
|
<< _numActive << ", activeRef = " << _numActiveRef
|
|
<< ": " << action << " ptr = " << ptr;
|
|
if (sts < 0)
|
|
- cerr << ", sts = " << sts << ": " << pmErrStr(sts);
|
|
- cerr << endl;
|
|
+ std::cerr << ", sts = " << sts << ": " << pmErrStr(sts);
|
|
+ std::cerr << std::endl;
|
|
}
|
|
#endif
|
|
|
|
@@ -349,20 +349,20 @@
|
|
}
|
|
|
|
void
|
|
-PMC_Indom::dump(ostream &os) const
|
|
+PMC_Indom::dump(std::ostream &os) const
|
|
{
|
|
uint_t i;
|
|
|
|
os << pmInDomStr(_id) << ": " << numInsts() << " instances ("
|
|
- << _nullCount << " NULL)" << endl;
|
|
+ << _nullCount << " NULL)" << std::endl;
|
|
for (i = 0; i < _instances.length(); i++)
|
|
if (!_instances[i].null())
|
|
os << " [" << _instances[i]._inst << "] = \""
|
|
<< _instances[i]._name << "\" (" << _instances[i]._refCount
|
|
<< " refs) " << (_instances[i]._active ? "active" : "inactive")
|
|
- << endl;
|
|
+ << std::endl;
|
|
else
|
|
- os << " NULL -> " << _instances[i]._index << endl;
|
|
+ os << " NULL -> " << _instances[i]._index << std::endl;
|
|
}
|
|
|
|
int
|
|
@@ -401,9 +401,9 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_INDOM && _nullCount != oldNullCount) {
|
|
- cerr << "PMC_Indom::update: Cleaning indom " << pmInDomStr(_id)
|
|
+ std::cerr << "PMC_Indom::update: Cleaning indom " << pmInDomStr(_id)
|
|
<< ": Removed " << _nullCount - oldNullCount
|
|
- << " instances" << endl;
|
|
+ << " instances" << std::endl;
|
|
}
|
|
#endif
|
|
|
|
@@ -426,9 +426,9 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Indom::update: Updating indom " << pmInDomStr(_id)
|
|
+ std::cerr << "PMC_Indom::update: Updating indom " << pmInDomStr(_id)
|
|
<< ": Got " << count << " instances (vs " << numInsts()
|
|
- << ")" << endl;
|
|
+ << ")" << std::endl;
|
|
#endif
|
|
|
|
// Any instances which are not in the new indom AND are not
|
|
@@ -474,8 +474,8 @@
|
|
_instances[i]._name == nameList[i]) {
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_INDOM)
|
|
- cerr << "PMC_Indom::update: Unchanged \"" << nameList[i]
|
|
- << "\"(" << instList[i] << ')' << endl;
|
|
+ std::cerr << "PMC_Indom::update: Unchanged \"" << nameList[i]
|
|
+ << "\"(" << instList[i] << ')' << std::endl;
|
|
#endif
|
|
_instances[i]._active = PMC_true;
|
|
_numActive++;
|
|
@@ -500,10 +500,10 @@
|
|
}
|
|
#ifdef PCP_DEBUG
|
|
else if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Indom::update: Ignoring \""
|
|
+ std::cerr << "PMC_Indom::update: Ignoring \""
|
|
<< nameList[i]
|
|
<< "\" with identical internal identifier ("
|
|
- << instList[i] << ")" << endl;
|
|
+ << instList[i] << ")" << std::endl;
|
|
#endif
|
|
break;
|
|
}
|
|
@@ -512,8 +512,8 @@
|
|
if (j == oldLen) {
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_INDOM)
|
|
- cerr << "PMC_Indom::update: Adding \"" << nameList[i]
|
|
- << "\"(" << instList[i] << ")" << endl;
|
|
+ std::cerr << "PMC_Indom::update: Adding \"" << nameList[i]
|
|
+ << "\"(" << instList[i] << ")" << std::endl;
|
|
#endif
|
|
|
|
if (_nullCount) {
|
|
@@ -537,11 +537,11 @@
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_INDOM) {
|
|
if (_instances.length() == oldLen && _nullCount == oldNullCount)
|
|
- cerr << "PMC_Indom::update: indom size unchanged" << endl;
|
|
+ std::cerr << "PMC_Indom::update: indom size unchanged" << std::endl;
|
|
else {
|
|
- cerr << "PMC_Indom::update: indom changed from "
|
|
- << oldLen - oldNullCount << " to " << numInsts() << endl;
|
|
- dump(cerr);
|
|
+ std::cerr << "PMC_Indom::update: indom changed from "
|
|
+ << oldLen - oldNullCount << " to " << numInsts() << std::endl;
|
|
+ dump(std::cerr);
|
|
}
|
|
}
|
|
#endif
|
|
@@ -553,11 +553,11 @@
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC) {
|
|
if (sts == 0)
|
|
- cerr << "PMC_Indom::update: indom empty!" << endl;
|
|
+ std::cerr << "PMC_Indom::update: indom empty!" << std::endl;
|
|
else
|
|
- cerr << "PMC_Indom::update: unable to lookup "
|
|
+ std::cerr << "PMC_Indom::update: unable to lookup "
|
|
<< pmInDomStr(_id) << " from host/local source: "
|
|
- << pmErrStr(sts) << endl;
|
|
+ << pmErrStr(sts) << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
--- src/libpcp_pmc/src/Indom.h
|
|
+++ src/libpcp_pmc/src/Indom.h
|
|
@@ -24,7 +24,7 @@
|
|
|
|
#ident "$Id: Indom.h,v 1.10 2005/05/10 01:59:58 kenmcd Exp $"
|
|
|
|
-#include <iostream.h>
|
|
+#include <iostream>
|
|
#include <assert.h>
|
|
#include "PMC.h"
|
|
#include "String.h"
|
|
@@ -164,7 +164,7 @@
|
|
{ _instances[inst]._index = index; }
|
|
|
|
// Dump some debugging output for this indom
|
|
- void dump(ostream &os) const;
|
|
+ void dump(std::ostream &os) const;
|
|
};
|
|
|
|
#endif /* _PMC_INDOM_H_ */
|
|
--- src/libpcp_pmc/src/Metric.c++
|
|
+++ src/libpcp_pmc/src/Metric.c++
|
|
@@ -21,7 +21,7 @@
|
|
|
|
#ident "$Id: Metric.c++,v 1.9 2005/05/10 01:59:58 kenmcd Exp $"
|
|
|
|
-#include <iostream.h>
|
|
+#include <iostream>
|
|
#include <strings.h>
|
|
#include "Metric.h"
|
|
#include "Group.h"
|
|
@@ -312,7 +312,7 @@
|
|
}
|
|
|
|
void
|
|
-PMC_Metric::dumpSource(ostream &os) const
|
|
+PMC_Metric::dumpSource(std::ostream &os) const
|
|
{
|
|
switch(context().source().type()) {
|
|
case PM_CONTEXT_LOCAL:
|
|
@@ -328,7 +328,7 @@
|
|
}
|
|
|
|
void
|
|
-PMC_Metric::dumpValue(ostream &os, uint_t inst) const
|
|
+PMC_Metric::dumpValue(std::ostream &os, uint_t inst) const
|
|
{
|
|
if (error(inst) < 0)
|
|
os << pmErrStr(error(inst));
|
|
@@ -339,7 +339,7 @@
|
|
}
|
|
|
|
void
|
|
-PMC_Metric::dump(ostream &os, PMC_Bool srcFlag, uint_t instance) const
|
|
+PMC_Metric::dump(std::ostream &os, PMC_Bool srcFlag, uint_t instance) const
|
|
{
|
|
uint_t i;
|
|
|
|
@@ -349,7 +349,7 @@
|
|
os << name();
|
|
|
|
if (_sts < 0)
|
|
- os << ": " << pmErrStr(_sts) << endl;
|
|
+ os << ": " << pmErrStr(_sts) << std::endl;
|
|
else if (hasInstances()) {
|
|
if (instance == UINT_MAX) {
|
|
if (numInst() == 1)
|
|
@@ -360,31 +360,31 @@
|
|
if (indom()->changed())
|
|
os << " (indom has changed)";
|
|
|
|
- os << endl;
|
|
+ os << std::endl;
|
|
|
|
for (i = 0; i < numInst(); i++) {
|
|
os << " [" << instID(i) << " or \"" << instName(i) << "\" ("
|
|
<< _values[i]._instance << ")] = ";
|
|
dumpValue(os, i);
|
|
- os << endl;
|
|
+ os << std::endl;
|
|
}
|
|
}
|
|
else {
|
|
os << '[' << instID(instance) << " or \"" << instName(instance)
|
|
<< "\" (" << _values[instance]._instance << ")] = ";
|
|
dumpValue(os, instance);
|
|
- os << endl;
|
|
+ os << std::endl;
|
|
}
|
|
}
|
|
else {
|
|
os << " = ";
|
|
dumpValue(os, 0);
|
|
- os << endl;
|
|
+ os << std::endl;
|
|
}
|
|
}
|
|
|
|
-ostream&
|
|
-operator<<(ostream &os, const PMC_Metric &mtrc)
|
|
+std::ostream&
|
|
+operator<<(std::ostream &os, const PMC_Metric &mtrc)
|
|
{
|
|
uint_t num = mtrc.numValues();
|
|
uint_t i;
|
|
@@ -433,8 +433,8 @@
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_VALUE)
|
|
if (_values[i]._error < 0)
|
|
- cerr << "PMC_Metric::update: " << spec(PMC_true, PMC_true, i)
|
|
- << ": " << pmErrStr(_values[i]._error) << endl;
|
|
+ std::cerr << "PMC_Metric::update: " << spec(PMC_true, PMC_true, i)
|
|
+ << ": " << pmErrStr(_values[i]._error) << std::endl;
|
|
#endif
|
|
}
|
|
|
|
@@ -460,9 +460,9 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_VALUE) {
|
|
- cerr << "PMC_Metric::update: Previous: "
|
|
+ std::cerr << "PMC_Metric::update: Previous: "
|
|
<< spec(PMC_true, PMC_true, i) << ": "
|
|
- << pmErrStr(value._error) << endl;
|
|
+ << pmErrStr(value._error) << std::endl;
|
|
}
|
|
#endif
|
|
|
|
@@ -555,9 +555,9 @@
|
|
_values[i]._value = oval.d;
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_VALUE)
|
|
- cerr << "PMC_Metric::update: scaled " << _name
|
|
+ std::cerr << "PMC_Metric::update: scaled " << _name
|
|
<< " from " << ival.d << " to " << oval.d
|
|
- << endl;
|
|
+ << std::endl;
|
|
#endif
|
|
}
|
|
}
|
|
@@ -569,9 +569,9 @@
|
|
void
|
|
PMC_Metric::dumpAll() const
|
|
{
|
|
- cerr << *this << " from " << context().source().desc()
|
|
+ std::cerr << *this << " from " << context().source().desc()
|
|
<< " with scale = " << _scale << " and units = " << desc().units()
|
|
- << endl;
|
|
+ << std::endl;
|
|
}
|
|
|
|
void
|
|
@@ -684,10 +684,10 @@
|
|
if (!_explicit && ((int)_values.length() != set->numval)) {
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_INDOM)
|
|
- cerr << "PMC_Metric::extractValues: implicit indom "
|
|
+ std::cerr << "PMC_Metric::extractValues: implicit indom "
|
|
<< pmInDomStr(indomPtr->id()) << " changed ("
|
|
<< set->numval << " != " << _values.length() << ')'
|
|
- << endl;
|
|
+ << std::endl;
|
|
#endif
|
|
indomPtr->hasChanged();
|
|
}
|
|
@@ -749,9 +749,9 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_OPTFETCH)
|
|
- cerr << "PMC_Metric::extractValues: "
|
|
+ std::cerr << "PMC_Metric::extractValues: "
|
|
<< spec(PMC_true, PMC_true, i) << ": "
|
|
- << pmErrStr(PM_ERR_VALUE) << endl;
|
|
+ << pmErrStr(PM_ERR_VALUE) << std::endl;
|
|
#endif
|
|
|
|
if (valueRef._prevError != PM_ERR_VALUE)
|
|
@@ -806,9 +806,9 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_OPTFETCH)
|
|
- cerr << "PMC_Metric::extractValues: " << spec(PMC_true)
|
|
+ std::cerr << "PMC_Metric::extractValues: " << spec(PMC_true)
|
|
<< " is a singular metric but result contained "
|
|
- << set->numval << " values" << endl;
|
|
+ << set->numval << " values" << std::endl;
|
|
#endif
|
|
|
|
setError(PM_ERR_VALUE);
|
|
@@ -820,8 +820,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_OPTFETCH)
|
|
- cerr << "PMC_Metric::extractValues: numval == 0: " << spec(PMC_true, PMC_false)
|
|
- << ": " << pmErrStr(PM_ERR_VALUE) << endl;
|
|
+ std::cerr << "PMC_Metric::extractValues: numval == 0: " << spec(PMC_true, PMC_false)
|
|
+ << ": " << pmErrStr(PM_ERR_VALUE) << std::endl;
|
|
#endif
|
|
|
|
setError(PM_ERR_VALUE);
|
|
@@ -833,8 +833,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_OPTFETCH)
|
|
- cerr << "PMC_Metric::extractValues: numval < 0: " << spec(PMC_true, PMC_false)
|
|
- << ": " << pmErrStr(set->numval) << endl;
|
|
+ std::cerr << "PMC_Metric::extractValues: numval < 0: " << spec(PMC_true, PMC_false)
|
|
+ << ": " << pmErrStr(set->numval) << std::endl;
|
|
#endif
|
|
|
|
setError(set->numval);
|
|
@@ -883,7 +883,7 @@
|
|
if (!_active || i == _values.length()) {
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_INDOM)
|
|
- cerr << "PMC_Metric::updateIndom: No change required" << endl;
|
|
+ std::cerr << "PMC_Metric::updateIndom: No change required" << std::endl;
|
|
#endif
|
|
return PMC_false;
|
|
/*NOTREACHED*/
|
|
@@ -942,8 +942,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Metric::updateIndom: " << spec(PMC_true) << ": Had "
|
|
- << oldNum << " instances, now have " << numInst() << endl;
|
|
+ std::cerr << "PMC_Metric::updateIndom: " << spec(PMC_true) << ": Had "
|
|
+ << oldNum << " instances, now have " << numInst() << std::endl;
|
|
#endif
|
|
|
|
indomPtr->update();
|
|
--- src/libpcp_pmc/src/Metric.h
|
|
+++ src/libpcp_pmc/src/Metric.h
|
|
@@ -219,15 +219,15 @@
|
|
uint_t instance = UINT_MAX) const;
|
|
|
|
// Dump out the metric and its current value(s)
|
|
- void dump(ostream &os,
|
|
+ void dump(std::ostream &os,
|
|
PMC_Bool srcFlag = PMC_false,
|
|
uint_t instance = UINT_MAX) const;
|
|
|
|
// Dump out the current value
|
|
- void dumpValue(ostream &os, uint_t instance) const;
|
|
+ void dumpValue(std::ostream &os, uint_t instance) const;
|
|
|
|
// Dump out the metric source
|
|
- void dumpSource(ostream &os) const;
|
|
+ void dumpSource(std::ostream &os) const;
|
|
|
|
// Format a value into a fixed width format
|
|
static const char *formatNumber(double value);
|
|
@@ -235,7 +235,7 @@
|
|
// Determine the current errors and rate-converted scaled values
|
|
int update();
|
|
|
|
- friend ostream &operator<<(ostream &os, const PMC_Metric &metric);
|
|
+ friend std::ostream &operator<<(std::ostream &os, const PMC_Metric &metric);
|
|
|
|
private:
|
|
|
|
--- src/libpcp_pmc/src/Source.c++
|
|
+++ src/libpcp_pmc/src/Source.c++
|
|
@@ -113,8 +113,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Source::PMC_Source: Created context "
|
|
- << _hndls.tail() << " to " << _desc << endl;
|
|
+ std::cerr << "PMC_Source::PMC_Source: Created context "
|
|
+ << _hndls.tail() << " to " << _desc << std::endl;
|
|
#endif
|
|
|
|
oldTZ = pmWhichZone(&tzs);
|
|
@@ -144,8 +144,8 @@
|
|
}
|
|
#ifdef PCP_DEBUG
|
|
else if (pmDebug & DBG_TRACE_PMC) {
|
|
- cerr << "PMC_Source::PMC_Source: Context to " << source
|
|
- << " failed: " << pmErrStr(_sts) << endl;
|
|
+ std::cerr << "PMC_Source::PMC_Source: Context to " << source
|
|
+ << " failed: " << pmErrStr(_sts) << std::endl;
|
|
}
|
|
#endif
|
|
|
|
@@ -186,9 +186,9 @@
|
|
src->host() == source) {
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Source::getSource: Matched host "
|
|
+ std::cerr << "PMC_Source::getSource: Matched host "
|
|
<< source << " to archive " << src->source()
|
|
- << " (source " << i << ")" << endl;
|
|
+ << " (source " << i << ")" << std::endl;
|
|
#endif
|
|
break;
|
|
}
|
|
@@ -197,8 +197,8 @@
|
|
src->source() == source) {
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Source::getSource: Matched " << source
|
|
- << " to source " << i << endl;
|
|
+ std::cerr << "PMC_Source::getSource: Matched " << source
|
|
+ << " to source " << i << std::endl;
|
|
#endif
|
|
if (src->_sts < 0) {
|
|
// try and connect again
|
|
@@ -214,11 +214,11 @@
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
if (type != PM_CONTEXT_LOCAL)
|
|
- cerr << "PMC_Source::getSource: Creating new source for "
|
|
- << source << endl;
|
|
+ std::cerr << "PMC_Source::getSource: Creating new source for "
|
|
+ << source << std::endl;
|
|
else
|
|
- cerr << "PMC_Source::getSource: Creating new LOCAL source"
|
|
- << endl;
|
|
+ std::cerr << "PMC_Source::getSource: Creating new LOCAL source"
|
|
+ << std::endl;
|
|
#endif
|
|
|
|
src = new PMC_Source(type, source);
|
|
@@ -226,8 +226,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (src == NULL && pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Source::getSource: Unable to map host "
|
|
- << source << " to an arch context" << endl;
|
|
+ std::cerr << "PMC_Source::getSource: Unable to map host "
|
|
+ << source << " to an arch context" << std::endl;
|
|
#endif
|
|
|
|
return src;
|
|
@@ -262,8 +262,8 @@
|
|
_dupFlag = PMC_true;
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Source::dupContext: Using original context for "
|
|
- << _desc << endl;
|
|
+ std::cerr << "PMC_Source::dupContext: Using original context for "
|
|
+ << _desc << std::endl;
|
|
#endif
|
|
}
|
|
else {
|
|
@@ -280,9 +280,9 @@
|
|
_hndls.append(sts);
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Source::dupContext: " << _desc
|
|
+ std::cerr << "PMC_Source::dupContext: " << _desc
|
|
<< " duplicated, hndl[" << _hndls.length()-1
|
|
- << "] = " << sts << endl;
|
|
+ << "] = " << sts << std::endl;
|
|
#endif
|
|
}
|
|
else {
|
|
@@ -309,16 +309,16 @@
|
|
_hndls.append(sts);
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Source::dupContext: new context to " << _desc
|
|
- << " created, hndl = " << sts << endl;
|
|
+ std::cerr << "PMC_Source::dupContext: new context to " << _desc
|
|
+ << " created, hndl = " << sts << std::endl;
|
|
#endif
|
|
}
|
|
}
|
|
#ifdef PCP_DEBUG
|
|
if (sts < 0 && pmDebug & DBG_TRACE_PMC) {
|
|
if (sts < 0)
|
|
- cerr << "PMC_Source::dupContext: context to " << _desc
|
|
- << " failed: " << pmErrStr(_sts) << endl;
|
|
+ std::cerr << "PMC_Source::dupContext: context to " << _desc
|
|
+ << " failed: " << pmErrStr(_sts) << std::endl;
|
|
}
|
|
#endif
|
|
|
|
@@ -338,9 +338,9 @@
|
|
if (i == _hndls.length()) {
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Source::delContext: Attempt to delete " << hndl
|
|
+ std::cerr << "PMC_Source::delContext: Attempt to delete " << hndl
|
|
<< " from list for " << _desc << ", but it is not listed"
|
|
- << endl;
|
|
+ << std::endl;
|
|
#endif
|
|
return PM_ERR_NOCONTEXT;
|
|
/*NOTREACHED*/
|
|
@@ -354,8 +354,8 @@
|
|
if (_hndls.length() == 0 && _sts >= 0) {
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_PMC)
|
|
- cerr << "PMC_Source::delContext: No contexts remain, removing "
|
|
- << _desc << endl;
|
|
+ std::cerr << "PMC_Source::delContext: No contexts remain, removing "
|
|
+ << _desc << std::endl;
|
|
#endif
|
|
delete this;
|
|
}
|
|
@@ -363,42 +363,42 @@
|
|
return sts;
|
|
}
|
|
|
|
-ostream&
|
|
-operator<<(ostream &os, const PMC_Source &rhs)
|
|
+std::ostream&
|
|
+operator<<(std::ostream &os, const PMC_Source &rhs)
|
|
{
|
|
os << rhs._desc;
|
|
return os;
|
|
}
|
|
|
|
void
|
|
-PMC_Source::dump(ostream& os)
|
|
+PMC_Source::dump(std::ostream& os)
|
|
{
|
|
uint_t i;
|
|
|
|
os << " sts = " << _sts << ", type = " << _type << ", source = "
|
|
- << _source << endl << " host = " << _host << ", timezone = "
|
|
- << _timezone << ", tz hndl = " << _tz << endl;
|
|
+ << _source << std::endl << " host = " << _host << ", timezone = "
|
|
+ << _timezone << ", tz hndl = " << _tz << std::endl;
|
|
|
|
if (_sts >= 0) {
|
|
os << " start = " << __pmtimevalToReal(&_start) << ", end = "
|
|
<< __pmtimevalToReal(&_end) << ", dupFlag = "
|
|
- << (_dupFlag == PMC_true ? "true" : "false") << endl << " "
|
|
+ << (_dupFlag == PMC_true ? "true" : "false") << std::endl << " "
|
|
<< _hndls.length() << " contexts: ";
|
|
}
|
|
|
|
for (i = 0; i < _hndls.length(); i++)
|
|
os << _hndls[i] << ' ';
|
|
|
|
- os << endl;
|
|
+ os << std::endl;
|
|
}
|
|
|
|
void
|
|
-PMC_Source::dumpList(ostream& os)
|
|
+PMC_Source::dumpList(std::ostream& os)
|
|
{
|
|
uint_t i;
|
|
- os << _sourceList.length() << " sources:" << endl;
|
|
+ os << _sourceList.length() << " sources:" << std::endl;
|
|
for (i = 0; i < _sourceList.length(); i++) {
|
|
- os << '[' << i << "] " << *(_sourceList[i]) << endl;
|
|
+ os << '[' << i << "] " << *(_sourceList[i]) << std::endl;
|
|
_sourceList[i]->dump(os);
|
|
}
|
|
}
|
|
--- src/libpcp_pmc/src/Source.h
|
|
+++ src/libpcp_pmc/src/Source.h
|
|
@@ -26,7 +26,7 @@
|
|
|
|
#ident "$Id: Source.h,v 1.3 2005/05/10 00:46:37 kenmcd Exp $"
|
|
|
|
-#include <iostream.h>
|
|
+#include <iostream>
|
|
#include "PMC.h"
|
|
#include "String.h"
|
|
#include "List.h"
|
|
@@ -118,13 +118,13 @@
|
|
int delContext(int hndl);
|
|
|
|
// Output the source
|
|
- friend ostream &operator<<(ostream &os, const PMC_Source & rhs);
|
|
+ friend std::ostream &operator<<(std::ostream &os, const PMC_Source & rhs);
|
|
|
|
// Dump all info about a source
|
|
- void dump(ostream& os);
|
|
+ void dump(std::ostream& os);
|
|
|
|
// Dump list of known sources
|
|
- static void dumpList(ostream& os);
|
|
+ static void dumpList(std::ostream& os);
|
|
|
|
private:
|
|
|
|
--- src/libpcp_pmc/src/String.c++
|
|
+++ src/libpcp_pmc/src/String.c++
|
|
@@ -280,8 +280,8 @@
|
|
return *this;
|
|
}
|
|
|
|
-ostream&
|
|
-operator<<(ostream &os, PMC_String const& rhs)
|
|
+std::ostream&
|
|
+operator<<(std::ostream &os, PMC_String const& rhs)
|
|
{
|
|
os << rhs._str.ptr();
|
|
return os;
|
|
--- src/libpcp_pmc/src/String.h
|
|
+++ src/libpcp_pmc/src/String.h
|
|
@@ -35,7 +35,7 @@
|
|
#include <sys/types.h>
|
|
#include <assert.h>
|
|
#include <string.h>
|
|
-#include <iostream.h>
|
|
+#include <iostream>
|
|
#include "Vector.h"
|
|
#include "List.h"
|
|
#include "Bool.h"
|
|
@@ -131,7 +131,7 @@
|
|
{ _str.resize(_len + 1); return *this; }
|
|
|
|
// Output the string
|
|
- friend ostream& operator<<(ostream &os, PMC_String const& rhs);
|
|
+ friend std::ostream& operator<<(std::ostream &os, PMC_String const& rhs);
|
|
};
|
|
|
|
typedef PMC_List<PMC_String> PMC_StrList;
|
|
--- src/pmdumptext/pmdumptext.c++
|
|
+++ src/pmdumptext/pmdumptext.c++
|
|
@@ -23,8 +23,8 @@
|
|
|
|
#include <math.h>
|
|
#include <float.h>
|
|
-#include <iostream.h>
|
|
-#include <iomanip.h>
|
|
+#include <iostream>
|
|
+#include <iomanip>
|
|
#include <stdio.h>
|
|
#include <string.h>
|
|
#include <ctype.h>
|
|
@@ -110,8 +110,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0) {
|
|
- cerr << "checkUnits: Changing " << metric->name()
|
|
- << " to use bytes" << endl;
|
|
+ std::cerr << "checkUnits: Changing " << metric->name()
|
|
+ << " to use bytes" << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
@@ -128,8 +128,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0) {
|
|
- cerr << "checkUnits: Changing " << metric->name()
|
|
- << " to use counts" << endl;
|
|
+ std::cerr << "checkUnits: Changing " << metric->name()
|
|
+ << " to use counts" << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
@@ -147,8 +147,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0) {
|
|
- cerr << "checkUnits: Changing " << metric->name()
|
|
- << " to use time utilization" << endl;
|
|
+ std::cerr << "checkUnits: Changing " << metric->name()
|
|
+ << " to use time utilization" << std::endl;
|
|
}
|
|
#endif
|
|
}
|
|
@@ -344,8 +344,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0)
|
|
- cerr << "parseConfig: Adding metric '" << buf << "' with scale = "
|
|
- << scale << " from line " << line << endl;
|
|
+ std::cerr << "parseConfig: Adding metric '" << buf << "' with scale = "
|
|
+ << scale << " from line " << line << std::endl;
|
|
#endif
|
|
|
|
if (traverse(buf, scale) < 0)
|
|
@@ -431,11 +431,11 @@
|
|
for (m = 0, v = 1; m < (int)metrics.length(); m++) {
|
|
metric = metrics[m];
|
|
for (i = 0; i < (int)metric->numValues(); i++, v++) {
|
|
- cout << '[' << setw(2) << v << "] "
|
|
- << metric->spec(sourceFlag, PMC_true, i) << endl;
|
|
+ std::cout << '[' << std::setw(2) << v << "] "
|
|
+ << metric->spec(sourceFlag, PMC_true, i) << std::endl;
|
|
}
|
|
}
|
|
- cout << endl;
|
|
+ std::cout << std::endl;
|
|
}
|
|
|
|
if (fullOnce) {
|
|
@@ -443,20 +443,20 @@
|
|
if (len < (int)columnStr.length()) {
|
|
columnStr.remove(len, columnStr.length() - len);
|
|
}
|
|
- cout << setw(len) << columnStr << delimiter;
|
|
+ std::cout << std::setw(len) << columnStr << delimiter;
|
|
}
|
|
|
|
for (m = 0, v = 1; m < (int)metrics.length(); m++) {
|
|
metric = metrics[m];
|
|
for (i = 0; i < (int)metric->numValues(); i++) {
|
|
- cout << setw(width) << v;
|
|
+ std::cout << std::setw(width) << v;
|
|
if (v < numValues) {
|
|
- cout << delimiter;
|
|
+ std::cout << delimiter;
|
|
v++;
|
|
}
|
|
}
|
|
}
|
|
- cout << endl;
|
|
+ std::cout << std::endl;
|
|
}
|
|
|
|
if (niceFlag && sourceFlag) {
|
|
@@ -464,7 +464,7 @@
|
|
if (len < (int)srcStr.length()) {
|
|
srcStr.remove(len, srcStr.length() - len);
|
|
}
|
|
- cout << setw(len) << srcStr << delimiter;
|
|
+ std::cout << std::setw(len) << srcStr << delimiter;
|
|
}
|
|
|
|
for (m = 0, v = 1; m < (int)metrics.length(); m++) {
|
|
@@ -473,14 +473,14 @@
|
|
strncpy(buffer, str.ptr(), width);
|
|
buffer[width] = '\0';
|
|
for (i = 0; i < (int)metric->numValues(); i++) {
|
|
- cout << setw(width) << buffer;
|
|
+ std::cout << std::setw(width) << buffer;
|
|
if (v < numValues) {
|
|
- cout << delimiter;
|
|
+ std::cout << delimiter;
|
|
v++;
|
|
}
|
|
}
|
|
}
|
|
- cout << endl;
|
|
+ std::cout << std::endl;
|
|
}
|
|
|
|
if (metricFlag || (sourceFlag && !niceFlag)) {
|
|
@@ -489,10 +489,10 @@
|
|
if (len < (int)metricStr.length()) {
|
|
metricStr.remove(len, metricStr.length() - len);
|
|
}
|
|
- cout << setw(len) << metricStr << delimiter;
|
|
+ std::cout << std::setw(len) << metricStr << delimiter;
|
|
}
|
|
else
|
|
- cout << "Time" << delimiter;
|
|
+ std::cout << "Time" << delimiter;
|
|
|
|
for (m = 0, v = 1; m < (int)metrics.length(); m++) {
|
|
metric = metrics[m];
|
|
@@ -512,22 +512,22 @@
|
|
}
|
|
}
|
|
if (c < (int)str.length())
|
|
- cout << setw(width) << (str.ptr() + c);
|
|
+ std::cout << std::setw(width) << (str.ptr() + c);
|
|
else
|
|
- cout << setw(width) << (str.ptr() + p);
|
|
+ std::cout << std::setw(width) << (str.ptr() + p);
|
|
}
|
|
else
|
|
- cout << setw(width) << str;
|
|
+ std::cout << std::setw(width) << str;
|
|
}
|
|
else
|
|
- cout << metric->spec(sourceFlag, PMC_true, i);
|
|
+ std::cout << metric->spec(sourceFlag, PMC_true, i);
|
|
if (v < numValues) {
|
|
- cout << delimiter;
|
|
+ std::cout << delimiter;
|
|
v++;
|
|
}
|
|
}
|
|
}
|
|
- cout << endl;
|
|
+ std::cout << std::endl;
|
|
}
|
|
|
|
if (instFlag) {
|
|
@@ -536,10 +536,10 @@
|
|
if (len < (int)instStr.length()) {
|
|
instStr.remove(len, instStr.length() - len);
|
|
}
|
|
- cout << setw(len) << instStr << delimiter;
|
|
+ std::cout << std::setw(len) << instStr << delimiter;
|
|
}
|
|
else
|
|
- cout << setw(len) << errStr << delimiter;
|
|
+ std::cout << std::setw(len) << errStr << delimiter;
|
|
|
|
for (m = 0, v = 1; m < (int)metrics.length(); m++) {
|
|
metric = metrics[m];
|
|
@@ -548,18 +548,18 @@
|
|
PMC_String const &str = metric->instName(i);
|
|
strncpy(buffer, str.ptr(), width);
|
|
buffer[width] = '\0';
|
|
- cout << setw(width) << buffer;
|
|
+ std::cout << std::setw(width) << buffer;
|
|
}
|
|
else
|
|
- cout << setw(width) << "n/a";
|
|
+ std::cout << std::setw(width) << "n/a";
|
|
|
|
if (v < numValues) {
|
|
- cout << delimiter;
|
|
+ std::cout << delimiter;
|
|
v++;
|
|
}
|
|
}
|
|
}
|
|
- cout << endl;
|
|
+ std::cout << std::endl;
|
|
}
|
|
|
|
if (normFlag) {
|
|
@@ -568,33 +568,33 @@
|
|
if (len < (int)normStr.length()) {
|
|
normStr.remove(len, normStr.length() - len);
|
|
}
|
|
- cout << setw(len) << normStr << delimiter;
|
|
+ std::cout << std::setw(len) << normStr << delimiter;
|
|
}
|
|
else
|
|
- cout << errStr << delimiter;
|
|
+ std::cout << errStr << delimiter;
|
|
|
|
for (m = 0, v = 1; m < (int)metrics.length(); m++) {
|
|
metric = metrics[m];
|
|
for (i = 0; i < (int)metric->numValues(); i++) {
|
|
if (shortFlag)
|
|
- cout << setprecision(precision)
|
|
- << setw(width)
|
|
+ std::cout << std::setprecision(precision)
|
|
+ << std::setw(width)
|
|
<< metric->scale();
|
|
else if (descFlag)
|
|
- cout << setw(width)
|
|
+ std::cout << std::setw(width)
|
|
<< PMC_Metric::formatNumber(metric->scale());
|
|
else
|
|
- cout << setiosflags(ios::fixed)
|
|
- << setprecision(precision)
|
|
- << setw(width)
|
|
+ std::cout << setiosflags(std::ios::fixed)
|
|
+ << std::setprecision(precision)
|
|
+ << std::setw(width)
|
|
<< metric->scale();
|
|
if (v < numValues) {
|
|
- cout << delimiter;
|
|
+ std::cout << delimiter;
|
|
v++;
|
|
}
|
|
}
|
|
}
|
|
- cout << endl;
|
|
+ std::cout << std::endl;
|
|
}
|
|
|
|
if (unitFlag) {
|
|
@@ -603,10 +603,10 @@
|
|
if (len < (int)unitStr.length()) {
|
|
unitStr.remove(len, unitStr.length() - len);
|
|
}
|
|
- cout << setw(len) << unitStr << delimiter;
|
|
+ std::cout << std::setw(len) << unitStr << delimiter;
|
|
}
|
|
else
|
|
- cout << noneStr << delimiter;
|
|
+ std::cout << noneStr << delimiter;
|
|
|
|
for (m = 0, v = 1; m < (int)metrics.length(); m++) {
|
|
metric = metrics[m];
|
|
@@ -615,19 +615,19 @@
|
|
for (i = 0; i < (int)metric->numValues(); i++) {
|
|
if (niceFlag)
|
|
if ((int)str.length() > width)
|
|
- cout << setw(width)
|
|
+ std::cout << std::setw(width)
|
|
<< (str.ptr() + str.length() - width);
|
|
else
|
|
- cout << setw(width) << str;
|
|
+ std::cout << std::setw(width) << str;
|
|
else
|
|
- cout << str;
|
|
+ std::cout << str;
|
|
if (v < numValues) {
|
|
- cout << delimiter;
|
|
+ std::cout << delimiter;
|
|
v++;
|
|
}
|
|
}
|
|
}
|
|
- cout << endl;
|
|
+ std::cout << std::endl;
|
|
}
|
|
}
|
|
|
|
@@ -1050,7 +1050,7 @@
|
|
/*NOTREACHED*/
|
|
}
|
|
|
|
- // Set up cout to use the required formatting
|
|
+ // Set up std::cout to use the required formatting
|
|
//
|
|
if (niceFlag) {
|
|
width = width < 6 ? 6 : width;
|
|
@@ -1081,9 +1081,9 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0)
|
|
- cerr << "main: optind = " << optind << ", argc = " << argc
|
|
+ std::cerr << "main: optind = " << optind << ", argc = " << argc
|
|
<< ", width = " << width << ", precision = " << precision
|
|
- << endl;
|
|
+ << std::endl;
|
|
#endif
|
|
|
|
if (optind == argc) {
|
|
@@ -1132,8 +1132,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0)
|
|
- cerr << "main: parsed " << metrics.length() << " metrics"
|
|
- << endl;
|
|
+ std::cerr << "main: parsed " << metrics.length() << " metrics"
|
|
+ << std::endl;
|
|
#endif
|
|
|
|
group->useDefault();
|
|
@@ -1150,7 +1150,7 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0)
|
|
- cerr << "main: default source is " << *(group->which()) << endl;
|
|
+ std::cerr << "main: default source is " << *(group->which()) << std::endl;
|
|
#endif
|
|
|
|
if (zflag)
|
|
@@ -1170,8 +1170,8 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0) {
|
|
- cerr << "main: Using timezone \"" << tzString << "\" from " << tzLabel
|
|
- << endl;
|
|
+ std::cerr << "main: Using timezone \"" << tzString << "\" from " << tzLabel
|
|
+ << std::endl;
|
|
}
|
|
#endif
|
|
|
|
@@ -1187,8 +1187,8 @@
|
|
}
|
|
#ifdef PCP_DEBUG
|
|
else if (pmDebug & DBG_TRACE_APPL0)
|
|
- cerr << "main: Changed environment with \""
|
|
- << tzEnv << '"' << endl;
|
|
+ std::cerr << "main: Changed environment with \""
|
|
+ << tzEnv << '"' << std::endl;
|
|
#endif
|
|
}
|
|
|
|
@@ -1210,10 +1210,10 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0) {
|
|
- cerr << "main: start = "
|
|
+ std::cerr << "main: start = "
|
|
<< __pmtimevalToReal(&logStartTime) << ", end = "
|
|
<< __pmtimevalToReal(&logEndTime)
|
|
- << endl;
|
|
+ << std::endl;
|
|
}
|
|
#endif
|
|
|
|
@@ -1237,9 +1237,9 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0) {
|
|
- cerr << "main: realStartTime = " << __pmtimevalToReal(&realStartTime)
|
|
+ std::cerr << "main: realStartTime = " << __pmtimevalToReal(&realStartTime)
|
|
<< ", endTime = " << endTime << ", pos = " << pos
|
|
- << ", delay = " << delay << endl;
|
|
+ << ", delay = " << delay << std::endl;
|
|
}
|
|
#endif
|
|
|
|
@@ -1262,11 +1262,11 @@
|
|
}
|
|
|
|
if (shortFlag) {
|
|
- cout.precision(precision);
|
|
+ std::cout.precision(precision);
|
|
}
|
|
else if (!descFlag) {
|
|
- cout.precision(precision);
|
|
- cout.setf(ios::fixed);
|
|
+ std::cout.precision(precision);
|
|
+ std::cout.setf(std::ios::fixed);
|
|
}
|
|
|
|
while(pos <= endTime &&
|
|
@@ -1276,7 +1276,7 @@
|
|
sampleCount++;
|
|
|
|
if (timeFlag)
|
|
- cout << dumpTime(position) << delimiter;
|
|
+ std::cout << dumpTime(position) << delimiter;
|
|
|
|
for (m = 0, v = 1; m < (int)metrics.length(); m++) {
|
|
metric = metrics[m];
|
|
@@ -1285,9 +1285,9 @@
|
|
if (rawFlag) {
|
|
if (metric->currError(i) < 0) {
|
|
if (niceFlag)
|
|
- cout << setw(width) << errStr;
|
|
+ std::cout << std::setw(width) << errStr;
|
|
else
|
|
- cout << errStr;
|
|
+ std::cout << errStr;
|
|
goto next;
|
|
}
|
|
else if (metric->real())
|
|
@@ -1295,9 +1295,9 @@
|
|
}
|
|
else if (metric->error(i) < 0) {
|
|
if (niceFlag)
|
|
- cout << setw(width) << errStr;
|
|
+ std::cout << std::setw(width) << errStr;
|
|
else
|
|
- cout << errStr;
|
|
+ std::cout << errStr;
|
|
goto next;
|
|
}
|
|
else if (metric->real())
|
|
@@ -1306,14 +1306,14 @@
|
|
if (metric->real()) {
|
|
if (descFlag)
|
|
if (niceFlag)
|
|
- cout << setw(width)
|
|
+ std::cout << std::setw(width)
|
|
<< PMC_Metric::formatNumber(value);
|
|
else
|
|
- cout << PMC_Metric::formatNumber(value);
|
|
+ std::cout << PMC_Metric::formatNumber(value);
|
|
else if (niceFlag)
|
|
- cout << setw(width) << value;
|
|
+ std::cout << std::setw(width) << value;
|
|
else
|
|
- cout << value;
|
|
+ std::cout << value;
|
|
}
|
|
// String
|
|
else {
|
|
@@ -1325,13 +1325,13 @@
|
|
width - 2);
|
|
buffer[width - 1] = '\"';
|
|
buffer[width] = '\0';
|
|
- cout << setw(width) << buffer;
|
|
+ std::cout << std::setw(width) << buffer;
|
|
}
|
|
else {
|
|
strcpy(buffer+1, metric->strValue(i).ptr());
|
|
buffer[l + 1] = '\"';
|
|
buffer[l + 2] = '\0';
|
|
- cout << setw(width) << buffer;
|
|
+ std::cout << std::setw(width) << buffer;
|
|
}
|
|
}
|
|
else if (widthFlag) {
|
|
@@ -1340,28 +1340,28 @@
|
|
width - 5);
|
|
strcpy(buffer + width - 4, "...\"");
|
|
buffer[width] = '\0';
|
|
- cout << setw(width) << buffer;
|
|
+ std::cout << std::setw(width) << buffer;
|
|
}
|
|
else {
|
|
strncpy(buffer+1, metric->strValue(i).ptr(),
|
|
width - 2);
|
|
buffer[width - 1] = '\"';
|
|
buffer[width] = '\0';
|
|
- cout << setw(width) << buffer;
|
|
+ std::cout << std::setw(width) << buffer;
|
|
}
|
|
}
|
|
else
|
|
- cout << '\"' << metric->strValue(i) << '\"';
|
|
+ std::cout << '\"' << metric->strValue(i) << '\"';
|
|
}
|
|
|
|
next:
|
|
if (v < numValues) {
|
|
- cout << delimiter;
|
|
+ std::cout << delimiter;
|
|
v++;
|
|
}
|
|
}
|
|
}
|
|
- cout << endl;
|
|
+ std::cout << std::endl;
|
|
|
|
position.tv_sec += interval.tv_sec;
|
|
position.tv_usec += interval.tv_usec;
|
|
@@ -1373,7 +1373,7 @@
|
|
if (diff < 0.0) { // We missed an update
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL0) {
|
|
- cerr << "Need to slip " << -diff << " seconds" << endl;
|
|
+ std::cerr << "Need to slip " << -diff << " seconds" << std::endl;
|
|
}
|
|
#endif
|
|
do {
|
|
@@ -1385,7 +1385,7 @@
|
|
|
|
#ifdef PCP_DEBUG
|
|
if (pmDebug & DBG_TRACE_APPL1) {
|
|
- cerr << "Napping for " << diff << " seconds" << endl;
|
|
+ std::cerr << "Napping for " << diff << " seconds" << std::endl;
|
|
}
|
|
#endif
|
|
sginap((long)(diff * (double)CLK_TCK));
|
|
@@ -1394,7 +1394,7 @@
|
|
pos = __pmtimevalToReal(&position);
|
|
lines++;
|
|
if (repeatLines > 0 && repeatLines == lines) {
|
|
- cout << endl;
|
|
+ std::cout << std::endl;
|
|
dumpHeader();
|
|
lines = 0;
|
|
}
|