Georg-Johann Lay schrieb:
Reviewing the ltoa sources [0] shows that the implementation's
speed is not award winning: it uses 32-bit div+mod.

There was propose [1] to speed ltoa by means of LUT but that
approach tries to use lookup tables for special radices.

The new proposal inlines __divmodsi4 leading to an ~35% tick gain
without increasing code size: [...]

With 5 more instructions an even more impressive speed gain of
40%..50% or even more can be worked out:

http://sourceforge.net/apps/mediawiki/mobilechessboar/nfs/project/m/mo/mobilechessboar/a/aa/Ltoa2.png

Plot is for the same 364 sample values as

[2] Plot:
http://sourceforge.net/apps/mediawiki/mobilechessboar/nfs/project/m/mo/mobilechessboar/4/48/Ltoa.png
[3] Plot Description
http://sourceforge.net/apps/mediawiki/mobilechessboar/index.php?title=File:Ltoa.png#Description


_______________________________________________
AVR-GCC-list mailing list
AVR-GCC-list@nongnu.org
https://lists.nongnu.org/mailman/listinfo/avr-gcc-list

Reply via email to