The author of the library is here regarding 2⁶⁴ limitation.
While numbers above 2⁶⁴ cannot be directly represented as 64.64-bit fixed point, this does not mean that the library cannot work reliably with large token and ether amounts. Actually, working with arbitrary large token and ether amounts was among the main goals for the library design.
The idea is that money amount are not fractional when measured in basic units, so one need not and should not use fractional data types for them at all. Though, there are use cases when fractional math needs to be applied to money amounts. We found that most of such use cases could be reduced to the following two scenarios:
- Calculate fractional coefficient and multiply money amount by it producing another money amount. This covers interest rates, fees, margins, etc.
- Divide one money amount by another producing fractional number. This covers exchange rates, Bancor like protocols, etc.
The library has functions specifically designed for these two scenarios: “muli” and “mulu” for the former, “divi” and “divu” for the latter.