8000 Revert "[Profiler] Give non-zero default values to start events (#149… · pytorch/pytorch@3b00ff8 · GitHub
[go: up one dir, main page]

Skip to content

Commit 3b00ff8

Browse files
Revert "[Profiler] Give non-zero default values to start events (#149757)"
This reverts commit bc72420. Reverted #149757 on behalf of https://github.com/malfet due to Broke windows builds, which were also the signal on the HUD ([comment](#149757 (comment)))
1 parent f3c77b2 commit 3b00ff8

File tree

1 file changed

+2
-11
lines changed

1 file changed

+2
-11
lines changed

torch/csrc/autograd/profiler_python.cpp

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,6 @@
1313
#include <Python.h>
1414
#include <frameobject.h>
1515

16-
#ifdef USE_KINETO
17-
#include <libkineto.h>
18-
#endif
19-
2016
#include <ATen/core/TensorBase.h>
2117
#include <c10/macros/Macros.h>
2218
#include <c10/util/ApproximateClock.h>
@@ -1033,14 +1029,9 @@ class PostProcess {
10331029
const auto python_tid =
10341030
std::get<ExtraFields<E>>((*it)->extra_fields_).python_tid_;
10351031
if ((*it)->start_tid_ == NoTID && SOFT_ASSERT(E == EventType::PyCall)) {
1036-
#ifdef USE_KINETO
1037-
kineto::DeviceAndResource info = {
1038-
libkineto::processId(), libkineto::systemThreadId()};
1039-
#else
1040-
kineto::DeviceAndResource info = kineto::DeviceAndResource();
1041-
#endif // USE_KINETO
10421032
const auto& tid_info =
1043-
tid_map.insert({python_tid, {NoTID, info}}).first->second;
1033+
tid_map.insert({python_tid, {NoTID, kineto::DeviceAndResource()}})
1034+
.first->second;
10441035
(*it)->start_tid_ = tid_info.first;
10451036
(*it)->kineto_info_ = tid_info.second;
10461037
}

0 commit comments

Comments
 (0)
0