Optimize integer-->string conversions#36470
Conversation
|
Awesome! |
timholy
left a comment
There was a problem hiding this comment.
This is a pretty performance-sensitive operation, so unrolling those loops is a great idea.
|
@rfourquet, I appreciate your comment I added the clamping into the I don't know the reason, but there is a little slowdown (~1 ns/number) from the original commit, but the unrolling is still effective. |
|
Bumping this. I don't have any objections to merging this. |
|
Since PR #36459 was merged, the |
|
Looks like this PR has been approved, is it ok to merge? |
This avoids invalidations caused by invalidating `StringVector(::Integer)`. This also makes `bin()`, `dec`() and `hex()` slightly faster, but does not change the Printf.
|
I've kicked off the failed CI runs, which looked unrelated. This seems good once CI passes. |
|
Thanks! |
|
I'm sorry, but I may have broken something. Edit: Line 633 in 36effbe Can you fix this on the BitIntegers.jl side? (cf. rfourquet/BitIntegers.jl#13) |
@kimikage Thank you for the report, I had no idea this |
This avoids invalidations caused by invalidating(Edit: The problem has been solved by PR #36459.)StringVector(::Integer). (cf. PR #36459)This also makes
bin(),dec()andhex()slightly faster, but does not change the Printf.