docs: private static int estimateQuotient(int u2, int u1, int u0, int v1, int v0)
      {
          // estimate qhat based on the first 2 digits of divisor divided by the first digit of a dividend
          long u21 = combineInts(u2, u1);
          long qhat;
          if (u2 == v1) {
              qhat = INT_BASE - 1;
          }
          else if (u21 >= 0) {
              qhat = u21 / (v1 & LONG_MASK);
          }
          else {
              qhat = divideUnsignedLong(u21, v1);
          }
  
          if (qhat == 0) {
              return 0;
          }
  
          // Check if qhat is greater than expected considering only first 3 digits of a dividend
          // This step help to eliminate all the cases when the estimation is greater than q by 2
          // and eliminates most of the cases when qhat is greater than q by 1
          //
          // u2 * b * b + u1 * b + u0 >= (v1 * b + v0) * qhat
          // u2 * b * b + u1 * b + u0 >= v1 * b * qhat + v0 * qhat
          // u2 * b * b + u1 * b - v1 * b * qhat >=  v0 * qhat - u0
          // (u21 - v1 * qhat) * b >=  v0 * qhat - u0
          // (u21 - v1 * qhat) * b + u0 >=  v0 * qhat
          // When ((u21 - v1 * qhat) * b + u0) is less than (v0 * qhat) decrease qhat by one
  
          int iterations = 0;
          long rhat = u21 - (v1 & LONG_MASK) * qhat;
          while (Long.compareUnsigned(rhat, INT_BASE) < 0 && Long.compareUnsigned((v0 & LONG_MASK) * qhat, combineInts(lowInt(rhat), u0)) > 0) {
              iterations++;
              qhat--;
              rhat += (v1 & LONG_MASK);
          }
  
          if (iterations > 2) {
              throw new IllegalStateException("qhat is greater than q by more than 2: " + iterations);
          }
  
          return (int) qhat;
      }