private LocalItem getLocalItemForReg(int ssaReg) {
    for (Map.Entry<LocalItem, ArrayList<RegisterSpec>> entry : localVariables.entrySet()) {
      for (RegisterSpec spec : entry.getValue()) {
        if (spec.getReg() == ssaReg) {
          return entry.getKey();
        }
      }
    }

    return null;
  }
Gets a local item associated with an ssa register, if one exists.

@param ssaReg {@code >= 0;} SSA register
@return {@code null-ok;} associated local item or null
android/android_framework/dex-maker/src/main/java/com/android/dx/ssa/back/FirstFitLocalCombiningAllocator.java