From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 94F2D3858C74; Wed, 28 Feb 2024 11:32:09 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 94F2D3858C74 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1709119929; bh=Hyg5C6FNh0PDT0kWc/rhufD02CD3DcLMnkA9JM7q3gM=; h=From:To:Subject:Date:From; b=SS1+XGMwDzflORcuWqodtZCqXVX88bwMeoLd3kvXQqMTJL1JMlVoG4urVsw0/rIPY WUDQrOipqPah960b6fGj+4edHXvRU19aCln53PZsDjIxNZXZUSl23isageSlciMpzo oEBVSpt5iCV4YdNPz1MT78X0B2LhRZFxsmLP7DDI= From: "newbie-02 at gmx dot de" To: glibc-bugs@sourceware.org Subject: [Bug math/31426] New: log10( 10^n ) poor accuracy in bin80 datatype, log10l( 1E+07l ) -> 7.000000000000000000434... Date: Wed, 28 Feb 2024 11:32:09 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: math X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: newbie-02 at gmx dot de X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone attachments.created Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://sourceware.org/bugzilla/show_bug.cgi?id=3D31426 Bug ID: 31426 Summary: log10( 10^n ) poor accuracy in bin80 datatype, log10l( 1E+07l ) -> 7.000000000000000000434... Product: glibc Version: unspecified Status: UNCONFIRMED Severity: normal Priority: P2 Component: math Assignee: unassigned at sourceware dot org Reporter: newbie-02 at gmx dot de Target Milestone: --- Created attachment 15381 --> https://sourceware.org/bugzilla/attachment.cgi?id=3D15381&action=3Ded= it Snippet demonstrating log10l imprecision. hello @all,=20=20 quite sure you'll tell me it's not a bug but the 'feature of imprecision' in bin-FP-math :-(=20 log10l( 1E+07l ) produces 7.000000000000000000434..., while=20 logl( 1E+07l ) / logl( 10.0l ) would hold with 7.0,=20 Same as with pow10s, having them exact at integral powers of ten=20 would help to form a reliable grid of stable points, and=20 find better ways for correct rounding, which=20 would help for better math.=20 Thus if possible to improve without messing other points I'd=20 appreciate, if not I'd like some explanation why and which=20 calculation path is taken / preferred, and a code pointer to=20 have a look myself.=20 'Me bad' is always an option, tried to evaluate and present=20 with best intention and skills available.=20 If 'notabug' pls. leave open or unconfirmed as hook for others=20 who at some time in the future might have a good idea. --=20 You are receiving this mail because: You are on the CC list for the bug.=