[fpc-devel] Re: Faster Implementation for IntToStr

Jonas Maebe jonas.maebe at elis.ugent.be
Sun Sep 2 14:54:38 CEST 2012


On 02 Sep 2012, at 14:46, Max Nazhalov wrote:

> And also an i386-speciic assembler variants in "./FPC_SRC/rtl/i386/i386.inc", which I suspect use approach similar to yours, but I'm not sure they are "enabled"..
> 
> {$if defined(disabled) and defined(regcall)}
> procedure int_str(l:longword;out s:string);
> ...
> procedure int_str(l:longint;out s:string);
> {Optimized for speed, but balanced with size.}
> const digits:array[0..9] of cardinal=
> (0,10,100,1000,10000,
>  100000,1000000,10000000,
>  100000000,1000000000);
> ...
> {$endif}

FWIW, these are disabled because they cause crashes.


Jonas


More information about the fpc-devel mailing list