[fpc-pascal] Re: Why is Random(255) some 529x slower compared to Delphi7?

Jürgen Hestermann juergen.hestermann at gmx.de
Thu Dec 8 17:24:51 CET 2011



Schindler Karl-Michael schrieb:
> How disgraceful is a replacement by a less accurate solution and how about the grace to implement your own solution ;-)
>
>   
You miss the whole point. It's not a matter of coding effort but of 
backwards compatibility with existing code and also with expectations of 
people coming from Delphi/Turbo Pascal who not even question the speed 
(and accuracy) of the random() function. Of course, there is a need for 
both versions of random() but since decades I (and others) know it to be 
fast but unreliable. In FPC it suddenly turned into an accurate (which I 
didn't know so I would not even have used this reliablility) but slow 
version (which breaks my code).

In other situations the Delphi compatibilty is pulled up even if the 
implementation is outrageous. But suddenly everybody wants to depart 
from Delphi. Strange.



More information about the fpc-pascal mailing list