Remove bignum dependency, optimize byte operations