comparison base/Profiler.cpp @ 1042:16dc7307d43a cxx11

More build fixes
author Chris Cannam
date Wed, 04 Mar 2015 13:52:48 +0000
parents e802e550a1f2
children c811991a5efa
comparison
equal deleted inserted replaced
1041:843f67be0ed9 1042:16dc7307d43a
103 fprintf(stderr, "%s(%d):\n", *i, pp.first); 103 fprintf(stderr, "%s(%d):\n", *i, pp.first);
104 104
105 fprintf(stderr, "\tCPU: \t%.9g ms/call \t[%d ms total]\n", 105 fprintf(stderr, "\tCPU: \t%.9g ms/call \t[%d ms total]\n",
106 (((double)pp.second.first * 1000.0 / 106 (((double)pp.second.first * 1000.0 /
107 (double)pp.first) / CLOCKS_PER_SEC), 107 (double)pp.first) / CLOCKS_PER_SEC),
108 int((pp.second.first * 1000.0) / CLOCKS_PER_SEC)); 108 int((double(pp.second.first) * 1000.0) / CLOCKS_PER_SEC));
109 109
110 fprintf(stderr, "\tReal: \t%s ms \t[%s ms total]\n", 110 fprintf(stderr, "\tReal: \t%s ms \t[%s ms total]\n",
111 ((pp.second.second / pp.first) * 1000).toString().c_str(), 111 ((pp.second.second / pp.first) * 1000).toString().c_str(),
112 (pp.second.second * 1000).toString().c_str()); 112 (pp.second.second * 1000).toString().c_str());
113 113
116 116
117 const TimePair &wc(k->second); 117 const TimePair &wc(k->second);
118 118
119 fprintf(stderr, "\tWorst:\t%s ms/call \t[%d ms CPU]\n", 119 fprintf(stderr, "\tWorst:\t%s ms/call \t[%d ms CPU]\n",
120 (wc.second * 1000).toString().c_str(), 120 (wc.second * 1000).toString().c_str(),
121 int((wc.first * 1000.0) / CLOCKS_PER_SEC)); 121 int((double(wc.first) * 1000.0) / CLOCKS_PER_SEC));
122 } 122 }
123 123
124 typedef std::multimap<RealTime, const char *> TimeRMap; 124 typedef std::multimap<RealTime, const char *> TimeRMap;
125 typedef std::multimap<int, const char *> IntRMap; 125 typedef std::multimap<int, const char *> IntRMap;
126 126