Peter Krempa wrote:
On Sun, Feb 28, 2021 at 08:24:58 +0400, Roman Bogorodskiy wrote:
> Meson default timeout for test() is 30 seconds. This may be not enough
> for some tests like sc_prohibit_nonreentrant or
> sc_libvirt_unmarked_diagnostics, so set it to 60 seconds.
Recently [1] we've established that we'll not be raising the timeout
arbitrarily to compensate for a possibly slow hardware unless it's a
widespread problem.
The tests you are complaining about are pretty fast on my system:
203/334 libvirt:syntax-check / sc_prohibit_nonreentrant OK
0.23s
315/334 libvirt:syntax-check / sc_unmarked_diagnostics OK
0.63s
On a laptop:
204/335 libvirt:syntax-check / sc_prohibit_nonreentrant OK
0.44s
316/335 libvirt:syntax-check / sc_unmarked_diagnostics OK
0.78s
And on a random sample from our (linux) CI runs:
53/158 libvirt:syntax-check / sc_libvirt_unmarked_diagnostics OK 0.6185753345489502
s
27/158 libvirt:syntax-check / sc_prohibit_nonreentrant OK 0.2680661678314209 s
Given the almost 2 orders of magnitude difference, I think something is
broken on your system and should be investigated first before attempting
to increase the timeout.
I *think* the reason it's slow on my system is because BSD grep is
slower than GNU grep.
I don't have a solid evidence of that though, except that 10 years old
post [1] and a basic test:
$ time gmake -C /usr/home/novel/code/libvirt/build/build-aux sc_prohibit_nonreentrant
gmake: Entering directory '/usr/home/novel/code/libvirt/build/build-aux'
prohibit_nonreentrant
gmake: Leaving directory '/usr/home/novel/code/libvirt/build/build-aux'
gmake -C /usr/home/novel/code/libvirt/build/build-aux sc_prohibit_nonreentran 48,21s user
0,06s system 100% cpu 48,199 total
$ time PATH="/usr/local/bin:$PATH" gmake -C
/usr/home/novel/code/libvirt/build/build-aux sc_prohibit_nonreentrant
gmake: Entering directory '/usr/home/novel/code/libvirt/build/build-aux'
prohibit_nonreentrant
gmake: Leaving directory '/usr/home/novel/code/libvirt/build/build-aux'
PATH="/usr/local/bin:$PATH" gmake -C sc_prohibit_nonreentrant 0,23s user 0,02s
system 119% cpu 0,215 total
$
Here, the PATH override is used because on FreeBSD the original BSD grep
is installed in /usr/bin/grep, and GNU grep is installed in
/usr/local/bin/grep from the gnugrep package (or textproc/gnugrep port).
1:
https://lists.freebsd.org/pipermail/freebsd-current/2010-August/019310.html
> Signed-off-by: Roman Bogorodskiy <bogorodskiy(a)gmail.com>
> ---
> On my system these two tests always timeout with the default value.
> That's what I have after increasing timeout:
>
> 157/288 libvirt:syntax-check / sc_prohibit_nonreentrant OK
52.18s
> 183/288 libvirt:syntax-check / sc_libvirt_unmarked_diagnostics OK
31.48s
[1] thread start:
https://listman.redhat.com/archives/libvir-list/2021-January/msg01148.html
https://listman.redhat.com/archives/libvir-list/2021-January/msg01219.html
Roman Bogorodskiy