The next 2 functions are used to compare MPIs:
Compare the multi-precision-integers number u and v returning 0 for equality, a positive value for u > v and a negative for u < v. If both numbers are opaque values (cf, gcry_mpi_set_opaque) the comparison is done by checking the bit sizes using memcmp. If only one number is an opaque value, the opaque value is less than the other number.