qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Eric Blake <eblake@redhat.com>
To: Fam Zheng <famz@redhat.com>, qemu-devel@nongnu.org
Cc: kwolf@redhat.com, stefanha@redhat.com
Subject: Re: [Qemu-devel] [PATCH 0/2] qemu-iotests: Filter out "qemu-io> " in all tests
Date: Tue, 19 Nov 2013 06:00:20 -0700	[thread overview]
Message-ID: <528B60E4.7070301@redhat.com> (raw)
In-Reply-To: <528B0A3A.6070303@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 2211 bytes --]

On 11/18/2013 11:50 PM, Fam Zheng wrote:
> The second patch is too big in size (over 10M), and rejected by list
> moderator.
> 
> You can PULL from git branch:
> 
>     https://github.com/famz/qemu.git 035-filter-qemu-io

I'm guessing the second patch consists of a tiny amount of code to turn
on the filter, while the majority of the patch was automated.  It would
be helpful to amend your commit message to show how you automated the
conversion (was it something like
  find tests/qemu-iotests -name "*.out" | \
  xargs -L1 sed -i "s/qemu-io> //g" '
?)

Given such a formula in the commit message itself, it would be much
easier to review the patch - check that both the non-automatic small
modification and the conversion formula make sense, then repeat the
conversion formula locally and compare it to your git tree to see that
the two results match, and that the testsuite still passes.  [Or in
other words, I don't plan on reading 10M of mindlessly repetitive
changes :) ]

>>   tests/qemu-iotests/common.filter |     3 +-
>>   20 files changed, 75546 insertions(+), 75545 deletions(-)

Looks like that's the one file with the nontrivial change.


diff --git a/tests/qemu-iotests/common.filter
b/tests/qemu-iotests/common.filter
index 8e7b1a4..0dd82e1 100644
--- a/tests/qemu-iotests/common.filter
+++ b/tests/qemu-iotests/common.filter
@@ -149,7 +149,8 @@ _filter_win32()
 # sanitize qemu-io output
 _filter_qemu_io()
 {
-    _filter_win32 | sed -e "s/[0-9]* ops\; [0-9/:. sec]* ([0-9/.inf]*
[EPTGMKiBbytes]*\/sec and [0-9/.inf]* ops\/sec)/X ops\; XX:XX:XX.X (XXX
YYY\/sec and XXX ops\/sec)/"
+    _filter_win32 | sed -e "s/[0-9]* ops\; [0-9/:. sec]* ([0-9/.inf]*
[EPTGMKiBbytes]*\/sec and [0-9/.inf]* ops\/sec)/X ops\; XX:XX:XX.X (XXX
YYY\/sec and XXX ops\/sec)/" |\
+        sed -e "s/qemu-io> //g"
 }

 # replace occurrences of QEMU_PROG with "qemu"


Question - why do you pipeline 'sed | sed'?  It should be sufficient to
just add the "s/qemu-io> //g" instruction into the existing sed
pipeline, for one fewer process per filter run.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 621 bytes --]

      reply	other threads:[~2013-11-19 13:00 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-18  7:21 [Qemu-devel] [PATCH 0/2] qemu-iotests: Filter out "qemu-io> " in all tests Fam Zheng
2013-11-18  7:21 ` [Qemu-devel] [PATCH 1/2] qemu-iotests: Filter qemu-io output in 025 Fam Zheng
2013-11-19 13:03   ` Eric Blake
2013-11-19  6:50 ` [Qemu-devel] [PATCH 0/2] qemu-iotests: Filter out "qemu-io> " in all tests Fam Zheng
2013-11-19 13:00   ` Eric Blake [this message]

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=528B60E4.7070301@redhat.com \
    --to=eblake@redhat.com \
    --cc=famz@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@redhat.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;
as well as URLs for NNTP newsgroup(s).