@NotNull
  private static List<Instruction> getReadInstructions(@NotNull List<Instruction> subGraph) {
    final List<Instruction> result = new ArrayList<>();
    for (Instruction instruction : subGraph) {
      if (instruction instanceof ReadWriteInstruction readWriteInstruction) {
        if (readWriteInstruction.getAccess().isReadAccess()) {
          result.add(readWriteInstruction);
        }
      }
    }
    return result;
  }
@NotNull
  private static List<Instruction> getReadInstructions(@NotNull List<Instruction> subGraph)