From: "Daniel P. Berrangé" <berrange@redhat.com>
To: Richard Henderson <richard.henderson@linaro.org>
Cc: qemu-devel@nongnu.org
Subject: Re: [RFC 0/4] util: qmessage_context followup
Date: Tue, 2 Sep 2025 18:47:29 +0200 [thread overview]
Message-ID: <aLcfja_1X18qeoQN@redhat.com> (raw)
In-Reply-To: <20250902103010.309094-1-richard.henderson@linaro.org>
On Tue, Sep 02, 2025 at 12:30:06PM +0200, Richard Henderson wrote:
> Hi Daniel,
>
> I'm still not keen on qmessage_context allocating a string.
>
> If we *did* allocate a string, it should be a GString so that we can
> easily append to that. The only benefit I see from this is that we
> would collect all of the output and it would reach stderr atomically.
>
> However, I think it's better to not collect the message and just
> output the pieces. Something like the following. The names are
> horrible and I didn't document the patches well.
Thanks for the suggestion, I'll have a look and see about merging
this, or something like it, into my series for a new posting.
>
>
> r~
>
>
> Richard Henderson (4):
> util: Introduce LogOutput
> util: Drop QMESSAGE_CONTEXT_SKIP_MONITOR
> util/message: Use LogOutput
> util/error-report: Use LogOutput in vreport
>
> include/monitor/monitor.h | 4 +++
> include/qemu/log-output.h | 14 ++++++++
> include/qemu/message.h | 21 +++--------
> monitor/monitor.c | 54 +++++++++++++++++++++++------
> stubs/error-printf.c | 11 ++++++
> util/error-report.c | 73 +++++++++++++++++++--------------------
> util/log.c | 23 +++++-------
> util/message.c | 45 ++++++++++--------------
> 8 files changed, 139 insertions(+), 106 deletions(-)
> create mode 100644 include/qemu/log-output.h
>
> --
> 2.43.0
>
With regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
next prev parent reply other threads:[~2025-09-02 16:49 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-02 10:30 [RFC 0/4] util: qmessage_context followup Richard Henderson
2025-09-02 10:30 ` [RFC 1/4] util: Introduce LogOutput Richard Henderson
2025-09-02 10:30 ` [RFC 2/4] util: Drop QMESSAGE_CONTEXT_SKIP_MONITOR Richard Henderson
2025-09-02 10:30 ` [RFC 3/4] util/message: Use LogOutput Richard Henderson
2025-09-02 10:30 ` [RFC 4/4] util/error-report: Use LogOutput in vreport Richard Henderson
2025-09-02 16:47 ` Daniel P. Berrangé [this message]
2025-09-10 18:05 ` [RFC 0/4] util: qmessage_context followup Daniel P. Berrangé
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=aLcfja_1X18qeoQN@redhat.com \
--to=berrange@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=richard.henderson@linaro.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 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.