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=MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 25926 invoked from network); 29 Jun 2020 16:26:58 -0000 Received: from mother.openwall.net (195.42.179.200) by inbox.vuxu.org with ESMTPUTF8; 29 Jun 2020 16:26:58 -0000 Received: (qmail 7296 invoked by uid 550); 29 Jun 2020 16:26:55 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Reply-To: musl@lists.openwall.com Received: (qmail 7274 invoked from network); 29 Jun 2020 16:26:54 -0000 Date: Mon, 29 Jun 2020 18:26:42 +0200 From: Szabolcs Nagy To: "mayuresh@kathe.in" Cc: musl@lists.openwall.com Message-ID: <20200629162642.GI2048759@port70.net> Mail-Followup-To: "mayuresh@kathe.in" , musl@lists.openwall.com References: <32b4-5ef9e500-33-6d961680@199533904> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable In-Reply-To: <32b4-5ef9e500-33-6d961680@199533904> Subject: Re: [musl] Posits support under Musl libc? * mayuresh@kathe.in [2020-06-29 14:56:09 +0200]: > On Monday, June 29, 2020 05:34 PM IST, Pascal Cuoq wrote: >=20 > > > Can the "musl" libc project consider supporting the Posit number form= at in the math routines? > > > > > More details; > > > https://posithub.org/docs/Posits4.pdf > > > https://posithub.org/docs/BeatingFloatingPoint.pdf > > > > > And a sample implementation; > > > https://gitlab.com/cerlane/SoftPosit > > > > I am not a musl contributor and have no say in what it should contain o= r not, but why in hell a software implementation of a non-standard floating= -point format that only its inventor seems to think has any concrete advant= age over IEEE 754 belong in a libc the goals of which are below? > > > > =E2=80=9Clightweight, fast, simple, free, and strives to be correct in = the sense of standards-conformance and safety.=E2=80=9D (from https://musl.= libc.org/ ) > > > > Posits are 1 out of 5 (I think they are free). >=20 > Posits are lightweight, fast, free and produce the same results across pl= atforms, something which IEEE 754 doesn't guarantee. To top that, IEEE 754 = isn't even a standard but just a set of guidelines which are usually implem= ented incorrectly due to misinterpretation or lack of expertise. So in that= sense, Posits are safer than Floating-point. >=20 > That makes Posits, 4 out of 5 (which seems a much better proposition). i would not hold my breath for posit support even if it was the best possible floating-point format. it has to be properly standardized and added to hw architectures. then the related software standards need to be developed (abi, programming language support, math library behaviour for special cases, printf format specifiers, etc) then the tooling support has to be added (compilers, emulators, softfloat libraries, etc) then we can come back and consider doing something about it in musl. (and even then it will take time for it to be usable in user code: requires widely deployed hw, protocol and file format updates, new algorithm designs and review of existing algorithms for compatibility)