From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.3 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,T_SCC_BODY_TEXT_LINE, UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 27412 invoked from network); 7 Apr 2022 18:01:16 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 7 Apr 2022 18:01:16 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20210803; t=1649354476; b=G8pY9hWDYk1xQJPJ/ORDeTwlCkAPdGcGZ1P2LFdnWrB4gpLm5yrhDFRvdHRoOBuGQAwglQ8OPp 3LD2n9xQbHuOw5jyQYgWypQdx4hrm13BQwudZzM+J3AQV1FLyZ8r8F4p9ea/he3e14aoUGnEm6 yQ6ONyTRFveoCC7sIWmq4CmyZv4pBB8K/snAZuyv93Z29sDHYg5wVvnGjAIDBuWwgE4QblnX0Z wPQbqwyKbL/9SiLONSRDWjFnewzz6Fvsdtj/7df0E0Vn5HvDfnZxfAcGfuj8+YKfPUeECFHKH0 YMvmnXohUfYitbJGh7z005DF6cpUBm6E5bjlFGwkmWNA9A==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mail-ej1-f49.google.com) smtp.remote-ip=209.85.218.49; dkim=pass header.d=brasslantern-com.20210112.gappssmtp.com header.s=20210112 header.a=rsa-sha256; dmarc=none header.from=brasslantern.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20210803; t=1649354476; bh=lfsZ2UnmUHrhGC8yrgwj/LSRoGWJB5Ik6ZGIILyI290=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Type:To:Subject:Message-ID:Date:From:In-Reply-To: References:MIME-Version:DKIM-Signature:DKIM-Signature; b=h6Cj7zsDm8yA01kmkBsHbBTnn7ARaaC03EskNthBsgj9Y1eelwr+hIRbvipjQ32kudpk6IKv9K 8dAKv5nMB6/WwwDKU2ina6eoKm1EhseppT59uwEoFocshp1OMhHIbcsDt4yAD8nBKLqDOktkIi bRaK2lNcRiiGmG0OtOhI4GzznKhD4mdB9Va/QOtR9YsuIg9+yq4XwDNsPnfogv1qQPVBoG6B8y 1fqEiJtT/ub58VqXcTbJ32rHZ+VRxkt9K4xLRM+b96doHnCtcKMim/Lnl0PkhGZTcukbFCbyJ1 24wO5lQ3ke9FQc45WnAwY7GEfg/xNrCQ3A/beg5GIkfB1g==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20210803; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Type:To:Subject:Message-ID: Date:From:In-Reply-To:References:MIME-Version:Reply-To:Cc: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=i0S5TjT9wnuyvJfLyQ0acVBSLpa9Yhblge+Z/+D68Bk=; b=SE4zoGBD3kDoAq6hNkmeuMAcoo 8KtsMXlzfg3682xIY1Lv2Yq/LFpnY/8K54BxI+ZFtqlxxnMIUBfE3k7z3KHXkCEwppZpjzG+DeP+b 30R4qS3EXHFckadVY0t4pDMEoI/jBNJ6PN3pyAf/wU0AMiWgmDM0kF3OkPZt11vVTTyJ7Uc7Ck+yE yinUGalSkeA+lD+2U4rv5EiqjKS5REi0NfYao6m69Tagmy/05pkxAOTj1QNW83emJb2/kRym6gu+W qBXOrMYkSn240If9mY4x/ybug07ykpjs+D24o2FQd579EhWMnSqlCM06LDS8wQvEJmzxD/TLgU12U OSvGIdOw==; Received: from authenticated user by zero.zsh.org with local id 1ncWRW-0002UH-09; Thu, 07 Apr 2022 18:01:14 +0000 Authentication-Results: zsh.org; iprev=pass (mail-ej1-f49.google.com) smtp.remote-ip=209.85.218.49; dkim=pass header.d=brasslantern-com.20210112.gappssmtp.com header.s=20210112 header.a=rsa-sha256; dmarc=none header.from=brasslantern.com; arc=none Received: from mail-ej1-f49.google.com ([209.85.218.49]:37684) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) id 1ncWR0-0002AS-4n; Thu, 07 Apr 2022 18:00:43 +0000 Received: by mail-ej1-f49.google.com with SMTP id bg10so12530277ejb.4 for ; Thu, 07 Apr 2022 11:00:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brasslantern-com.20210112.gappssmtp.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=i0S5TjT9wnuyvJfLyQ0acVBSLpa9Yhblge+Z/+D68Bk=; b=c45rq5cHxPwouyvGKl6F4x9kOdtMS5T3F1XGeATHUilNC3NBlLxp/HxmYhGCG3X/FD B2EQcL/gNUUw2lCY+oFoz7pZKPabqORyzP5LeWZay5PWtofOQwbz8NXw6Mb8sIW+r/EK wK/4aSRWTk8dqU7xB5aEg1608IkZI+b/kDWsoydJ38VaXFjWBVEkrlykfARMHgQZML5+ ssfBHP6OVG25bjU5nxdhaStBstsU9NM7NlYLdzkwubsLY3w9lkIi+6fPw2PCuWd07GjI hLyTa2CAOsN/8TYX3fowp263wfkoEdzyJdDz07vsZOs6KiXYsdhWNeJShLmUGF8iflnu L9ZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=i0S5TjT9wnuyvJfLyQ0acVBSLpa9Yhblge+Z/+D68Bk=; b=D5bB5C0RDBuGM3XjzV4uWw3nC+9uRX586Ml+hzh3Rhnwqv556zRunaUOHgnZlEr0Q5 Glx/JfBUFtPUqA7KXwcscAOUpRwJM1eo2/t18xavNuhB+TpDQh7uD6hrdFM39auMpWpR wjw+25RvaxVIqnr4Sa3kM1beAQSPNBNTL9we8TjUhrlR7rBBfahUlL7awnXow+HV75F2 vJsX6wknQFF+jvr688gIWOwJtghbZF+qyYmWD46/bwo0kcELEHHLMCrSX7Ovbsh85O0f Rm4rpshQyFQoeKQp5eUKF+tLPfmkRqyD6J3kO/RDJuWZb8GCZiE0VGFWJgnLAHswcpWv ctUQ== X-Gm-Message-State: AOAM533isyxzSyXgH98EuwtC5QR+fZy3Iej+ig/DSLT699T/Dsjp9k5q vgmhRK6SaaG48Y7phm0l7WTTJ9HMoxpy/bwD1MSkDZ1QI/ys1A== X-Google-Smtp-Source: ABdhPJzG8i//Z9rwMvv4yW2xuUS2mTB0DoTSNzQ12x/M41FMZ8KZiVVfFrFztSt1Vt4zHDp7IGtMLwbnx9M4bvpDzIQ= X-Received: by 2002:a17:906:7742:b0:6e8:3f85:4da1 with SMTP id o2-20020a170906774200b006e83f854da1mr2917968ejn.495.1649354440952; Thu, 07 Apr 2022 11:00:40 -0700 (PDT) MIME-Version: 1.0 References: <20220323163646.GB1190496@cventin.lip.ens-lyon.fr> <20220327082652.fg6uef5munymssm6@chazelas.org> <20220407150645.GB1179089@zira.vinc17.org> In-Reply-To: <20220407150645.GB1179089@zira.vinc17.org> From: Bart Schaefer Date: Thu, 7 Apr 2022 11:00:29 -0700 Message-ID: Subject: Re: floating-point precision and zsh vs ksh93 and coreutils To: Zsh hackers list Content-Type: text/plain; charset="UTF-8" X-Seq: 50016 Archived-At: X-Loop: zsh-workers@zsh.org Errors-To: zsh-workers-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-workers-request@zsh.org X-no-archive: yes List-Id: List-Help: List-Subscribe: List-Unsubscribe: List-Post: List-Owner: List-Archive: On Thu, Apr 7, 2022 at 8:07 AM Vincent Lefevre wrote: > > On 2022-03-27 15:26:42 -0700, Bart Schaefer wrote: > > Vincent's final contribution to that discussion was a link to the > > dtoa() implementation in C by D.Gay ... which just for comparison is > > more than 6000 lines of code or about 4% the size of the entire zsh C > > code at the time I write this. > > I haven't looked at the code recently, but I thought that D. Gay's > code provided several functions. For just the output to decimal, > I suppose that this should be much shorter. Actually, no. I visited the site; each of the "several functions" is isolated to its own file. 6k lines is JUST dtoa(). About a third of it is huge lookup tables.