fls() should find the most significant bit of an int faster than a linear search can, so use it to avoid a linear search in isqrt.
Details
Details
Diff Detail
Diff Detail
- Lint
Lint Skipped - Unit
Tests Skipped
Differential D20102
Use fls to avoid a loop in isqrt dougm on Apr 30 2019, 6:12 AM. Authored by Tags None Referenced Files
Subscribers
Details fls() should find the most significant bit of an int faster than a linear search can, so use it to avoid a linear search in isqrt.
Diff Detail
|