diff options
author | wolfbeast <mcwerewolf@gmail.com> | 2018-09-04 20:53:31 +0200 |
---|---|---|
committer | wolfbeast <mcwerewolf@gmail.com> | 2018-09-04 20:53:31 +0200 |
commit | 580084e9e1d0355c96a54a9641df6c1fee894948 (patch) | |
tree | 5aff416b5aed2ca9e326054567d837f28c20ed25 /netwerk/base/Predictor.cpp | |
parent | fc61780b35af913801d72086456f493f63197da6 (diff) | |
parent | b28ab55f9675f2e97dda9a4fcac0d4f5267a2bb9 (diff) | |
download | UXP-2018.09.05.tar UXP-2018.09.05.tar.gz UXP-2018.09.05.tar.lz UXP-2018.09.05.tar.xz UXP-2018.09.05.zip |
Merge branch 'master' into Basilisk-releasev2018.09.05
Diffstat (limited to 'netwerk/base/Predictor.cpp')
-rw-r--r-- | netwerk/base/Predictor.cpp | 26 |
1 files changed, 1 insertions, 25 deletions
diff --git a/netwerk/base/Predictor.cpp b/netwerk/base/Predictor.cpp index e97b11d16..12e4eb415 100644 --- a/netwerk/base/Predictor.cpp +++ b/netwerk/base/Predictor.cpp @@ -294,26 +294,9 @@ Predictor::Action::OnCacheEntryAvailable(nsICacheEntry *entry, bool isNew, "Aborting.", this, result)); return NS_OK; } - Telemetry::AccumulateTimeDelta(Telemetry::PREDICTOR_WAIT_TIME, - mStartTime); - if (mPredict) { - bool predicted = mPredictor->PredictInternal(mPredictReason, entry, isNew, - mFullUri, mTargetURI, - mVerifier, mStackCount); - Telemetry::AccumulateTimeDelta( - Telemetry::PREDICTOR_PREDICT_WORK_TIME, mStartTime); - if (predicted) { - Telemetry::AccumulateTimeDelta( - Telemetry::PREDICTOR_PREDICT_TIME_TO_ACTION, mStartTime); - } else { - Telemetry::AccumulateTimeDelta( - Telemetry::PREDICTOR_PREDICT_TIME_TO_INACTION, mStartTime); - } - } else { + if (!mPredict) { mPredictor->LearnInternal(mLearnReason, entry, isNew, mFullUri, mTargetURI, mSourceURI); - Telemetry::AccumulateTimeDelta( - Telemetry::PREDICTOR_LEARN_WORK_TIME, mStartTime); } return NS_OK; @@ -1073,8 +1056,6 @@ Predictor::CalculateGlobalDegradation(uint32_t lastLoad) globalDegradation = mPageDegradationMax; } - Telemetry::Accumulate(Telemetry::PREDICTOR_GLOBAL_DEGRADATION, - globalDegradation); return globalDegradation; } @@ -1139,10 +1120,6 @@ Predictor::CalculateConfidence(uint32_t hitCount, uint32_t hitsPossible, confidence = std::max(confidence, 0); confidence = std::min(confidence, maxConfidence); - Telemetry::Accumulate(Telemetry::PREDICTOR_BASE_CONFIDENCE, baseConfidence); - Telemetry::Accumulate(Telemetry::PREDICTOR_SUBRESOURCE_DEGRADATION, - confidenceDegradation); - Telemetry::Accumulate(Telemetry::PREDICTOR_CONFIDENCE, confidence); return confidence; } @@ -2335,7 +2312,6 @@ Predictor::PrefetchListener::OnStopRequest(nsIRequest *aRequest, if (NS_FAILED(aStatusCode)) { return aStatusCode; } - Telemetry::AccumulateTimeDelta(Telemetry::PREDICTOR_PREFETCH_TIME, mStartTime); nsCOMPtr<nsIHttpChannel> httpChannel = do_QueryInterface(aRequest); if (!httpChannel) { |