QEMU-Devel Archive on lore.kernel.org
 help / color / Atom feed
From: Andrey Shinkevich <andrey.shinkevich@virtuozzo.com>
To: John Snow <jsnow@redhat.com>,
	Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>,
	"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
	"qemu-block@nongnu.org" <qemu-block@nongnu.org>
Cc: "kwolf@redhat.com" <kwolf@redhat.com>,
	Denis Lunev <den@virtuozzo.com>,
	"mreitz@redhat.com" <mreitz@redhat.com>
Subject: Re: [Qemu-devel] [Qemu-block] [PATCH v5 6/6] iotests: extend sleeping time under Valgrind
Date: Wed, 28 Aug 2019 15:24:00 +0000
Message-ID: <421d92ed-0eb1-6e45-f080-0198c1739e17@virtuozzo.com> (raw)
In-Reply-To: <27a1a3e5-3ebd-2e64-a36e-e8e4728b2b6d@redhat.com>



On 27/08/2019 22:42, John Snow wrote:
> 
> 
> On 8/23/19 11:27 AM, Vladimir Sementsov-Ogievskiy wrote:
>> 16.08.2019 4:01, John Snow wrote:
>>>
>>>
>>> On 7/19/19 12:30 PM, Andrey Shinkevich wrote:
>>>> To synchronize the time when QEMU is running longer under the Valgrind,
>>>> increase the sleeping time in the test 247.
>>>>
>>>> Signed-off-by: Andrey Shinkevich <andrey.shinkevich@virtuozzo.com>
>>>> Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
>>>> ---
>>>>    tests/qemu-iotests/247 | 6 +++++-
>>>>    1 file changed, 5 insertions(+), 1 deletion(-)
>>>>
>>>> diff --git a/tests/qemu-iotests/247 b/tests/qemu-iotests/247
>>>> index 546a794..c853b73 100755
>>>> --- a/tests/qemu-iotests/247
>>>> +++ b/tests/qemu-iotests/247
>>>> @@ -57,7 +57,11 @@ TEST_IMG="$TEST_IMG.4" _make_test_img $size
>>>>    {"execute":"block-commit",
>>>>     "arguments":{"device":"format-4", "top-node": "format-2", "base-node":"format-0", "job-id":"job0"}}
>>>>    EOF
>>>> -sleep 1
>>>> +if [ "${VALGRIND_QEMU}" == "y" ]; then
>>>> +    sleep 10
>>>> +else
>>>> +    sleep 1
>>>> +fi
>>>>    echo '{"execute":"quit"}'
>>>>    ) | $QEMU -qmp stdio -nographic -nodefaults \
>>>>        -blockdev file,node-name=file-0,filename=$TEST_IMG.0,auto-read-only=on \
>>>>
>>>
>>> This makes me nervous, though. Won't this race terribly? (Wait, why
>>> doesn't it race already?)
>>>
>>
>> Hmm, however it works somehow. I'm afraid that everything with "sleep" is definitely racy..
>> Or what do you mean?
>>
> 
> Right -- anything with a sleep is already at risk for racing.
> 
> What I am picking up on here is that with valgrind, there is an even
> greater computational overhead that's much harder to predict, so I was
> wondering how these values were determined.
> 

I just followed the trend and extended the sleeping time with a grater 
tolerance so that the test could pass on systems where the 'sleep 1' 
command helps to pass without Valgrind. We could rewrite the test 247 in 
Python in a separate series, shall we?

Andrey

> (I wouldn't withhold an RB for that alone -- the sleeps are existing
> problems.)
> 
> What I moved on to wondering in particular is why test 247 doesn't
> already have race problems, because it looks quite fragile.
> 
> Neither of these are really Andrey's problems; I was just surprised
> momentarily that I don't see 247 fail more often already, as-is.
> 
> --js
> 

-- 
With the best regards,
Andrey Shinkevich

  reply index

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-19 16:30 [Qemu-devel] [PATCH v5 0/6] Allow Valgrind checking all QEMU processes Andrey Shinkevich
2019-07-19 16:30 ` [Qemu-devel] [PATCH v5 1/6] iotests: allow " Andrey Shinkevich
2019-08-15 22:49   ` [Qemu-devel] [Qemu-block] " John Snow
2019-08-25 15:26     ` Andrey Shinkevich
2019-08-27 19:56       ` John Snow
2019-08-28 15:04         ` Andrey Shinkevich
2019-07-19 16:30 ` [Qemu-devel] [PATCH v5 2/6] iotests: exclude killed processes from running under Valgrind Andrey Shinkevich
2019-08-16  0:40   ` [Qemu-devel] [Qemu-block] " John Snow
2019-07-19 16:30 ` [Qemu-devel] [PATCH v5 3/6] iotests: Add casenotrun report to bash tests Andrey Shinkevich
2019-08-16  0:44   ` [Qemu-devel] [Qemu-block] " John Snow
2019-08-16 20:33     ` Cleber Rosa
2019-08-25 13:03       ` Andrey Shinkevich
2019-07-19 16:30 ` [Qemu-devel] [PATCH v5 4/6] iotests: Valgrind fails with nonexistent directory Andrey Shinkevich
2019-08-16  0:55   ` [Qemu-devel] [Qemu-block] " John Snow
2019-08-25 15:24     ` Andrey Shinkevich
2019-08-27 19:45       ` John Snow
2019-08-28 15:12         ` Andrey Shinkevich
2019-07-19 16:30 ` [Qemu-devel] [PATCH v5 5/6] iotests: extended timeout under Valgrind Andrey Shinkevich
2019-08-16  0:58   ` [Qemu-devel] [Qemu-block] " John Snow
2019-07-19 16:30 ` [Qemu-devel] [PATCH v5 6/6] iotests: extend sleeping time " Andrey Shinkevich
2019-08-16  1:01   ` [Qemu-devel] [Qemu-block] " John Snow
2019-08-23 15:27     ` Vladimir Sementsov-Ogievskiy
2019-08-27 19:42       ` John Snow
2019-08-28 15:24         ` Andrey Shinkevich [this message]
2019-08-28 17:27           ` John Snow
2019-08-25 10:13     ` Andrey Shinkevich
2019-08-06 16:24 ` [Qemu-devel] [PATCH v5 0/6] Allow Valgrind checking all QEMU processes Andrey Shinkevich
2019-08-16 20:05 ` Cleber Rosa
2019-08-25 10:30   ` Andrey Shinkevich

Reply instructions:

You may reply publically 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=421d92ed-0eb1-6e45-f080-0198c1739e17@virtuozzo.com \
    --to=andrey.shinkevich@virtuozzo.com \
    --cc=den@virtuozzo.com \
    --cc=jsnow@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=mreitz@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=vsementsov@virtuozzo.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

QEMU-Devel Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/qemu-devel/0 qemu-devel/git/0.git
	git clone --mirror https://lore.kernel.org/qemu-devel/1 qemu-devel/git/1.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 qemu-devel qemu-devel/ https://lore.kernel.org/qemu-devel \
		qemu-devel@nongnu.org
	public-inbox-index qemu-devel

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.nongnu.qemu-devel


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git