<div dir="auto"><div><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Martin Frb via fpc-devel <<a href="mailto:fpc-devel@lists.freepascal.org">fpc-devel@lists.freepascal.org</a>> schrieb am Mi., 12. Jan. 2022, 18:06:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On 12/01/2022 17:31, Tomas Hajny via fpc-devel wrote:<br>
> On 2022-01-12 16:03, Martin Frb via fpc-devel wrote:<br>
>><br>
>><br>
>> But, if any change to the code (not even necessarily a functional<br>
>> change) would allow the compiler to do those calculations at compile<br>
>> time, then the value changes. And the entire behaviour of the app may<br>
>> change.<br>
>> Possible, this could even be a change just in optimization settings<br>
>> (or upgrading FPC), allowing the compiler to to propagate constants...<br>
>><br>
>> So does that mean, any code (that is to be compiled for Win-64bit) is<br>
>> considered "unstable" if it contains "extended" ?<br>
><br>
> Not necessarily - when targetting Win64, the user needs to be prepared <br>
> for the lower precision. However, imagine that that the user compiles <br>
> his source code for target x86_64-linux. The resulting binary and its <br>
> output will be exactly the same if the source code is compiled (with <br>
> the same options, etc.) on Linux or if it is compiled on Windows using <br>
> a Win32 hosted compiler, but it will differ if using a Win64 hosted <br>
> compiler. From compiler support point of view, this is an issue.<br>
<br>
Ok. So a question of priority. (E.g., reducing maintenance on tests?)<br></blockquote></div></div><div dir="auto"><br></div><div dir="auto">No, it's a question of unnecessary support we want. We already had users that complained that their code compiled from Win64 to x86_64-linux behaved differently than if compiled from Win32 or from x86_64-linux. We don't want to promote (and support) a compiler that doesn't produce the same code as the other two variants. </div><div dir="auto"><br></div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
>> when targetting Win64, the user needs to be prepared for the lower <br>
precision<br>
Yes, but It is one thing to be prepared for:<br>
- One (exactly one) "lower precision", and all behaviour (on that <br>
platform [1]) to be always according to that specific precision.<br>
<br>
[1] on that platform, with that exact revision of the compiler.<br>
But with any compile options, and independent of none functional <br>
changes to the users code.<br>
<br>
It is another thing to be prepared for<br>
- A random[2] "precision" that will change depending on compiler options <br>
and/or seemingly unrelated changes in the user's code<br>
<br>
[2] From the users view "random", in that the user can not predict all <br>
the factors that will affect the selection.<br>
<br>
<br>
Currently the user must be prepared for the latter.<br></blockquote></div></div><div dir="auto"><br></div><div dir="auto">No, it is deterministic, it's simply different from a native x86_64-linux compilation or one from Win32 as mentioned above and that is bad.</div><div dir="auto"><br></div><div dir="auto">Regards, </div><div dir="auto">Sven </div></div>