code: public static long addressOf(Object o) {
      Object[] array = new Object[] { o };
      long baseOffset = THE_UNSAFE.arrayBaseOffset(Object[].class);
      long objectAddress;
      switch (ADDRESS_SIZE) {
      case 4:
        objectAddress = THE_UNSAFE.getInt(array, baseOffset);
        break;
      case 8:
        objectAddress = THE_UNSAFE.getLong(array, baseOffset);
        break;
      default:
        throw new IllegalStateException("unsupported address size: " + ADDRESS_SIZE);
      }
      return objectAddress;
    }
docs: Get the memory address of the given object.
  
  @param o
  @return