File tree 2 files changed +8
-9
lines changed
2 files changed +8
-9
lines changed Original file line number Diff line number Diff line change @@ -4001,7 +4001,7 @@ class ZeCollector {
4001
4001
}
4002
4002
4003
4003
void AggregateDeviceTimeStats () const {
4004
- // do not acquire global_device_time_stats_mutex_. caller dos it.
4004
+ // do not acquire global_device_time_stats_mutex_. caller does it.
4005
4005
for (auto it = global_device_time_stats_->begin (); it != global_device_time_stats_->end (); it++) {
4006
4006
std::string kname;
4007
4007
if (it->first .tile_ >= 0 ) {
Original file line number Diff line number Diff line change @@ -203,6 +203,13 @@ class UniTracer {
203
203
~UniTracer () {
204
204
total_execution_time_ = correlator_.GetTimestamp ();
205
205
206
+ if (ze_collector_ != nullptr ) {
207
+ ze_collector_->DisableTracing ();
208
+ delete ze_collector_;
209
+ }
210
+
211
+ // report after ze_collector_ is destructed
212
+ // local stats are sweeped in deconstructor
206
213
Report ();
207
214
208
215
ClExtCollector::Destroy ();
@@ -213,14 +220,6 @@ class UniTracer {
213
220
cl_gpu_collector_->DisableTracing ();
214
221
}
215
222
216
- if (ze_collector_ != nullptr ) {
217
- ze_collector_->DisableTracing ();
218
- }
219
-
220
- if (ze_collector_ != nullptr ) {
221
- delete ze_collector_;
222
- }
223
-
224
223
if (itt_collector != nullptr ){
225
224
// Print CCL summary before deleting the object
226
225
// If CCL summary is not enbled summary string will be empty
You can’t perform that action at this time.
0 commit comments