VM.assert(avail.size() == 0, avail.toString());
VM._assert(avail.size() == 0, avail.toString());
  void perform (OPT_IR ir) {    if (ir.hasReachableExceptionHandlers() || OPT_GCP.tooBig(ir)) return;    verbose = OPT_LICM.verbose;    this.ir = ir;    dominator = ir.HIRInfo.dominatorTree;    (new OPT_GlobalValueNumber()).perform(ir);    valueNumbers = ir.HIRInfo.valueNumbers;    if (true || ir.IRStage == ir.LIR) {      if (verbose) VM.sysWrite ("in GCSE for "+ir.method+"\n");      OPT_DefUse.computeDU(ir);      OPT_Simple.copyPropagation(ir);      OPT_DefUse.computeDU(ir);      GlobalCSE(ir.firstBasicBlockInCodeOrder());      if (VM.VerifyAssertions)	VM.assert(avail.size() == 0, avail.toString());    }  }    private OPT_IR ir;  private static java.util.HashMap avail = new java.util.HashMap();  private OPT_GlobalValueNumberState valueNumbers;  /**   * Do a global CSE for all instructions of block b using the given   * value numbers    * @param b   */  private void GlobalCSE (OPT_BasicBlock b) {    OPT_Instruction next, inst;    //VM.sysWrite ("Entering Block "+b+"\n");    inst = b.firstInstruction();    while (!BBend.conforms(inst)) {      next = inst.nextInstructionInCodeOrder();      if (!shouldCSE(inst)) {	inst = next;	continue;      }      OPT_RegisterOperand result = getResult(inst);      if (result == null) {	inst = next;	continue;      }      int vn = valueNumbers.getValueNumber(result);      if (vn < 0) {	inst = next;	continue;      }      Integer Vn = new Integer(vn);      OPT_Instruction former = (OPT_Instruction)avail.get(Vn);      if (former != null) {	// instead of trying to repair Heap SSA, we rebuild it after CSE 		// relink scalar dependencies	OPT_RegisterOperand formerDef = getResult(former);	OPT_Register reg = result.register;	formerDef.register.setSpansBasicBlock();	OPT_RegisterOperandEnumeration uses = OPT_DefUse.uses(reg);	while (uses.hasMoreElements()) {	  OPT_RegisterOperand use = uses.next();	  OPT_DefUse.transferUse(use, formerDef);	}	if (verbose) {	  VM.sysWrite("using      " + former + "\n" + "instead of " + 		      inst + "\n");	}	inst.remove();      }       else {	//if (verbose) VM.sysWrite ("adding ("+b+") ["+vn+"]"+inst+"\n");	avail.put(Vn, inst);      }      inst = next;    }    Enumeration e = dominator.getChildren(b);    while (e.hasMoreElements()) {      OPT_DominatorTreeNode n = (OPT_DominatorTreeNode)e.nextElement();      GlobalCSE(n.getBlock());    }    inst = b.firstInstruction();    while (!BBend.conforms(inst)) {      next = inst.nextInstructionInCodeOrder();      if (!shouldCSE(inst)) {	inst = next;	continue;      }      OPT_RegisterOperand result = getResult(inst);      if (result == null) {	inst = next;	continue;      }      int vn = valueNumbers.getValueNumber(result);      if (vn < 0) {	inst = next;	continue;      }      Integer Vn = new Integer(vn);      OPT_Instruction former = (OPT_Instruction)avail.get(Vn);      if (former == inst) {	avail.remove(Vn);	//if (verbose) VM.sysWrite ("removing ("+b+"): "+inst+"\n");      }      inst = next;    }    //VM.sysWrite ("Leaving Block "+b+"\n");  }