Impala
Impalaistheopensource,nativeanalyticdatabaseforApacheHadoop.
|
#include <stopwatch.h>
Public Member Functions | |
MonotonicStopWatch () | |
void | Start () |
void | Stop () |
uint64_t | Reset () |
Restarts the timer. Returns the elapsed time until this point. More... | |
uint64_t | ElapsedTime () const |
Returns time in nanosecond. More... | |
Private Attributes | |
timespec | start_ |
uint64_t | total_time_ |
bool | running_ |
Stop watch for reporting elapsed time in nanosec based on CLOCK_MONOTONIC. It is as fast as Rdtsc. It is also accurate because it not affected by cpu frequency changes and it is not affected by user setting the system clock. CLOCK_MONOTONIC represents monotonic time since some unspecified starting point. It is good for computing elapsed time.
Definition at line 74 of file stopwatch.h.
|
inline |
Definition at line 76 of file stopwatch.h.
References running_, and total_time_.
|
inline |
Returns time in nanosecond.
Definition at line 105 of file stopwatch.h.
References running_, start_, and total_time_.
Referenced by impala::Webserver::BeginRequestCallback(), impala::BlockingQueue< TRowBatch * >::BlockingGet(), impala::BlockingQueue< TRowBatch * >::BlockingPut(), impala::RuntimeProfile::EventSequence::ElapsedTime(), impala::ResourceBroker::Expand(), impala::PlanFragmentExecutor::FragmentComplete(), impala::CatalogServer::GatherCatalogUpdatesThread(), HandleBroadcast(), impala::ResourceBroker::LlamaRpc(), impala::RuntimeProfile::EventSequence::MarkEvent(), impala::StatestoreSubscriber::RecoveryModeChecker(), impala::ResourceBroker::Reserve(), Reset(), Send(), impala::Statestore::SendHeartbeat(), impala::Statestore::SendTopicUpdate(), Stop(), impala::ThreadCounterMeasurement::Stop(), impala::StatestoreSubscriber::UpdateState(), and impala::ParallelExecutor::Worker().
|
inline |
Restarts the timer. Returns the elapsed time until this point.
Definition at line 96 of file stopwatch.h.
References ElapsedTime(), running_, and start_.
Referenced by impala::StatestoreSubscriber::Heartbeat(), and impala::StatestoreSubscriber::UpdateState().
|
inline |
Definition at line 81 of file stopwatch.h.
References running_, and start_.
Referenced by impala::Webserver::BeginRequestCallback(), impala::BlockingQueue< TRowBatch * >::BlockingGet(), impala::BlockingQueue< TRowBatch * >::BlockingPut(), impala::ResourceBroker::Expand(), impala::CatalogServer::GatherCatalogUpdatesThread(), HandleBroadcast(), impala::ResourceBroker::LlamaRpc(), impala::PlanFragmentExecutor::Prepare(), impala::StatestoreSubscriber::RecoveryModeChecker(), impala::StatestoreSubscriber::Register(), impala::ResourceBroker::Reserve(), Send(), impala::Statestore::SendHeartbeat(), impala::Statestore::SendTopicUpdate(), impala::RuntimeProfile::EventSequence::Start(), impala::ThreadCounterMeasurement::ThreadCounterMeasurement(), impala::StatestoreSubscriber::UpdateState(), and impala::ParallelExecutor::Worker().
|
inline |
Definition at line 88 of file stopwatch.h.
References ElapsedTime(), running_, and total_time_.
Referenced by impala::BlockingQueue< TRowBatch * >::BlockingGet(), impala::BlockingQueue< TRowBatch * >::BlockingPut(), impala::PlanFragmentExecutor::FragmentComplete(), HandleBroadcast(), Send(), impala::ThreadCounterMeasurement::Stop(), and impala::StatestoreSubscriber::UpdateState().
|
private |
Definition at line 116 of file stopwatch.h.
Referenced by ElapsedTime(), MonotonicStopWatch(), Reset(), Start(), and Stop().
|
private |
Definition at line 114 of file stopwatch.h.
Referenced by ElapsedTime(), Reset(), and Start().
|
private |
Definition at line 115 of file stopwatch.h.
Referenced by ElapsedTime(), MonotonicStopWatch(), and Stop().