Simplify integer-based comparison
Remove GMP as a dependency