return; }  if (phaseId == BOOTIMAGE_ROOTS) { Scanning.resetThreadCounter();
  public void collectionPhase(int phaseId) throws InlinePragma {    if (phaseId == INITIATE) {      if (Stats.gatheringStats()) {        Stats.startGC();        printPreStats();      }      Plan.setGCStatus(GC_PREPARE);      return;    }    if (phaseId == PREPARE) {      loSpace.prepare();      immortalSpace.prepare();      Memory.globalPrepareVMSpace();      return;    }    if (phaseId == ROOTS) {      Scanning.resetThreadCounter();      Plan.setGCStatus(GC_PROPER);      return;    }    if (phaseId == BOOTIMAGE_ROOTS) {      Scanning.resetThreadCounter();      return;    }    if (phaseId == RELEASE) {      loSpace.release();      immortalSpace.release();      Memory.globalReleaseVMSpace();      return;    }    if (phaseId == COMPLETE) {      Plan.setGCStatus(NOT_IN_GC);      if (Stats.gatheringStats()) {        Stats.endGC();        printPostStats();      }      return;    }    if (Options.sanityCheck.getValue() &&        getSanityChecker().collectionPhase(phaseId)) {      return;    }    Log.write("Global phase "); Log.write(Phase.getName(phaseId));     Log.writeln(" not handled.");    Assert.fail("Global phase not handled!");  }