<!DOCTYPE html>
<html data-lt-installed="true">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body style="padding-bottom: 1px;">
    <p>Hello, Sergey,</p>
    <p>thanks for the patch! See comments below.<br>
    </p>
    <p><br>
    </p>
    <div class="moz-cite-prefix">On 19.12.2024 12:30, Sergey Kaplun
      wrote:<br>
    </div>
    <blockquote type="cite"
      cite="mid:20241219093041.14681-1-skaplun@tarantool.org">
      <pre class="moz-quote-pre" wrap="">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]: <a class="moz-txt-link-freetext" href="https://sourceware.org/bugzilla/show_bug.cgi?id=23279">https://sourceware.org/bugzilla/show_bug.cgi?id=23279</a>
---

Branch: <a class="moz-txt-link-freetext" href="https://github.com/tarantool/luajit/tree/skaplun/gh-noticket-fix-glibc-versions">https://github.com/tarantool/luajit/tree/skaplun/gh-noticket-fix-glibc-versions</a>

The CI failure for libc 2.23 (ubuntu 16):
<a class="moz-txt-link-freetext" href="https://github.com/tarantool/tarantool/actions/runs/12376159316/job/34542626889?pr=10949#step:5:13916">https://github.com/tarantool/tarantool/actions/runs/12376159316/job/34542626889?pr=10949#step:5:13916</a></pre>
    </blockquote>
    Ubuntu 16.04 EOL and EOS are reached [1]<br>
    <blockquote type="cite"
      cite="mid:20241219093041.14681-1-skaplun@tarantool.org">
      <pre class="moz-quote-pre" wrap="">
The CI failure for libc 2.24 (debian 9):
<a class="moz-txt-link-freetext" href="https://github.com/tarantool/tarantool/actions/runs/12376159307/job/34542633454?pr=10949#step:5:13859">https://github.com/tarantool/tarantool/actions/runs/12376159307/job/34542633454?pr=10949#step:5:13859</a></pre>
    </blockquote>
    Debian 9 EOL is reached 4 years ago [2]<br>
    <blockquote type="cite"
      cite="mid:20241219093041.14681-1-skaplun@tarantool.org">
      <pre class="moz-quote-pre" wrap="">
The CI failure for libc 2.27 (ubuntu 18):
<a class="moz-txt-link-freetext" href="https://github.com/tarantool/tarantool/actions/runs/12376159278/job/34542625496?pr=10949#step:5:11743">https://github.com/tarantool/tarantool/actions/runs/12376159278/job/34542625496?pr=10949#step:5:11743</a>
The CI pass for libc 2.31 (ubuntu 20):
<a class="moz-txt-link-freetext" href="https://github.com/tarantool/tarantool/actions/runs/12376159289/job/34542630993?pr=10949">https://github.com/tarantool/tarantool/actions/runs/12376159289/job/34542630993?pr=10949</a></pre>
    </blockquote>
    Ubuntu 20.04 support ends in 3 months and 2 week [1].
    <p><br>
    </p>
    <blockquote type="cite"
      cite="mid:20241219093041.14681-1-skaplun@tarantool.org">
      <pre class="moz-quote-pre" wrap="">

 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 <a class="moz-txt-link-freetext" href="https://sourceware.org/bugzilla/show_bug.cgi?id=16151">https://sourceware.org/bugzilla/show_bug.cgi?id=16151</a>.
-do --- strtod parsing -libc<2.19
+-- Skip for the old libc version with the bugs in the `strtod()`.
+-- Affected versions:
+-- * <2.19: <a class="moz-txt-link-freetext" href="https://sourceware.org/bugzilla/show_bug.cgi?id=16151">https://sourceware.org/bugzilla/show_bug.cgi?id=16151</a>.
+-- * <2.28: <a class="moz-txt-link-freetext" href="https://sourceware.org/bugzilla/show_bug.cgi?id=23279">https://sourceware.org/bugzilla/show_bug.cgi?id=23279</a>.</pre>
    </blockquote>
    <p>I propose to skip strtod test when Glibc is older than say 2.30
      [3] and avoid testing</p>
    <p>with ancient Glibc versions because Glibc implementation is buggy
      [4] and</p>
    <p>a there are lot of bugs in old and more or less new versions:</p>
    <p>v2.41 [5], v2.22 [6], v2.27 [7], v2.15 [8], v2.33 [9] etc [10].<br>
    </p>
    <p><br>
    </p>
    <p>I don't think we should waste our time with issues like this.<br>
    </p>
    <p><br>
    </p>
    <p>1. <a class="moz-txt-link-freetext" href="https://endoflife.date/ubuntu">https://endoflife.date/ubuntu</a></p>
    <p>2. <a class="moz-txt-link-freetext" href="https://endoflife.date/debian">https://endoflife.date/debian</a></p>
    <p>3. <a class="moz-txt-link-freetext" href="https://sourceware.org/glibc/wiki/Release">https://sourceware.org/glibc/wiki/Release</a></p>
    <p>4.
<a class="moz-txt-link-freetext" href="https://github.com/tarantool/luajit/blob/cd5ab5da9b56bf560407554c0377cfa8567d4430/src/lj_strscan.c#L20-L27">https://github.com/tarantool/luajit/blob/cd5ab5da9b56bf560407554c0377cfa8567d4430/src/lj_strscan.c#L20-L27</a></p>
    <p>5. <a class="moz-txt-link-freetext" href="https://sourceware.org/bugzilla/show_bug.cgi?id=30220">https://sourceware.org/bugzilla/show_bug.cgi?id=30220</a><br>
    </p>
    <p>6. <a class="moz-txt-link-freetext" href="https://sourceware.org/bugzilla/show_bug.cgi?id=19380">https://sourceware.org/bugzilla/show_bug.cgi?id=19380</a></p>
    <p>7. <a class="moz-txt-link-freetext" href="https://sourceware.org/bugzilla/show_bug.cgi?id=15744">https://sourceware.org/bugzilla/show_bug.cgi?id=15744</a></p>
    <p>8. <a class="moz-txt-link-freetext" href="https://sourceware.org/bugzilla/show_bug.cgi?id=14049">https://sourceware.org/bugzilla/show_bug.cgi?id=14049</a></p>
    <p>9. <a class="moz-txt-link-freetext" href="https://sourceware.org/bugzilla/show_bug.cgi?id=26137">https://sourceware.org/bugzilla/show_bug.cgi?id=26137</a></p>
    <p>10.
<a class="moz-txt-link-freetext" href="https://sourceware.org/bugzilla/buglist.cgi?bug_status=__all__&content=strtod&no_redirect=1&order=bug_id%20DESC&product=glibc&query_format=specific">https://sourceware.org/bugzilla/buglist.cgi?bug_status=__all__&content=strtod&no_redirect=1&order=bug_id%20DESC&product=glibc&query_format=specific</a><br>
    </p>
    <p></p>
    <blockquote type="cite"
      cite="mid:20241219093041.14681-1-skaplun@tarantool.org">
      <pre class="moz-quote-pre" wrap="">
+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
</pre>
    </blockquote>
  </body>
  <lt-container></lt-container>
</html>