Re: glibc test time regression after gawk update

Sam James <[email protected]>
Newsgroups gmane.comp.gnu.gawk.bugs,gmane.comp.lib.glibc.alpha
Organization Gentoo
Message-ID <[email protected]>
[email protected] writes:

> Hi.

Hi Arnold,

>
> I suspect that the problem is line 34 in the script:
>
> 	value = gensub(/^(INF|NAN|inf|nan)/, "+\\1", 1, val)
>
> There was a bug in gensub with \N escapes that has been fixed.
> Can you try with https://www.skeeve.com/gawk/gawk-5.4.0d.tar.gz?
>
> FYI, feedback on this ASAP would be really good, as I am planning
> to release 5.4.1 this week.

Sorry for the delay, I'd tried to find time earlier this week but events
got the better of me.

It looks like it solves the problem:
```
$ hyperfine "make test t=stdio-common/tst-printf-format-vas-double-f AWK=/tmp/gawk-5.4.0/bin/gawk" "make test t=stdio-common/tst-printf-format-vas-double-f AWK=/tmp/gawk-5.4-stable/bin/gawk"
Benchmark 1: make test t=stdio-common/tst-printf-format-vas-double-f AWK=/tmp/gawk-5.4.0/bin/gawk
  Time (mean ± σ):      3.303 s ±  0.013 s    [User: 3.567 s, System: 0.116 s]
  Range (min … max):    3.281 s …  3.320 s    10 runs

Benchmark 2: make test t=stdio-common/tst-printf-format-vas-double-f AWK=/tmp/gawk-5.4-stable/bin/gawk
  Time (mean ± σ):      2.369 s ±  0.018 s    [User: 2.632 s, System: 0.114 s]
  Range (min … max):    2.352 s …  2.415 s    10 runs

Summary
  make test t=stdio-common/tst-printf-format-vas-double-f AWK=/tmp/gawk-5.4-stable/bin/gawk ran
    1.39 ± 0.01 times faster than make test t=stdio-common/tst-printf-format-vas-double-f AWK=/tmp/gawk-5.4.0/bin/gawk
```

Hopefully Florian can confirm as well. I didn't compare the full
testsuite time, just picked a sample of the tst-printf-format-* tests
(as for some reason I couldn't easily re-run just all of those with
`subdirs=`).

>
> Thanks,
>
> Arnold

cheers,
sam

>
> Sam James <[email protected]> wrote:
>
>> Sam James <[email protected]> writes:
>>
>> > Florian Weimer <[email protected]> writes:
>> >
>> >> It looks like we have a very substantial test time regression in glibc
>> >> after a gawk update.  Based on quick poking with GDB, it may be related
>> >> to the MinRX change in gawk 5.4.0.
>> >>
>> >> This is the script:
>> >>
>> >>   <https://sourceware.org/cgit/glibc/tree/stdio-common/tst-printf-format.awk>
>> >>
>> >> Is this expected?  The input files can be quite large, with very long
>> >> lines, too.
>> >>
>> >> I suppose we can switch back to the old matcher (will that remain
>> >> available?), or maybe run it under the C locale.
>> >
>> > Maciej, can you take a look? I suspect you're best placed to try reduce
>> > something here as you're the author of the tests.
>>
>> Resending.
>>
>> >
>> >>
>> >> Thanks,
>> >> Florian
signature.asc (application/pgp-signature, 418 B)
-----BEGIN PGP SIGNATURE-----

iQEBBAEWCgCpFiEEJaa7iN2bdkxrVUHCc4QJ9SDfkZAFAmpK5mkbFIAAAAAABAAO
bWFudTIsMi41KzEuMTIsMiwyXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25z
Lm9wZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQyNUE2QkI4OEREOUI3NjRDNkI1NTQx
QzI3Mzg0MDlGNTIwREY5MTkwDxxzYW1AZ2VudG9vLm9yZwAKCRBzhAn1IN+RkH0D
AP4m+mnjB9aBGggcoK3PA5cIvx/USfKvTcKZYeqenhpYZgEA1oXOtwySHLmwKhUf
LrIUevTgSmDoCqIfMqLkZneJgA8=
=1rhZ
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.