| 110 | } |
| 111 | |
| 112 | void Profiler::end(const OperatorInfo* info) { |
| 113 | mEndTime = getTime(); |
| 114 | float cost = (float)(mEndTime - mStartTime) / 1000.0f; |
| 115 | mMapByType[info->type()].costTime += cost; |
| 116 | mMapByName[info->name()].costTime += cost; |
| 117 | mTotalTime += cost; |
| 118 | } |
| 119 | |
| 120 | static void printTable(const char* title, const std::vector<std::string>& header, |
| 121 | const std::vector<std::vector<std::string>>& data) { |