From: Chao Liu <lc00631@tecorigin.com>
To: pbonzini@redhat.com, peterx@redhat.com, david@redhat.com,
philmd@linaro.org, armbru@redhat.com, balaton@eik.bme.hu
Cc: zhangtj@tecorigin.com, zqz00548@tecorigin.com,
lc00631@tecorigin.com, qemu-devel@nongnu.org
Subject: [PATCH v4 0/1] Optimizing the print format of the QEMU monitor 'info mtree'
Date: Thu, 1 May 2025 00:32:57 +0800 [thread overview]
Message-ID: <cover.1746028446.git.lc00631@tecorigin.com> (raw)
Hi, all:
Thanks to Markus, BALATON, and Philippe for their reviews
In PATCH v4,
I have extensively incorporated everyone's suggestions and made the
following improvements:
1. When printing the child nodes of a single node, the line characters from the
parent node's level are no longer printed, making the output more concise
and clear overall;
2. Use more commonly used ASCII characters, such as '|--' instead of '├──',
and '`--' instead of '└──';
3. Control the number of prefix characters to reduce unnecessary output;
The result is as follows:
```
$ ./qemu-system-aarch64 -S -monitor stdio -M raspi4b
(qemu) info mtree
address-space: memory
`-- 0000000000000000-ffffffffffffffff (prio 0, i/o): system
|-- 0000000000000000-000000007fffffff (prio 0, ram): ram
...
|-- 00000000fe000000-00000000ff7fffff (prio 1, i/o): bcm2835-peripherals
| |-- 00000000fe900000-00000000fe907fff (prio -1000, i/o): bcm2835-dbus
| |-- 00000000fe910000-00000000fe917fff (prio -1000, i/o): bcm2835-ave0
| |-- 00000000fe980000-00000000fe990fff (prio 0, i/o): dwc2
| | |-- 00000000fe980000-00000000fe980fff (prio 0, i/o): dwc2-io
| | `-- 00000000fe981000-00000000fe990fff (prio 0, i/o): dwc2-fifo
| |-- 00000000fec00000-00000000fec00fff (prio -1000, i/o): bcm2835-v3d
| |-- 00000000fec11000-00000000fec110ff (prio -1000, i/o): bcm2835-clkisp
| |-- 00000000fee00000-00000000fee000ff (prio -1000, i/o): bcm2835-sdramc
| `-- 00000000fee05000-00000000fee050ff (prio 0, i/o): bcm2835-dma-chan15
|-- 00000000ff800000-00000000ff8000ff (prio 0, i/o): bcm2836-control
...
|-- 00000000ff845600-00000000ff8456ff (prio 0, i/o): gic_cpu
`-- 00000000ff846000-00000000ff847fff (prio 0, i/o): gic_vcpu
```
PATCH v3 changelog:
1.Use more maintainable c functions instead of macros, as per review comments.
PATCH v2 changelog:
1. Enrich the commit message, add 'info mtree' print example.
2. Optimize the code implementation according to the review comments.
PATCH v3:
https://lore.kernel.org/qemu-devel/15227d0a-c459-4bea-bec7-13dc88d22c3c@linaro.org/
PATCH v2:
https://lore.kernel.org/qemu-devel/72b2d911-112e-48e3-9ba4-017a11758060@linaro.org/
https://lore.kernel.org/qemu-devel/7ec1e581-3919-fdf5-499a-279cba99d43d@eik.bme.hu/
https://lore.kernel.org/qemu-devel/874iy5d9v7.fsf@pond.sub.org/
PATCH v1:
https://lore.kernel.org/qemu-devel/210c69d9-803e-41a5-b40c-bc8372e582fa@redhat.com/
--
Regards,
Chao
Chao Liu (1):
system: improve visual representation of node hierarchy in 'info
mtree' output for qemu monitor
system/memory.c | 122 +++++++++++++++++++++++++++++++++++++++++++-----
1 file changed, 111 insertions(+), 11 deletions(-)
--
2.48.1
reply other threads:[~2025-04-30 16:33 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=cover.1746028446.git.lc00631@tecorigin.com \
--to=lc00631@tecorigin.com \
--cc=armbru@redhat.com \
--cc=balaton@eik.bme.hu \
--cc=david@redhat.com \
--cc=pbonzini@redhat.com \
--cc=peterx@redhat.com \
--cc=philmd@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=zhangtj@tecorigin.com \
--cc=zqz00548@tecorigin.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.