math/big: regression in BitLen #57014
Labels
FrozenDueToAge
NeedsFix
The path to resolution is known, but the work has not been done.
release-blocker
Milestone
CL 450055 replaced big.Int.BitLen with a portable constant-time operation for fear of bits.LeadingZeros using a lookup table on some architectures (notably not on x86, which uses a hardware instruction). @drchase's benchmarks found https://perf.golang.org/search?q=upload%3A20221130.13+pkg%3Agithub.com%2Fericlagergren%2Fdecimal%2Fbenchmarks, non-crypto code with a significant performance hit for a property (constant-time) it didn't need.
Talked to @FiloSottile, and he is going to send a CL removing use of big.Int.BitLen from crypto code and restoring the old implementation.
Filing issue so we remember to submit the CL before the release.
The text was updated successfully, but these errors were encountered: