qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 19/29] disas: use QEMU_IS_ALIGNED macro


From: Michael Tokarev
Subject: Re: [Qemu-devel] [PATCH 19/29] disas: use QEMU_IS_ALIGNED macro
Date: Tue, 18 Jul 2017 14:09:54 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0

18.07.2017 09:09, Philippe Mathieu-Daudé wrote:

> @@ -151,7 +151,7 @@ static int print_insn_objdump(bfd_vma pc, 
> disassemble_info *info,
>      info->read_memory_func(pc, buf, n, info);
>  
>      for (i = 0; i < n; ++i) {
> -        if (i % 32 == 0) {
> +        if (QEMU_IS_ALIGNED(i, 32)) {
>              info->fprintf_func(info->stream, "\n%s: ", prefix);
>          }
>          info->fprintf_func(info->stream, "%02x", buf[i]);

This does not seem to be related to _alignment_ per se, it is
just formatting, 32 entries per line, so that output looks
more-or less compact and stays readable.  To me it is a
strange move, not so much logical.

It doesn't matter much either way, but with IS_ALIGNED, to me
at least, it looks a bit less logical than now.

Thanks,

/mjt




reply via email to

[Prev in Thread] Current Thread [Next in Thread]