diff options
author | dziana.hurynovich <dziana.hurynovich@mongodb.com> | 2023-01-30 10:24:43 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2023-01-30 11:09:50 +0000 |
commit | b1195b271c5944cd9b68763b91697828f5cda58b (patch) | |
tree | 9790a08345e343a016e835f2b86a7cc58a2bab5e /src/mongo/db/curop.h | |
parent | 0de85d50a1d7a1c3b3f2dd73145b7dd55b37b56a (diff) | |
download | mongo-b1195b271c5944cd9b68763b91697828f5cda58b.tar.gz |
Revert "SERVER-70032 Report CPU time in slow query logs and profiler as cpuNanos"
This reverts commit 0d5ad158ceb6fea1004034bcb78c82c9daf69eac.
Diffstat (limited to 'src/mongo/db/curop.h')
-rw-r--r-- | src/mongo/db/curop.h | 19 |
1 files changed, 5 insertions, 14 deletions
diff --git a/src/mongo/db/curop.h b/src/mongo/db/curop.h index a0cd46a4e0e..e939e22ff9c 100644 --- a/src/mongo/db/curop.h +++ b/src/mongo/db/curop.h @@ -297,11 +297,6 @@ public: // response info Microseconds executionTime{0}; - - // Amount of CPU time used by this thread. Will remain zero if this platform does not support - // this feature. - Nanoseconds cpuTime{0}; - long long nreturned{-1}; int responseLength{-1}; @@ -458,8 +453,8 @@ public: return _originatingCommand; } - void enter_inlock(OperationContext* opCtx, NamespaceString nss, int dbProfileLevel); - void enter_inlock(OperationContext* opCtx, const DatabaseName& dbName, int dbProfileLevel); + void enter_inlock(NamespaceString nss, int dbProfileLevel); + void enter_inlock(const DatabaseName& dbName, int dbProfileLevel); /** * Sets the type of the current network operation. @@ -580,8 +575,8 @@ public: // negative, if the system time has been reset during the course of this operation. // - void ensureStarted(OperationContext* opCtx) { - static_cast<void>(startTime(opCtx)); + void ensureStarted() { + static_cast<void>(startTime()); } bool isStarted() const { return _start.load() != 0; @@ -886,7 +881,7 @@ public: private: class CurOpStack; - TickSource::Tick startTime(OperationContext* opCtx); + TickSource::Tick startTime(); Microseconds computeElapsedTimeTotal(TickSource::Tick startTime, TickSource::Tick endTime) const; @@ -915,10 +910,6 @@ private: // The time at which this CurOp instance was marked as done or 0 if the CurOp is not yet done. std::atomic<TickSource::Tick> _end{0}; // NOLINT - // This CPU timer tracks the CPU time spent for this operation. Will be nullptr on unsupported - // platforms. - std::unique_ptr<OperationCPUTimer> _cpuTimer; - // The time at which this CurOp instance had its timer paused, or 0 if the timer is not // currently paused. TickSource::Tick _lastPauseTime{0}; |