From: Jens Axboe <axboe@kernel.dk>
To: <linux-btrace@vger.kernel.org>
Subject: Recent changes (master)
Date: Wed, 9 Oct 2024 06:00:02 -0600 (MDT) [thread overview]
Message-ID: <20241009120002.132AE1BC014D@kernel.dk> (raw)
The following changes since commit 1836be5d99c9362f1e2b39206c95270f19cb7faa:
fix hang when BLKTRACESETUP fails and "-o -" is used (2024-06-12 14:45:58 -0600)
are available in the Git repository at:
git://git.kernel.dk/blktrace.git master
for you to fetch changes up to f49e7ded6405bcecd10846a614f40061ca6301c8:
iowatcher: Calculate ios_in_flight per trace (2024-10-08 07:40:39 -0600)
----------------------------------------------------------------
Igor Pylypiv (1):
iowatcher: Calculate ios_in_flight per trace
iowatcher/blkparse.c | 13 ++++++-------
iowatcher/blkparse.h | 1 +
2 files changed, 7 insertions(+), 7 deletions(-)
---
Diff of recent changes:
diff --git a/iowatcher/blkparse.c b/iowatcher/blkparse.c
index 6203854..0518083 100644
--- a/iowatcher/blkparse.c
+++ b/iowatcher/blkparse.c
@@ -41,7 +41,6 @@
#define IO_HASH_TABLE_BITS 11
#define IO_HASH_TABLE_SIZE (1 << IO_HASH_TABLE_BITS)
static struct list_head io_hash_table[IO_HASH_TABLE_SIZE];
-static u64 ios_in_flight = 0;
#define PROCESS_HASH_TABLE_BITS 7
#define PROCESS_HASH_TABLE_SIZE (1 << PROCESS_HASH_TABLE_BITS)
@@ -1037,8 +1036,8 @@ void add_pending_io(struct trace *trace, struct graph_line_data *gld)
return;
}
if (action == __BLK_TA_REQUEUE) {
- if (ios_in_flight > 0)
- ios_in_flight--;
+ if (trace->ios_in_flight > 0)
+ trace->ios_in_flight--;
return;
}
if (action != __BLK_TA_ISSUE)
@@ -1054,10 +1053,10 @@ void add_pending_io(struct trace *trace, struct graph_line_data *gld)
}
account_io:
- ios_in_flight++;
+ trace->ios_in_flight++;
seconds = SECONDS(io->time);
- gld->data[seconds].sum += ios_in_flight;
+ gld->data[seconds].sum += trace->ios_in_flight;
gld->data[seconds].count++;
avg = (double)gld->data[seconds].sum / gld->data[seconds].count;
@@ -1088,8 +1087,8 @@ void add_completed_io(struct trace *trace,
if (!pio)
return;
- if (ios_in_flight > 0)
- ios_in_flight--;
+ if (trace->ios_in_flight > 0)
+ trace->ios_in_flight--;
if (io->time >= pio->dispatch_time) {
latency = io->time - pio->dispatch_time;
latency_gld->data[seconds].sum += latency;
diff --git a/iowatcher/blkparse.h b/iowatcher/blkparse.h
index fce9d01..f828763 100644
--- a/iowatcher/blkparse.h
+++ b/iowatcher/blkparse.h
@@ -57,6 +57,7 @@ struct trace {
int mpstat_fd;
int mpstat_seconds;
int mpstat_num_cpus;
+ u64 ios_in_flight;
char *fio_start;
char *fio_cur;
next reply other threads:[~2024-10-09 12:00 UTC|newest]
Thread overview: 45+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-09 12:00 Jens Axboe [this message]
-- strict thread matches above, loose matches on Subject: below --
2025-12-11 13:00 Recent changes (master) Jens Axboe
2025-03-20 12:00 Jens Axboe
2025-01-31 13:00 Jens Axboe
2024-06-13 12:00 Jens Axboe
2024-01-18 13:00 Jens Axboe
2013-03-20 5:00 Jens Axboe
2013-08-02 4:00 ` Jens Axboe
2013-12-04 4:56 ` Jens Axboe
2014-04-12 12:00 ` Jens Axboe
2014-09-09 12:00 ` Jens Axboe
2014-09-26 12:00 ` Jens Axboe
2015-02-19 13:00 ` Jens Axboe
2015-08-21 12:00 ` Jens Axboe
2015-09-16 12:00 ` Jens Axboe
2016-01-09 13:00 ` Jens Axboe
2016-02-10 13:00 ` Jens Axboe
2016-04-26 12:00 ` Jens Axboe
2016-05-04 12:00 ` Jens Axboe
2016-05-06 12:00 ` Jens Axboe
2016-05-20 12:00 ` Jens Axboe
2016-08-24 12:00 ` Jens Axboe
2017-01-27 13:00 ` Jens Axboe
2017-11-05 13:00 ` Jens Axboe
2017-11-06 13:00 ` Jens Axboe
2017-11-08 13:00 ` Jens Axboe
2018-01-24 13:00 ` Jens Axboe
2018-01-25 13:00 ` Jens Axboe
2018-04-10 12:00 ` Jens Axboe
2018-05-03 12:00 ` Jens Axboe
2018-05-17 12:00 ` Jens Axboe
2018-08-31 12:00 ` Jens Axboe
2018-09-01 12:00 ` Jens Axboe
2019-05-22 12:00 ` Jens Axboe
2019-09-17 12:00 ` Jens Axboe
2019-09-25 12:00 ` Jens Axboe
2020-01-17 13:00 ` Jens Axboe
2020-03-21 12:00 ` Jens Axboe
2020-05-08 12:00 ` Jens Axboe
2020-05-21 12:00 ` Jens Axboe
2021-02-20 13:00 ` Jens Axboe
2021-04-20 12:00 ` Jens Axboe
2021-06-15 11:59 ` Jens Axboe
2021-06-29 12:00 ` Jens Axboe
2021-10-22 12:00 ` Jens Axboe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20241009120002.132AE1BC014D@kernel.dk \
--to=axboe@kernel.dk \
--cc=linux-btrace@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).