int instructionOffset,
Offset instructionOffset,
  public final void setupIterator(VM_CompiledMethod cm,                                   int instructionOffset,                                   Address framePtr) {    if (DEBUG) {      VM.sysWrite("\n\t   ==========================\n");      VM.sysWrite("Reference map request made");      VM.sysWrite(" for machine code offset: ");      VM.sysWrite(instructionOffset);      VM.sysWrite("\n");      VM.sysWrite("\tframePtr: ");      VM.sysWrite(framePtr);      VM.sysWrite("\n");    }    reset();    // retrieve and save the corresponding VM_OptMachineCodeMap for    // this method and instructionOffset    compiledMethod = (VM_OptCompiledMethod)cm;    map = compiledMethod.getMCMap();    mapIndex = map.findGCMapIndex(instructionOffset);    if (mapIndex == VM_OptGCMap.ERROR) {      if (instructionOffset < 0) {        VM.sysWriteln("VM_OptGenericGCMapIterator.setupIterator called with negative instructionOffset", instructionOffset);      } else {        int possibleLen = cm.getInstructions().length() << VM.LG_INSTRUCTION_WIDTH;        if (possibleLen < instructionOffset) {          VM.sysWriteln("VM_OptGenericGCMapIterator.setupIterator called with too big of an instructionOffset");          VM.sysWriteln("offset is", instructionOffset, " bytes of machine code for method ",possibleLen);        } else {          VM.sysWriteln("VM_OptGenericGCMapIterator.setupIterator called with apparently valid offset, but no GC map found!");          VM.sysWrite("Method: ");          VM.sysWrite(compiledMethod.getMethod());          VM.sysWrite(", Machine Code (MC) Offset: ");          VM.sysWriteln(instructionOffset);          VM.sysFail("VM_OptGenericMapIterator: findGCMapIndex failed\n");        }      }      VM.sysWrite("Supposed method: ");      VM.sysWrite(compiledMethod.getMethod());      VM.sysWriteln("\nBase of its code array", VM_Magic.objectAsAddress(cm.getInstructions()));      Address ra = VM_Magic.objectAsAddress(cm.getInstructions()).add(instructionOffset);      VM.sysWriteln("Calculated actual return address is ", ra);      VM_CompiledMethod realCM = VM_CompiledMethods.findMethodForInstruction(ra);      if (realCM == null) {        VM.sysWriteln("Unable to find compiled method corresponding to this return address");      } else {        VM.sysWrite("Found compiled method ");        VM.sysWrite(realCM.getMethod());        VM.sysWriteln(" whose code contains this return address");      }      VM.sysFail("VM_OptGenericMapIterator: setupIterator failed\n");    }    // save the frame pointer    this.framePtr = framePtr;    if (DEBUG) {      VM.sysWrite("\tMethod: ");      VM.sysWrite(compiledMethod.getMethod());      VM.sysWrite("\n ");      if (mapIndex == VM_OptGCMap.NO_MAP_ENTRY) {        VM.sysWrite("... empty map found\n");      } else {        VM.sysWrite("... found a map\n");      }      if (lookForMissedReferencesInSpills) {        VM.sysWrite("FramePtr: ");        VM.sysWrite(framePtr);        VM.sysWrite("\tFirst Spill: ");        VM.sysWrite(getFirstSpillLoc());        VM.sysWrite("\tLast Spill: ");        VM.sysWrite(getLastSpillLoc());        VM.sysWrite("\n");      }    }  }