Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Kevin Buettner <kevinb@redhat.com>
To: gdb-patches@sourceware.org
Cc: Tom Tromey <tromey@adacore.com>
Subject: Re: [PATCH] Remove excess calls to gdb_flush
Date: Tue, 19 Feb 2019 22:12:00 -0000	[thread overview]
Message-ID: <20190219151226.2805c624@f29-4.lan> (raw)
In-Reply-To: <20190219205426.4168-1-tromey@adacore.com>

On Tue, 19 Feb 2019 13:54:26 -0700
Tom Tromey <tromey@adacore.com> wrote:

> A customer noticed some mildly odd MI output, where CLI output was
> split into multiple MI strings at unusual boundaries, like this:
> 
>     ~"$1 = (b => true"
>     ~", p => 0x407260"
> 
> This is technically correct according to the MI spec, but still
> unusual, in that there's no particular reason for the string to be
> split where it is.
> 
> I tracked this down to a call to gdb_flush in generic_val_print.
> Then, I went through all calls to gdb_flush and removed the ones I
> thought were superfluous.  In particular:
> 
> * Any call in the value-printing code;
> * Likewise the type-printing code (just a single call); and
> * Any call that immediately followed a printf that obviously
>   ended with a newline, my belief being that gdb's standard output
>   streams are line buffered (by inheriting the behavior from stdio)
> 
> Regression tested on x86-64 Fedora 29.
> 
> I didn't add a new test case.  I tend to think we don't necessarily
> want to specify this behavior in the tests.  Let me know what you
> think of this.

I agree with you regarding the test case.

I looked over the patch and didn't see any problems.

Kevin


  reply	other threads:[~2019-02-19 22:12 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-19 20:54 Tom Tromey
2019-02-19 22:12 ` Kevin Buettner [this message]
2019-03-05 15:56   ` Tom Tromey
2019-03-05 17:06 ` Pedro Alves
2019-03-05 17:54   ` Tom Tromey
2019-03-07  6:06     ` Joel Brobecker

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=20190219151226.2805c624@f29-4.lan \
    --to=kevinb@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=tromey@adacore.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox