* [Tarantool-patches] [PATCH luajit] test: harden skipcond for libc in LuaJIT-tests @ 2024-12-19 9:30 Sergey Kaplun via Tarantool-patches 2024-12-20 10:59 ` Sergey Bronnikov via Tarantool-patches 0 siblings, 1 reply; 4+ messages in thread From: Sergey Kaplun via Tarantool-patches @ 2024-12-19 9:30 UTC (permalink / raw) To: Maxim Kokryashkin, Sergey Bronnikov; +Cc: tarantool-patches The `strtod parsing` subtest in the <lib/base/tonumber_scan.lua> checks the results yielded by the `strtod()` via FFI call. In glibc versions before 2.28 it returns an incorrect result (NaN instead of inf) for "0x3p1023" [1]. This patch hardens the skipcond for this test for a smaller version of the libc installed. [1]: https://sourceware.org/bugzilla/show_bug.cgi?id=23279 --- Branch: https://github.com/tarantool/luajit/tree/skaplun/gh-noticket-fix-glibc-versions The CI failure for libc 2.23 (ubuntu 16): https://github.com/tarantool/tarantool/actions/runs/12376159316/job/34542626889?pr=10949#step:5:13916 The CI failure for libc 2.24 (debian 9): https://github.com/tarantool/tarantool/actions/runs/12376159307/job/34542633454?pr=10949#step:5:13859 The CI failure for libc 2.27 (ubuntu 18): https://github.com/tarantool/tarantool/actions/runs/12376159278/job/34542625496?pr=10949#step:5:11743 The CI pass for libc 2.31 (ubuntu 20): https://github.com/tarantool/tarantool/actions/runs/12376159289/job/34542630993?pr=10949 test/LuaJIT-tests/lib/base/tonumber_scan.lua | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/test/LuaJIT-tests/lib/base/tonumber_scan.lua b/test/LuaJIT-tests/lib/base/tonumber_scan.lua index ac7d68a4..800c57b0 100644 --- a/test/LuaJIT-tests/lib/base/tonumber_scan.lua +++ b/test/LuaJIT-tests/lib/base/tonumber_scan.lua @@ -186,9 +186,11 @@ do --- tonumber parsing test_conv(tonumber) end --- Skip for the old libc version with the bug in the `strtod()`. --- See also https://sourceware.org/bugzilla/show_bug.cgi?id=16151. -do --- strtod parsing -libc<2.19 +-- Skip for the old libc version with the bugs in the `strtod()`. +-- Affected versions: +-- * <2.19: https://sourceware.org/bugzilla/show_bug.cgi?id=16151. +-- * <2.28: https://sourceware.org/bugzilla/show_bug.cgi?id=23279. +do --- strtod parsing -libc<2.28 test_conv(function(s) local d = ffi.C.strtod(s, e) return (e[0][0] == 0 and #s ~= 0) and d or nil -- 2.47.0 ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Tarantool-patches] [PATCH luajit] test: harden skipcond for libc in LuaJIT-tests 2024-12-19 9:30 [Tarantool-patches] [PATCH luajit] test: harden skipcond for libc in LuaJIT-tests Sergey Kaplun via Tarantool-patches @ 2024-12-20 10:59 ` Sergey Bronnikov via Tarantool-patches 2024-12-20 12:15 ` Sergey Kaplun via Tarantool-patches 0 siblings, 1 reply; 4+ messages in thread From: Sergey Bronnikov via Tarantool-patches @ 2024-12-20 10:59 UTC (permalink / raw) To: Sergey Kaplun, Maxim Kokryashkin; +Cc: tarantool-patches [-- Attachment #1: Type: text/plain, Size: 3340 bytes --] Hello, Sergey, thanks for the patch! See comments below. On 19.12.2024 12:30, Sergey Kaplun wrote: > The `strtod parsing` subtest in the <lib/base/tonumber_scan.lua> checks > the results yielded by the `strtod()` via FFI call. In glibc versions > before 2.28 it returns an incorrect result (NaN instead of inf) for > "0x3p1023" [1]. This patch hardens the skipcond for this test for a > smaller version of the libc installed. > > [1]:https://sourceware.org/bugzilla/show_bug.cgi?id=23279 > --- > > Branch:https://github.com/tarantool/luajit/tree/skaplun/gh-noticket-fix-glibc-versions > > The CI failure for libc 2.23 (ubuntu 16): > https://github.com/tarantool/tarantool/actions/runs/12376159316/job/34542626889?pr=10949#step:5:13916 Ubuntu 16.04 EOL and EOS are reached [1] > The CI failure for libc 2.24 (debian 9): > https://github.com/tarantool/tarantool/actions/runs/12376159307/job/34542633454?pr=10949#step:5:13859 Debian 9 EOL is reached 4 years ago [2] > The CI failure for libc 2.27 (ubuntu 18): > https://github.com/tarantool/tarantool/actions/runs/12376159278/job/34542625496?pr=10949#step:5:11743 > The CI pass for libc 2.31 (ubuntu 20): > https://github.com/tarantool/tarantool/actions/runs/12376159289/job/34542630993?pr=10949 Ubuntu 20.04 support ends in 3 months and 2 week [1]. > > test/LuaJIT-tests/lib/base/tonumber_scan.lua | 8 +++++--- > 1 file changed, 5 insertions(+), 3 deletions(-) > > diff --git a/test/LuaJIT-tests/lib/base/tonumber_scan.lua b/test/LuaJIT-tests/lib/base/tonumber_scan.lua > index ac7d68a4..800c57b0 100644 > --- a/test/LuaJIT-tests/lib/base/tonumber_scan.lua > +++ b/test/LuaJIT-tests/lib/base/tonumber_scan.lua > @@ -186,9 +186,11 @@ do --- tonumber parsing > test_conv(tonumber) > end > > --- Skip for the old libc version with the bug in the `strtod()`. > --- See alsohttps://sourceware.org/bugzilla/show_bug.cgi?id=16151. > -do --- strtod parsing -libc<2.19 > +-- Skip for the old libc version with the bugs in the `strtod()`. > +-- Affected versions: > +-- * <2.19:https://sourceware.org/bugzilla/show_bug.cgi?id=16151. > +-- * <2.28:https://sourceware.org/bugzilla/show_bug.cgi?id=23279. I propose to skip strtod test when Glibc is older than say 2.30 [3] and avoid testing with ancient Glibc versions because Glibc implementation is buggy [4] and a there are lot of bugs in old and more or less new versions: v2.41 [5], v2.22 [6], v2.27 [7], v2.15 [8], v2.33 [9] etc [10]. I don't think we should waste our time with issues like this. 1. https://endoflife.date/ubuntu 2. https://endoflife.date/debian 3. https://sourceware.org/glibc/wiki/Release 4. https://github.com/tarantool/luajit/blob/cd5ab5da9b56bf560407554c0377cfa8567d4430/src/lj_strscan.c#L20-L27 5. https://sourceware.org/bugzilla/show_bug.cgi?id=30220 6. https://sourceware.org/bugzilla/show_bug.cgi?id=19380 7. https://sourceware.org/bugzilla/show_bug.cgi?id=15744 8. https://sourceware.org/bugzilla/show_bug.cgi?id=14049 9. https://sourceware.org/bugzilla/show_bug.cgi?id=26137 10. https://sourceware.org/bugzilla/buglist.cgi?bug_status=__all__&content=strtod&no_redirect=1&order=bug_id%20DESC&product=glibc&query_format=specific > +do --- strtod parsing -libc<2.28 > test_conv(function(s) > local d = ffi.C.strtod(s, e) > return (e[0][0] == 0 and #s ~= 0) and d or nil [-- Attachment #2: Type: text/html, Size: 6871 bytes --] ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Tarantool-patches] [PATCH luajit] test: harden skipcond for libc in LuaJIT-tests 2024-12-20 10:59 ` Sergey Bronnikov via Tarantool-patches @ 2024-12-20 12:15 ` Sergey Kaplun via Tarantool-patches 2024-12-20 12:21 ` Sergey Bronnikov via Tarantool-patches 0 siblings, 1 reply; 4+ messages in thread From: Sergey Kaplun via Tarantool-patches @ 2024-12-20 12:15 UTC (permalink / raw) To: Sergey Bronnikov; +Cc: tarantool-patches Hi, Sergey! Thanks for the review! See my answers below. On 20.12.24, Sergey Bronnikov wrote: > Hello, Sergey, > > thanks for the patch! See comments below. > > > On 19.12.2024 12:30, Sergey Kaplun wrote: > > The `strtod parsing` subtest in the <lib/base/tonumber_scan.lua> checks > > the results yielded by the `strtod()` via FFI call. In glibc versions > > before 2.28 it returns an incorrect result (NaN instead of inf) for > > "0x3p1023" [1]. This patch hardens the skipcond for this test for a > > smaller version of the libc installed. > > > > [1]:https://sourceware.org/bugzilla/show_bug.cgi?id=23279 > > --- > > > > Branch:https://github.com/tarantool/luajit/tree/skaplun/gh-noticket-fix-glibc-versions > > > > The CI failure for libc 2.23 (ubuntu 16): > > https://github.com/tarantool/tarantool/actions/runs/12376159316/job/34542626889?pr=10949#step:5:13916 > Ubuntu 16.04 EOL and EOS are reached [1] > > The CI failure for libc 2.24 (debian 9): > > https://github.com/tarantool/tarantool/actions/runs/12376159307/job/34542633454?pr=10949#step:5:13859 > Debian 9 EOL is reached 4 years ago [2] > > The CI failure for libc 2.27 (ubuntu 18): > > https://github.com/tarantool/tarantool/actions/runs/12376159278/job/34542625496?pr=10949#step:5:11743 > > The CI pass for libc 2.31 (ubuntu 20): > > https://github.com/tarantool/tarantool/actions/runs/12376159289/job/34542630993?pr=10949 > Ubuntu 20.04 support ends in 3 months and 2 week [1]. Yes, unfortunately we should keep (AFAICS) these runners to check the installations for our customers. > > > > > > test/LuaJIT-tests/lib/base/tonumber_scan.lua | 8 +++++--- > > 1 file changed, 5 insertions(+), 3 deletions(-) > > > > diff --git a/test/LuaJIT-tests/lib/base/tonumber_scan.lua b/test/LuaJIT-tests/lib/base/tonumber_scan.lua > > index ac7d68a4..800c57b0 100644 > > --- a/test/LuaJIT-tests/lib/base/tonumber_scan.lua > > +++ b/test/LuaJIT-tests/lib/base/tonumber_scan.lua > > @@ -186,9 +186,11 @@ do --- tonumber parsing > > test_conv(tonumber) > > end > > > > --- Skip for the old libc version with the bug in the `strtod()`. > > --- See alsohttps://sourceware.org/bugzilla/show_bug.cgi?id=16151. > > -do --- strtod parsing -libc<2.19 > > +-- Skip for the old libc version with the bugs in the `strtod()`. > > +-- Affected versions: > > +-- * <2.19:https://sourceware.org/bugzilla/show_bug.cgi?id=16151. > > +-- * <2.28:https://sourceware.org/bugzilla/show_bug.cgi?id=23279. > > I propose to skip strtod test when Glibc is older than say 2.30 [3] and > avoid testing > > with ancient Glibc versions because Glibc implementation is buggy [4] and > > a there are lot of bugs in old and more or less new versions: > > v2.41 [5], v2.22 [6], v2.27 [7], v2.15 [8], v2.33 [9] etc [10]. > > > I don't think we should waste our time with issues like this. > > > 1. https://endoflife.date/ubuntu > > 2. https://endoflife.date/debian > > 3. https://sourceware.org/glibc/wiki/Release > > 4. > https://github.com/tarantool/luajit/blob/cd5ab5da9b56bf560407554c0377cfa8567d4430/src/lj_strscan.c#L20-L27 > > 5. https://sourceware.org/bugzilla/show_bug.cgi?id=30220 > > 6. https://sourceware.org/bugzilla/show_bug.cgi?id=19380 > > 7. https://sourceware.org/bugzilla/show_bug.cgi?id=15744 > > 8. https://sourceware.org/bugzilla/show_bug.cgi?id=14049 > > 9. https://sourceware.org/bugzilla/show_bug.cgi?id=26137 > > 10. > https://sourceware.org/bugzilla/buglist.cgi?bug_status=__all__&content=strtod&no_redirect=1&order=bug_id%20DESC&product=glibc&query_format=specific Yes, I agree that this should be the last red line for us. If the test will fail again due to glibc, it will be easier just to drop it. For now, I see no failures for versions 2.31 -- 2.40, and find no bugs related to our tests that affected versions 2.28 -- 2.30, so let's skip it for versions less than 2.28 for now. > > > +do --- strtod parsing -libc<2.28 > > test_conv(function(s) > > local d = ffi.C.strtod(s, e) > > return (e[0][0] == 0 and #s ~= 0) and d or nil -- Best regards, Sergey Kaplun ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Tarantool-patches] [PATCH luajit] test: harden skipcond for libc in LuaJIT-tests 2024-12-20 12:15 ` Sergey Kaplun via Tarantool-patches @ 2024-12-20 12:21 ` Sergey Bronnikov via Tarantool-patches 0 siblings, 0 replies; 4+ messages in thread From: Sergey Bronnikov via Tarantool-patches @ 2024-12-20 12:21 UTC (permalink / raw) To: Sergey Kaplun; +Cc: tarantool-patches [-- Attachment #1: Type: text/plain, Size: 4313 bytes --] Hi, Sergey, On 20.12.2024 15:15, Sergey Kaplun wrote: > Hi, Sergey! > Thanks for the review! > See my answers below. > > On 20.12.24, Sergey Bronnikov wrote: >> Hello, Sergey, >> >> thanks for the patch! See comments below. >> >> >> On 19.12.2024 12:30, Sergey Kaplun wrote: >>> The `strtod parsing` subtest in the <lib/base/tonumber_scan.lua> checks >>> the results yielded by the `strtod()` via FFI call. In glibc versions >>> before 2.28 it returns an incorrect result (NaN instead of inf) for >>> "0x3p1023" [1]. This patch hardens the skipcond for this test for a >>> smaller version of the libc installed. >>> >>> [1]:https://sourceware.org/bugzilla/show_bug.cgi?id=23279 >>> --- >>> >>> Branch:https://github.com/tarantool/luajit/tree/skaplun/gh-noticket-fix-glibc-versions >>> >>> The CI failure for libc 2.23 (ubuntu 16): >>> https://github.com/tarantool/tarantool/actions/runs/12376159316/job/34542626889?pr=10949#step:5:13916 >> Ubuntu 16.04 EOL and EOS are reached [1] >>> The CI failure for libc 2.24 (debian 9): >>> https://github.com/tarantool/tarantool/actions/runs/12376159307/job/34542633454?pr=10949#step:5:13859 >> Debian 9 EOL is reached 4 years ago [2] >>> The CI failure for libc 2.27 (ubuntu 18): >>> https://github.com/tarantool/tarantool/actions/runs/12376159278/job/34542625496?pr=10949#step:5:11743 >>> The CI pass for libc 2.31 (ubuntu 20): >>> https://github.com/tarantool/tarantool/actions/runs/12376159289/job/34542630993?pr=10949 >> Ubuntu 20.04 support ends in 3 months and 2 week [1]. > Yes, unfortunately we should keep (AFAICS) these runners to check the > installations for our customers. > I believe we will clarify a list of Linux distros in a separate activity. >> >>> test/LuaJIT-tests/lib/base/tonumber_scan.lua | 8 +++++--- >>> 1 file changed, 5 insertions(+), 3 deletions(-) >>> >>> diff --git a/test/LuaJIT-tests/lib/base/tonumber_scan.lua b/test/LuaJIT-tests/lib/base/tonumber_scan.lua >>> index ac7d68a4..800c57b0 100644 >>> --- a/test/LuaJIT-tests/lib/base/tonumber_scan.lua >>> +++ b/test/LuaJIT-tests/lib/base/tonumber_scan.lua >>> @@ -186,9 +186,11 @@ do --- tonumber parsing >>> test_conv(tonumber) >>> end >>> >>> --- Skip for the old libc version with the bug in the `strtod()`. >>> --- See alsohttps://sourceware.org/bugzilla/show_bug.cgi?id=16151. >>> -do --- strtod parsing -libc<2.19 >>> +-- Skip for the old libc version with the bugs in the `strtod()`. >>> +-- Affected versions: >>> +-- * <2.19:https://sourceware.org/bugzilla/show_bug.cgi?id=16151. >>> +-- * <2.28:https://sourceware.org/bugzilla/show_bug.cgi?id=23279. >> I propose to skip strtod test when Glibc is older than say 2.30 [3] and >> avoid testing >> >> with ancient Glibc versions because Glibc implementation is buggy [4] and >> >> a there are lot of bugs in old and more or less new versions: >> >> v2.41 [5], v2.22 [6], v2.27 [7], v2.15 [8], v2.33 [9] etc [10]. >> >> >> I don't think we should waste our time with issues like this. >> >> >> 1.https://endoflife.date/ubuntu >> >> 2.https://endoflife.date/debian >> >> 3.https://sourceware.org/glibc/wiki/Release >> >> 4. >> https://github.com/tarantool/luajit/blob/cd5ab5da9b56bf560407554c0377cfa8567d4430/src/lj_strscan.c#L20-L27 >> >> 5.https://sourceware.org/bugzilla/show_bug.cgi?id=30220 >> >> 6.https://sourceware.org/bugzilla/show_bug.cgi?id=19380 >> >> 7.https://sourceware.org/bugzilla/show_bug.cgi?id=15744 >> >> 8.https://sourceware.org/bugzilla/show_bug.cgi?id=14049 >> >> 9.https://sourceware.org/bugzilla/show_bug.cgi?id=26137 >> >> 10. >> https://sourceware.org/bugzilla/buglist.cgi?bug_status=__all__&content=strtod&no_redirect=1&order=bug_id%20DESC&product=glibc&query_format=specific > Yes, I agree that this should be the last red line for us. If the test > will fail again due to glibc, it will be easier just to drop it. For > now, I see no failures for versions 2.31 -- 2.40, and find no bugs > related to our tests that affected versions 2.28 -- 2.30, so let's skip > it for versions less than 2.28 for now. Okay, LGTM then. Also discussed it and decided to remove the test if the same issue will happen next time. > >>> +do --- strtod parsing -libc<2.28 >>> test_conv(function(s) >>> local d = ffi.C.strtod(s, e) >>> return (e[0][0] == 0 and #s ~= 0) and d or nil [-- Attachment #2: Type: text/html, Size: 8039 bytes --] ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2024-12-20 12:21 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2024-12-19 9:30 [Tarantool-patches] [PATCH luajit] test: harden skipcond for libc in LuaJIT-tests Sergey Kaplun via Tarantool-patches 2024-12-20 10:59 ` Sergey Bronnikov via Tarantool-patches 2024-12-20 12:15 ` Sergey Kaplun via Tarantool-patches 2024-12-20 12:21 ` Sergey Bronnikov via Tarantool-patches
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox