<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta name=Generator content="Microsoft Word 15 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Aptos;
panose-1:2 11 0 4 2 2 2 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
font-size:12.0pt;
font-family:"Aptos",sans-serif;}
MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;
mso-ligatures:none;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:70.85pt 70.85pt 2.0cm 70.85pt;}
div.WordSection1
{page:WordSection1;}
--></style></head><body lang=DE-CH link="#467886" vlink="#96607D" style='word-wrap:break-word'><div class=WordSection1><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;mso-fareast-language:EN-US'>Correct.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;mso-fareast-language:EN-US'>Jörg<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:11.0pt;mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal style='margin-bottom:12.0pt'>Am 16.07.24, 10:45 schrieb "Hans Klaver" <hklaver@dds.nl>:<o:p></o:p></p><div><p class=MsoNormal><span lang=EN-US>On 16 July 2024, at 08:14 Jörg Straube wrote:<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US>> To narrow done where the culprit is, you might know that Wirth’s Oberon compiler has an undocumented feature allowing to write the REALs directly in hex IEEE 754 notation. With this feature you are absolutely sure what REAL we are talking about.<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US>> I use this in numerical algorithms, where it is important to have the REAL constants correct to the ulp.<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US>> <o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US>> CONST pi = 40490FDBR; (* pi is between 40490FDAR and 40490FDBR, closer to the latter *)<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US>> Out.Real(40000001R, 12);<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US>> Out.RealFix(40000001R, 12, 7)<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US>> IF FLT(2) = 40000000R THEN Out.String("FLT okay") END;<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US>> IF 3.14159265 = pi THEN Out.String(“compiler okay”) ELSE Out.String("compiler bad") END;<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US>That's a handy feature indeed, especially when testing FLT, ORD or constants.<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US>Testing with the line:<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US> IF FLT(2) = 40000000R THEN Out.String("FLT okay") END;<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p></div><div><p class=MsoNormal><span lang=EN-US>and getting the result "FLT okay" in an emulator without your proposed patch to fp.add() in risc-fp.c I conclude that that patch is not necessary. </span>Is that a sound conclusion?<o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>Regards,<o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal>Hans<o:p></o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal><o:p> </o:p></p></div></div></body></html>