Optimize math library
ItsNickBarry opened this issue · 2 comments
ItsNickBarry commented
The Math
utils library can be optimized using bit shifts and bitwise and operations in place of division and modulo by 2, respectively. Tests should be added before updating.
ItsNickBarry commented
Required steps:
- Create
MathMock
contract for testingMath
library - Test
MathMock
- Use bit shifts
ItsNickBarry commented
Ensure that the optimization does not cause overflows or underflows.