File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 1
- /* Copyright 2020 The TensorFlow Authors. All Rights Reserved.
1
+ /* Copyright 2025 The TensorFlow Authors. All Rights Reserved.
2
2
3
3
Licensed under the Apache License, Version 2.0 (the "License");
4
4
you may not use this file except in compliance with the License.
@@ -14,9 +14,11 @@ limitations under the License.
14
14
==============================================================================*/
15
15
#include " tensorflow/lite/micro/micro_profiler.h"
16
16
17
+ #include < algorithm>
17
18
#include < cinttypes>
18
19
#include < cstdint>
19
20
#include < cstring>
21
+ #include < iterator>
20
22
21
23
#include " tensorflow/lite/kernels/internal/compatibility.h"
22
24
#include " tensorflow/lite/micro/micro_log.h"
@@ -122,9 +124,7 @@ int MicroProfiler::FindExistingOrNextPosition(const char* tag_name) {
122
124
}
123
125
124
126
void MicroProfiler::ClearEvents () {
125
- for (int i = 0 ; i < num_events_; i++) {
126
- total_ticks_per_tag_[i].tag = nullptr ;
127
- }
127
+ std::fill_n (std::begin (total_ticks_per_tag_), num_events_, TicksPerTag{});
128
128
129
129
num_events_ = 0 ;
130
130
}
You can’t perform that action at this time.
0 commit comments