code: public void initWorklist(boolean addAll) {
          if (addAll) {
              Block last = null;
              for (Block b = blocklistHead; b != null; b = b.nextBlock) {
                  b.nextInWorklist = b.nextBlock;
                  last = b;
              }
              worklistHead = blocklistHead;
              worklistTail = last;
          } else {
              Block largest = blocklistHead;
              if (largest == null) {
                  return;
              }
              int largestSize = largest.size();
              for (Block b = largest.nextBlock; b != null; b = b.nextBlock) {
                  int size = b.size();
                  if (size > largestSize) {
                      addToWorklist(largest);
                      largest = b;
                      largestSize = size;
                  } else {
                      addToWorklist(b);
                  }
              }
          }
      }
docs: Initializes the worklist from the block list. This assumes that the worklist is empty.
  <p>
  If {@code addAll} is {@code true}, all blocks from the block list will be added to the worklist. Otherwise, all
  but the largest block will be added.
  
  @param addAll
  controls if all blocks are added to the worklist, or all but the largest.