[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [Qemu-block] [PATCH 02/17] trace: Show blockjob actions
From: |
Eric Blake |
Subject: |
Re: [Qemu-devel] [Qemu-block] [PATCH 02/17] trace: Show blockjob actions via bytes, not sectors |
Date: |
Mon, 17 Apr 2017 14:55:53 -0500 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.0 |
On 04/17/2017 02:18 PM, John Snow wrote:
>> @@ -346,13 +349,15 @@ static uint64_t coroutine_fn
>> mirror_iteration(MirrorBlockJob *s)
>> if (sector_num < 0) {
>> bdrv_set_dirty_iter(s->dbi, 0);
>> sector_num = bdrv_dirty_iter_next(s->dbi);
>> - trace_mirror_restart_iter(s, bdrv_get_dirty_count(s->dirty_bitmap));
>> + trace_mirror_restart_iter(s, bdrv_get_dirty_count(s->dirty_bitmap) *
>> + BDRV_SECTOR_SIZE);
>
> mirror_restart_iter(void *s, int64_t cnt) "s %p dirty count %"PRId64
>
> I guess the print doesn't really bother to say what the unit is, just a
> "dirty count."
>
> Does this conflict with the bitmap series, though? (Won't need to scale
> by BDRV_SECTOR_SIZE after that, I think.)
>
That series depends on this one going in first (as currently written),
and indeed, in that series, the code DOES simplify to drop the '*
BDRV_SECTOR_SIZE' in the patch that changes the return scale of
bdrv_get_dirty_count().
>> backup_do_cow_skip(void *job, int64_t start) "job %p start %"PRId64
>> backup_do_cow_process(void *job, int64_t start) "job %p start %"PRId64
>> backup_do_cow_read_fail(void *job, int64_t start, int ret) "job %p start
>> %"PRId64" ret %d"
>
> I guess these three were "cluster" based, but you didn't need to change
> anything to assert them as byte-based.
>
>>
>
> Under the assumption that it's okay to change tracing output without
> being able to differentiate between new and old output:
I'll leave that to Stefan's discretion as trace maintainer, but my
thoughts are that tracing is for debugging purposes, and as long as you
know what binary you are debugging, you can figure out what the trace
message meant by referring back to the source that generated that binary.
>
> Reviewed-by: John Snow <address@hidden>
>
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization: qemu.org | libvirt.org
signature.asc
Description: OpenPGP digital signature
- [Qemu-devel] [PATCH 00/17] make bdrv_is_allocated[_above] byte-based, Eric Blake, 2017/04/11
- [Qemu-devel] [PATCH 01/17] blockjob: Track job ratelimits via bytes, not sectors, Eric Blake, 2017/04/11
- [Qemu-devel] [PATCH 03/17] stream: Switch stream_populate() to byte-based, Eric Blake, 2017/04/11
- [Qemu-devel] [PATCH 04/17] stream: Switch stream_run() to byte-based, Eric Blake, 2017/04/11
- [Qemu-devel] [PATCH 02/17] trace: Show blockjob actions via bytes, not sectors, Eric Blake, 2017/04/11
- [Qemu-devel] [PATCH 05/17] commit: Switch commit_populate() to byte-based, Eric Blake, 2017/04/11
- [Qemu-devel] [PATCH 06/17] commit: Switch commit_run() to byte-based, Eric Blake, 2017/04/11
- [Qemu-devel] [PATCH 08/17] mirror: Switch mirror_do_zero_or_discard() to byte-based, Eric Blake, 2017/04/11
- [Qemu-devel] [PATCH 07/17] mirror: Switch MirrorBlockJob to byte-based, Eric Blake, 2017/04/11
- [Qemu-devel] [PATCH 09/17] mirror: Switch mirror_cow_align() to byte-based, Eric Blake, 2017/04/11
- [Qemu-devel] [PATCH 10/17] mirror: Switch mirror_do_read() to byte-based, Eric Blake, 2017/04/11
- [Qemu-devel] [PATCH 11/17] mirror: Switch mirror_iteration() to byte-based, Eric Blake, 2017/04/11
- [Qemu-devel] [PATCH 12/17] backup: Switch BackupBlockJob to byte-based, Eric Blake, 2017/04/11
- [Qemu-devel] [PATCH 15/17] backup: Switch backup_run() to byte-based, Eric Blake, 2017/04/11