From 1b90d57764a15e07bba08a18801aa8307dc11bd5 Mon Sep 17 00:00:00 2001 From: lisali Date: Fri, 18 Aug 2017 09:51:35 -0400 Subject: [PATCH] os/bluestore: Add lat record of deferred_queued and deferred_aio_wait Originally bluestore defines the two lat deferred_queued_lat and deferred_aio_wait_lat, but doesn't use it. This patch is to add the records that each TXC stays on deferred queue deferred ios. Signed-off-by: Xiaoyan Li xiaoyan.li@intel.com --- src/os/bluestore/BlueStore.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/os/bluestore/BlueStore.cc b/src/os/bluestore/BlueStore.cc index e74ea82c1a79f..5e7628b66c8ab 100644 --- a/src/os/bluestore/BlueStore.cc +++ b/src/os/bluestore/BlueStore.cc @@ -8628,6 +8628,9 @@ void BlueStore::_deferred_submit_unlock(OpSequencer *osr) assert(!osr->deferred_running); auto b = osr->deferred_pending; + for (auto& txc : b->txcs) { + txc.log_state_latency(logger, l_bluestore_state_deferred_queued_lat); + } deferred_queue_size -= b->seq_bytes.size(); assert(deferred_queue_size >= 0); @@ -8700,6 +8703,7 @@ void BlueStore::_deferred_aio_finish(OpSequencer *osr) std::lock_guard l2(osr->qlock); for (auto& i : b->txcs) { TransContext *txc = &i; + txc->log_state_latency(logger, l_bluestore_state_deferred_aio_wait_lat); txc->state = TransContext::STATE_DEFERRED_CLEANUP; costs += txc->cost; } -- 2.39.5