[libc] Refactor `BigInt` (#86137)

This patch moves most of the multiprecision logic to the `multiword`
namespace and simplifies some logic in `BigInt`. It also fully
implements the mask and count functions and increases test coverage.

`math_extras.h` is also reworked to make it more concise.

GitOrigin-RevId: a2306b65d223212dcfafe12c7299262d8d4fdcb4
12 files changed