code: public static void managedBlock(ManagedBlocker blocker)
          throws InterruptedException {
          Thread t = Thread.currentThread();
          ForkJoinPool p = ((t instanceof ForkJoinWorkerThread) ?
                            ((ForkJoinWorkerThread)t).pool : null);
          while (!blocker.isReleasable()) {
              if (p == null || p.tryCompensate(null, blocker)) {
                  try {
                      do {} while (!blocker.isReleasable() && !blocker.block());
                  } finally {
                      if (p != null)
                          p.incrementActiveCount();
                  }
                  break;
              }
          }
      }
docs: Blocks in accord with the given blocker.  If the current thread
  is a {@link ForkJoinWorkerThread}, this method possibly
  arranges for a spare thread to be activated if necessary to
  ensure sufficient parallelism while the current thread is blocked.
  
  <p>If the caller is not a {@link ForkJoinTask}, this method is
  behaviorally equivalent to
  <pre> {@code
  while (!blocker.isReleasable())
  if (blocker.block())
  return;
  }</pre>
  
  If the caller is a {@code ForkJoinTask}, then the pool may
  first be expanded to ensure parallelism, and later adjusted.
  
  @param blocker the blocker
  @throws InterruptedException if blocker.block did so