Small typo:
“Recent Intel processors have performance on par with Intel”
should be Recent AMD (or Zen) processors have performance…
jerchsays:
(offtopic)
I wonder if there is a really fast SIMD-based calculation possible for itoa, maybe something along bitfield multiplication and pext extraction steps. Had to deal with it recently and was quite surprised, how hard the binary number to decimal digits conversion still is.
@Lemire Do you happen to have dealt with that in the past, or have some good pointers? Sorry if I overlooked it.
Many thanks you for the link. At a first glance it seems that I also went with the small table approach (2 digits lookup after divmod 100). Will see if I can get that somewhat faster without going into big table realms.
Small typo:
“Recent Intel processors have performance on par with Intel”
should be Recent AMD (or Zen) processors have performance…
(offtopic)
I wonder if there is a really fast SIMD-based calculation possible for itoa, maybe something along bitfield multiplication and pext extraction steps. Had to deal with it recently and was quite surprised, how hard the binary number to decimal digits conversion still is.
@Lemire Do you happen to have dealt with that in the past, or have some good pointers? Sorry if I overlooked it.
You may like…
Converting integers to fix-digit representations quickly
Many thanks you for the link. At a first glance it seems that I also went with the small table approach (2 digits lookup after divmod 100). Will see if I can get that somewhat faster without going into big table realms.
Here is the optimized implementation from ClickHouse:
https://github.com/ClickHouse/ClickHouse/blob/master/base/base/itoa.h
No SIMD there, though.