code: @CheckForSigned
    private int _getPutIndex (final int key)
    {
      final int readIdx = _getReadIndex (key);
      if (readIdx >= 0)
        return readIdx;
      // key not found, find insertion point
      final int startIdx = MapHelper.phiMix (key) & m_nMask;
      if (m_aKeys[startIdx] == FREE_KEY)
        return startIdx;
      int idx = startIdx;
      while (m_aKeys[idx] != FREE_KEY)
      {
        idx = _getNextIndex (idx);
        if (idx == startIdx)
          return -1;
      }
      return idx;
    }
docs: Find an index of a cell which should be updated by 'put' operation. It can
  be: 1) a cell with a given key 2) first free cell in the chain
  
  @param key
  Key to look for
  @return Index of a cell to be updated by a 'put' operation