program nuske_vs_phantom_thnook
  implicit none
  integer :: n, m, q, a(0:2000,0:2000), x1, y1, x2, y2, i, j, k
  integer :: x(0:2000,0:2000), y(0:2000,0:2000), z(0:2000,0:2000)
  character(2000) :: s
  a = 0
  x = 0
  y = 0
  z = 0
  read(*,*) n, m, q
  do i = 1, n
    read(*,*) s
    s = trim(adjustl(s))
    do j = 1, m
      if (s(j:j).eq."1") a(i,j) = 1
    end do
  end do
  do i = 1, n
    do j = 1, m
      x(i,j) = x(i,j-1)+x(i-1,j)-x(i-1,j-1)+a(i,j)
      y(i,j) = y(i,j-1)+y(i-1,j)-y(i-1,j-1)+a(i,j)*a(i,j-1)
      z(i,j) = z(i,j-1)+z(i-1,j)-z(i-1,j-1)+a(i,j)*a(i-1,j)
    end do
  end do
  do k = 1, q
    read(*,*) x1, y1, x2, y2
    write(*,'(i0)') f(x,x1,y1,x2,y2)-f(y,x1,y1+1,x2,y2)-f(z,x1+1,y1,x2,y2)
  end do
  stop
contains
  integer function f(x,i1,j1,i2,j2)
    implicit none
    integer, intent(in) :: x(0:2000,0:2000), i1, j1, i2, j2
    f = x(i2,j2)-x(i2,j1-1)-x(i1-1,j2)+x(i1-1,j1-1)
    return
  end function f
end program nuske_vs_phantom_thnook
; ModuleID = 'FIRModule'
source_filename = "FIRModule"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"

@_QFEa = internal unnamed_addr global [2001 x [2001 x i32]] undef
@_QFEs = internal global [2000 x i8] undef
@_QFEx = internal unnamed_addr global [2001 x [2001 x i32]] undef
@_QFEy = internal unnamed_addr global [2001 x [2001 x i32]] undef
@_QFEz = internal unnamed_addr global [2001 x [2001 x i32]] undef
@_QQcl.2ea5df66a83518943063ffad4d5f3996 = linkonce constant [73 x i8] c"/home/ubuntu/Downloads/TheStack_IR/Collated/Fortran/Source_7255/source.f\00"
@_QQcl.31 = linkonce constant [1 x i8] c"1"
@_QQcl.28693029 = linkonce constant [4 x i8] c"(i0)"
@_QQEnvironmentDefaults = local_unnamed_addr constant ptr null

; Function Attrs: mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite)
declare void @free(ptr allocptr nocapture noundef) local_unnamed_addr #0

; Function Attrs: noreturn
define void @_QQmain() local_unnamed_addr #1 {
.preheader175.preheader:
  %0 = alloca { ptr, i64, i32, i8, i8, i8, i8 }, align 8
  %1 = alloca { ptr, i64, i32, i8, i8, i8, i8 }, align 8
  %2 = alloca { ptr, i64, i32, i8, i8, i8, i8 }, align 8
  %3 = alloca { ptr, i64, i32, i8, i8, i8, i8 }, align 8
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(16016004) @_QFEa, i8 0, i64 16016004, i1 false), !tbaa !3
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(16016004) @_QFEx, i8 0, i64 16016004, i1 false), !tbaa !3
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(16016004) @_QFEy, i8 0, i64 16016004, i1 false), !tbaa !3
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(16016004) @_QFEz, i8 0, i64 16016004, i1 false), !tbaa !3
  %11 = tail call ptr @_FortranAioBeginExternalListInput(i32 -1, ptr nonnull @_QQcl.2ea5df66a83518943063ffad4d5f3996, i32 10)
  %12 = call i1 @_FortranAioInputInteger(ptr %11, ptr nonnull %5, i32 4)
  %13 = call i1 @_FortranAioInputInteger(ptr %11, ptr nonnull %4, i32 4)
  %14 = call i1 @_FortranAioInputInteger(ptr %11, ptr nonnull %6, i32 4)
  %15 = call i32 @_FortranAioEndIoStatement(ptr %11)
  %16 = load i32, ptr %5, align 4, !tbaa !3
  %17 = icmp sgt i32 %16, 0
  br i1 %17, label %.lr.ph182, label %._crit_edge189

.lr.ph182:                                        ; preds = %.preheader175.preheader
  %18 = zext i32 %16 to i64
  %.fca.1.gep57 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %1, i64 0, i32 1
  %.fca.2.gep58 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %1, i64 0, i32 2
  %.fca.3.gep59 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %1, i64 0, i32 3
  %.fca.4.gep60 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %1, i64 0, i32 4
  %.fca.5.gep61 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %1, i64 0, i32 5
  %.fca.6.gep62 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %1, i64 0, i32 6
  %.fca.1.gep = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %3, i64 0, i32 1
  %.fca.2.gep = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %3, i64 0, i32 2
  %.fca.3.gep = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %3, i64 0, i32 3
  %.fca.4.gep = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %3, i64 0, i32 4
  %.fca.5.gep = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %3, i64 0, i32 5
  %.fca.6.gep = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %3, i64 0, i32 6
  %.fca.1.gep123 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %0, i64 0, i32 1
  %.fca.2.gep125 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %0, i64 0, i32 2
  %.fca.3.gep127 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %0, i64 0, i32 3
  %.fca.4.gep129 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %0, i64 0, i32 4
  %.fca.5.gep131 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %0, i64 0, i32 5
  %.fca.6.gep133 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %0, i64 0, i32 6
  %.fca.1.gep24 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %2, i64 0, i32 1
  %.fca.2.gep26 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %2, i64 0, i32 2
  %.fca.3.gep28 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %2, i64 0, i32 3
  %.fca.4.gep30 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %2, i64 0, i32 4
  %.fca.5.gep32 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %2, i64 0, i32 5
  %.fca.6.gep34 = getelementptr inbounds { ptr, i64, i32, i8, i8, i8, i8 }, ptr %2, i64 0, i32 6
  br label %19

19:                                               ; preds = %.lr.ph182, %._crit_edge180
  %indvars.iv195 = phi i64 [ 1, %.lr.ph182 ], [ %indvars.iv.next196, %._crit_edge180 ]
  %20 = call ptr @_FortranAioBeginExternalListInput(i32 -1, ptr nonnull @_QQcl.2ea5df66a83518943063ffad4d5f3996, i32 12)
  %21 = call i1 @_FortranAioInputAscii(ptr %20, ptr nonnull @_QFEs, i64 2000)
  %22 = call i32 @_FortranAioEndIoStatement(ptr %20)
  store ptr @_QFEs, ptr %1, align 8, !tbaa !7
  store i64 2000, ptr %.fca.1.gep57, align 8, !tbaa !7
  store i32 20180515, ptr %.fca.2.gep58, align 8, !tbaa !7
  store i8 0, ptr %.fca.3.gep59, align 4, !tbaa !7
  store i8 40, ptr %.fca.4.gep60, align 1, !tbaa !7
  store i8 0, ptr %.fca.5.gep61, align 2, !tbaa !7
  store i8 0, ptr %.fca.6.gep62, align 1, !tbaa !7
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %3, i8 0, i64 16, i1 false)
  store i32 20180515, ptr %.fca.2.gep, align 8, !tbaa !7
  store i8 0, ptr %.fca.3.gep, align 4, !tbaa !7
  store i8 40, ptr %.fca.4.gep, align 1, !tbaa !7
  store i8 2, ptr %.fca.5.gep, align 2, !tbaa !7
  store i8 0, ptr %.fca.6.gep, align 1, !tbaa !7
  %23 = call {} @_FortranAAdjustl(ptr nonnull %3, ptr nonnull %1, ptr nonnull @_QQcl.2ea5df66a83518943063ffad4d5f3996, i32 13)
  %.fca.0.load = load ptr, ptr %3, align 8, !tbaa !7
  %.fca.1.load = load i64, ptr %.fca.1.gep, align 8, !tbaa !7
  store ptr %.fca.0.load, ptr %0, align 8, !tbaa !7
  store i64 %.fca.1.load, ptr %.fca.1.gep123, align 8, !tbaa !7
  store i32 20180515, ptr %.fca.2.gep125, align 8, !tbaa !7
  store i8 0, ptr %.fca.3.gep127, align 4, !tbaa !7
  store i8 40, ptr %.fca.4.gep129, align 1, !tbaa !7
  store i8 0, ptr %.fca.5.gep131, align 2, !tbaa !7
  store i8 0, ptr %.fca.6.gep133, align 1, !tbaa !7
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %2, i8 0, i64 16, i1 false)
  store i32 20180515, ptr %.fca.2.gep26, align 8, !tbaa !7
  store i8 0, ptr %.fca.3.gep28, align 4, !tbaa !7
  store i8 40, ptr %.fca.4.gep30, align 1, !tbaa !7
  store i8 2, ptr %.fca.5.gep32, align 2, !tbaa !7
  store i8 0, ptr %.fca.6.gep34, align 1, !tbaa !7
  %24 = call {} @_FortranATrim(ptr nonnull %2, ptr nonnull %0, ptr nonnull @_QQcl.2ea5df66a83518943063ffad4d5f3996, i32 13)
  %.fca.0.load36 = load ptr, ptr %2, align 8, !tbaa !7
  %.fca.1.load39 = load i64, ptr %.fca.1.gep24, align 8, !tbaa !7
  %25 = call i64 @llvm.smin.i64(i64 %.fca.1.load39, i64 2000)
  call void @llvm.memmove.p0.p0.i64(ptr nonnull align 16 @_QFEs, ptr align 1 %.fca.0.load36, i64 %25, i1 false)
  %26 = sub i64 2000, %25
  %27 = icmp sgt i64 %26, 0
  br i1 %27, label %.lr.ph.preheader, label %._crit_edge

.lr.ph.preheader:                                 ; preds = %19
  %uglygep = getelementptr i8, ptr @_QFEs, i64 %25
  call void @llvm.memset.p0.i64(ptr align 1 %uglygep, i8 32, i64 %26, i1 false), !tbaa !3
  br label %._crit_edge

._crit_edge:                                      ; preds = %.lr.ph.preheader, %19
  call void @free(ptr %.fca.0.load36)
  call void @free(ptr %.fca.0.load)
  %28 = load i32, ptr %4, align 4, !tbaa !3
  %29 = icmp sgt i32 %28, 0
  br i1 %29, label %.lr.ph179, label %._crit_edge180

.lr.ph179:                                        ; preds = %._crit_edge
  %30 = zext i32 %28 to i64
  br label %31

31:                                               ; preds = %.lr.ph179, %38
  %indvars.iv = phi i64 [ 1, %.lr.ph179 ], [ %indvars.iv.next, %38 ]
  %32 = add nsw i64 %indvars.iv, -1
  %33 = getelementptr [2000 x [1 x i8]], ptr @_QFEs, i64 0, i64 %32
  %34 = call i32 @_FortranACharacterCompareScalar1(ptr %33, ptr nonnull @_QQcl.31, i64 1, i64 1)
  %35 = icmp eq i32 %34, 0
  br i1 %35, label %36, label %38

36:                                               ; preds = %31
  %37 = getelementptr [2001 x [2001 x i32]], ptr @_QFEa, i64 0, i64 %indvars.iv, i64 %indvars.iv195
  store i32 1, ptr %37, align 4, !tbaa !3
  br label %38

38:                                               ; preds = %36, %31
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv, %30
  br i1 %exitcond.not, label %._crit_edge180, label %31

._crit_edge180:                                   ; preds = %38, %._crit_edge
  %indvars.iv.next196 = add nuw nsw i64 %indvars.iv195, 1
  %exitcond198.not = icmp eq i64 %indvars.iv195, %18
  br i1 %exitcond198.not, label %._crit_edge183, label %19

._crit_edge183:                                   ; preds = %._crit_edge180
  %.pre = load i32, ptr %5, align 4, !tbaa !3
  %39 = icmp sgt i32 %.pre, 0
  br i1 %39, label %.lr.ph188, label %._crit_edge189

.lr.ph188:                                        ; preds = %._crit_edge183
  %40 = load i32, ptr %4, align 4, !tbaa !3
  %41 = icmp sgt i32 %40, 0
  br i1 %41, label %.lr.ph185.us.preheader, label %._crit_edge189

.lr.ph185.us.preheader:                           ; preds = %.lr.ph188
  %42 = zext i32 %40 to i64
  %43 = zext i32 %.pre to i64
  br label %.lr.ph185.us

.lr.ph185.us:                                     ; preds = %.lr.ph185.us.preheader, %._crit_edge186.us
  %indvars.iv203 = phi i64 [ 1, %.lr.ph185.us.preheader ], [ %indvars.iv.next204, %._crit_edge186.us ]
  %44 = add nsw i64 %indvars.iv203, -1
  %.phi.trans.insert = getelementptr [2001 x [2001 x i32]], ptr @_QFEx, i64 0, i64 0, i64 %indvars.iv203
  %.pre207 = load i32, ptr %.phi.trans.insert, align 4, !tbaa !3
  %.phi.trans.insert208 = getelementptr [2001 x [2001 x i32]], ptr @_QFEx, i64 0, i64 0, i64 %44
  %.pre209 = load i32, ptr %.phi.trans.insert208, align 4, !tbaa !3
  %.phi.trans.insert210 = getelementptr [2001 x [2001 x i32]], ptr @_QFEy, i64 0, i64 0, i64 %indvars.iv203
  %.pre211 = load i32, ptr %.phi.trans.insert210, align 4, !tbaa !3
  %.phi.trans.insert212 = getelementptr [2001 x [2001 x i32]], ptr @_QFEy, i64 0, i64 0, i64 %44
  %.pre213 = load i32, ptr %.phi.trans.insert212, align 4, !tbaa !3
  %.phi.trans.insert214 = getelementptr [2001 x [2001 x i32]], ptr @_QFEa, i64 0, i64 0, i64 %indvars.iv203
  %.pre215 = load i32, ptr %.phi.trans.insert214, align 4, !tbaa !3
  %.phi.trans.insert216 = getelementptr [2001 x [2001 x i32]], ptr @_QFEz, i64 0, i64 0, i64 %indvars.iv203
  %.pre217 = load i32, ptr %.phi.trans.insert216, align 4, !tbaa !3
  %.phi.trans.insert218 = getelementptr [2001 x [2001 x i32]], ptr @_QFEz, i64 0, i64 0, i64 %44
  %.pre219 = load i32, ptr %.phi.trans.insert218, align 4, !tbaa !3
  br label %45

45:                                               ; preds = %.lr.ph185.us, %45
  %46 = phi i32 [ %.pre219, %.lr.ph185.us ], [ %69, %45 ]
  %47 = phi i32 [ %.pre217, %.lr.ph185.us ], [ %75, %45 ]
  %48 = phi i32 [ %.pre215, %.lr.ph185.us ], [ %58, %45 ]
  %49 = phi i32 [ %.pre213, %.lr.ph185.us ], [ %62, %45 ]
  %50 = phi i32 [ %.pre211, %.lr.ph185.us ], [ %66, %45 ]
  %51 = phi i32 [ %.pre209, %.lr.ph185.us ], [ %54, %45 ]
  %52 = phi i32 [ %.pre207, %.lr.ph185.us ], [ %59, %45 ]
  %indvars.iv199 = phi i64 [ 1, %.lr.ph185.us ], [ %indvars.iv.next200, %45 ]
  %53 = getelementptr [2001 x [2001 x i32]], ptr @_QFEx, i64 0, i64 %indvars.iv199, i64 %44
  %54 = load i32, ptr %53, align 4, !tbaa !3
  %55 = add i32 %54, %52
  %56 = sub i32 %55, %51
  %57 = getelementptr [2001 x [2001 x i32]], ptr @_QFEa, i64 0, i64 %indvars.iv199, i64 %indvars.iv203
  %58 = load i32, ptr %57, align 4, !tbaa !3
  %59 = add i32 %56, %58
  %60 = getelementptr [2001 x [2001 x i32]], ptr @_QFEx, i64 0, i64 %indvars.iv199, i64 %indvars.iv203
  store i32 %59, ptr %60, align 4, !tbaa !3
  %61 = getelementptr [2001 x [2001 x i32]], ptr @_QFEy, i64 0, i64 %indvars.iv199, i64 %44
  %62 = load i32, ptr %61, align 4, !tbaa !3
  %63 = add i32 %62, %50
  %64 = sub i32 %63, %49
  %65 = mul i32 %48, %58
  %66 = add i32 %64, %65
  %67 = getelementptr [2001 x [2001 x i32]], ptr @_QFEy, i64 0, i64 %indvars.iv199, i64 %indvars.iv203
  store i32 %66, ptr %67, align 4, !tbaa !3
  %68 = getelementptr [2001 x [2001 x i32]], ptr @_QFEz, i64 0, i64 %indvars.iv199, i64 %44
  %69 = load i32, ptr %68, align 4, !tbaa !3
  %70 = add i32 %69, %47
  %71 = sub i32 %70, %46
  %72 = getelementptr [2001 x [2001 x i32]], ptr @_QFEa, i64 0, i64 %indvars.iv199, i64 %44
  %73 = load i32, ptr %72, align 4, !tbaa !3
  %74 = mul i32 %73, %58
  %75 = add i32 %71, %74
  %76 = getelementptr [2001 x [2001 x i32]], ptr @_QFEz, i64 0, i64 %indvars.iv199, i64 %indvars.iv203
  store i32 %75, ptr %76, align 4, !tbaa !3
  %indvars.iv.next200 = add nuw nsw i64 %indvars.iv199, 1
  %exitcond202.not = icmp eq i64 %indvars.iv199, %42
  br i1 %exitcond202.not, label %._crit_edge186.us, label %45

._crit_edge186.us:                                ; preds = %45
  %indvars.iv.next204 = add nuw nsw i64 %indvars.iv203, 1
  %exitcond206.not = icmp eq i64 %indvars.iv203, %43
  br i1 %exitcond206.not, label %._crit_edge189, label %.lr.ph185.us

._crit_edge189:                                   ; preds = %._crit_edge186.us, %.preheader175.preheader, %.lr.ph188, %._crit_edge183
  %77 = load i32, ptr %6, align 4, !tbaa !3
  %78 = icmp sgt i32 %77, 0
  br i1 %78, label %.lr.ph191.preheader, label %._crit_edge192

.lr.ph191.preheader:                              ; preds = %._crit_edge189
  %79 = zext i32 %77 to i64
  br label %.lr.ph191

.lr.ph191:                                        ; preds = %.lr.ph191.preheader, %.lr.ph191
  %80 = phi i64 [ %132, %.lr.ph191 ], [ %79, %.lr.ph191.preheader ]
  %81 = call ptr @_FortranAioBeginExternalListInput(i32 -1, ptr nonnull @_QQcl.2ea5df66a83518943063ffad4d5f3996, i32 26)
  %82 = call i1 @_FortranAioInputInteger(ptr %81, ptr nonnull %7, i32 4)
  %83 = call i1 @_FortranAioInputInteger(ptr %81, ptr nonnull %9, i32 4)
  %84 = call i1 @_FortranAioInputInteger(ptr %81, ptr nonnull %8, i32 4)
  %85 = call i1 @_FortranAioInputInteger(ptr %81, ptr nonnull %10, i32 4)
  %86 = call i32 @_FortranAioEndIoStatement(ptr %81)
  %87 = call ptr @_FortranAioBeginExternalFormattedOutput(ptr nonnull @_QQcl.28693029, i64 4, ptr null, i32 -1, ptr nonnull @_QQcl.2ea5df66a83518943063ffad4d5f3996, i32 27)
  %88 = load i32, ptr %8, align 4, !tbaa !3
  %89 = sext i32 %88 to i64
  %90 = load i32, ptr %10, align 4, !tbaa !3
  %91 = sext i32 %90 to i64
  %92 = getelementptr [2001 x [2001 x i32]], ptr @_QFEx, i64 0, i64 %91, i64 %89
  %93 = load i32, ptr %92, align 4, !tbaa !3
  %94 = load i32, ptr %9, align 4, !tbaa !3
  %95 = add i32 %94, -1
  %96 = sext i32 %95 to i64
  %97 = getelementptr [2001 x [2001 x i32]], ptr @_QFEx, i64 0, i64 %96, i64 %89
  %98 = load i32, ptr %97, align 4, !tbaa !3
  %99 = load i32, ptr %7, align 4, !tbaa !3
  %100 = add i32 %99, -1
  %101 = sext i32 %100 to i64
  %102 = getelementptr [2001 x [2001 x i32]], ptr @_QFEx, i64 0, i64 %91, i64 %101
  %103 = load i32, ptr %102, align 4, !tbaa !3
  %104 = getelementptr [2001 x [2001 x i32]], ptr @_QFEx, i64 0, i64 %96, i64 %101
  %105 = load i32, ptr %104, align 4, !tbaa !3
  %106 = getelementptr [2001 x [2001 x i32]], ptr @_QFEy, i64 0, i64 %91, i64 %89
  %107 = load i32, ptr %106, align 4, !tbaa !3
  %108 = sext i32 %94 to i64
  %109 = getelementptr [2001 x [2001 x i32]], ptr @_QFEy, i64 0, i64 %108, i64 %89
  %110 = load i32, ptr %109, align 4, !tbaa !3
  %111 = getelementptr [2001 x [2001 x i32]], ptr @_QFEy, i64 0, i64 %91, i64 %101
  %112 = load i32, ptr %111, align 4, !tbaa !3
  %113 = getelementptr [2001 x [2001 x i32]], ptr @_QFEy, i64 0, i64 %108, i64 %101
  %114 = load i32, ptr %113, align 4, !tbaa !3
  %115 = getelementptr [2001 x [2001 x i32]], ptr @_QFEz, i64 0, i64 %91, i64 %89
  %116 = load i32, ptr %115, align 4, !tbaa !3
  %117 = getelementptr [2001 x [2001 x i32]], ptr @_QFEz, i64 0, i64 %96, i64 %89
  %118 = load i32, ptr %117, align 4, !tbaa !3
  %119 = sext i32 %99 to i64
  %120 = getelementptr [2001 x [2001 x i32]], ptr @_QFEz, i64 0, i64 %91, i64 %119
  %121 = load i32, ptr %120, align 4, !tbaa !3
  %122 = getelementptr [2001 x [2001 x i32]], ptr @_QFEz, i64 0, i64 %96, i64 %119
  %123 = load i32, ptr %122, align 4, !tbaa !3
  %124 = add i32 %98, %103
  %125 = add i32 %93, %105
  %126 = add i32 %124, %107
  %.neg152.neg = sub i32 %125, %126
  %.neg161 = add i32 %.neg152.neg, %110
  %.neg162 = add i32 %.neg161, %112
  %127 = add i32 %114, %116
  %.neg158 = sub i32 %.neg162, %127
  %.neg168 = add i32 %.neg158, %118
  %128 = add i32 %.neg168, %121
  %129 = sub i32 %128, %123
  %130 = call i1 @_FortranAioOutputInteger32(ptr %87, i32 %129)
  %131 = call i32 @_FortranAioEndIoStatement(ptr %87)
  %132 = add nsw i64 %80, -1
  %133 = icmp ugt i64 %80, 1
  br i1 %133, label %.lr.ph191, label %._crit_edge192

._crit_edge192:                                   ; preds = %.lr.ph191, %._crit_edge189
  %134 = call {} @_FortranAStopStatement(i32 0, i1 false, i1 false)
  unreachable
}

; Function Attrs: mustprogress nofree norecurse nosync nounwind willreturn memory(argmem: read)
define i32 @_QFPf(ptr nocapture readonly %0, ptr nocapture readonly %1, ptr nocapture readonly %2, ptr nocapture readonly %3, ptr nocapture readonly %4) local_unnamed_addr #2 {
  %6 = load i32, ptr %3, align 4, !tbaa !3
  %7 = sext i32 %6 to i64
  %8 = load i32, ptr %4, align 4, !tbaa !3
  %9 = sext i32 %8 to i64
  %10 = getelementptr [2001 x [2001 x i32]], ptr %0, i64 0, i64 %9, i64 %7
  %11 = load i32, ptr %10, align 4, !tbaa !3
  %12 = load i32, ptr %2, align 4, !tbaa !3
  %13 = add i32 %12, -1
  %14 = sext i32 %13 to i64
  %15 = getelementptr [2001 x [2001 x i32]], ptr %0, i64 0, i64 %14, i64 %7
  %16 = load i32, ptr %15, align 4, !tbaa !3
  %17 = load i32, ptr %1, align 4, !tbaa !3
  %18 = add i32 %17, -1
  %19 = sext i32 %18 to i64
  %20 = getelementptr [2001 x [2001 x i32]], ptr %0, i64 0, i64 %9, i64 %19
  %21 = load i32, ptr %20, align 4, !tbaa !3
  %22 = getelementptr [2001 x [2001 x i32]], ptr %0, i64 0, i64 %14, i64 %19
  %23 = load i32, ptr %22, align 4, !tbaa !3
  %24 = add i32 %16, %21
  %25 = sub i32 %11, %24
  %26 = add i32 %25, %23
  ret i32 %26
}

declare ptr @_FortranAioBeginExternalListInput(i32, ptr, i32) local_unnamed_addr

declare i1 @_FortranAioInputInteger(ptr, ptr, i32) local_unnamed_addr

declare i32 @_FortranAioEndIoStatement(ptr) local_unnamed_addr

declare i1 @_FortranAioInputAscii(ptr, ptr, i64) local_unnamed_addr

declare {} @_FortranAAdjustl(ptr, ptr, ptr, i32) local_unnamed_addr

declare {} @_FortranATrim(ptr, ptr, ptr, i32) local_unnamed_addr

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memmove.p0.p0.i64(ptr nocapture writeonly, ptr nocapture readonly, i64, i1 immarg) #3

declare i32 @_FortranACharacterCompareScalar1(ptr, ptr, i64, i64) local_unnamed_addr

declare ptr @_FortranAioBeginExternalFormattedOutput(ptr, i64, ptr, i32, ptr, i32) local_unnamed_addr

declare i1 @_FortranAioOutputInteger32(ptr, i32) local_unnamed_addr

declare {} @_FortranAStopStatement(i32, i1, i1) local_unnamed_addr

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.smin.i64(i64, i64) #4

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #5

attributes #0 = { mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite) "alloc-family"="malloc" }
attributes #1 = { noreturn }
attributes #2 = { mustprogress nofree norecurse nosync nounwind willreturn memory(argmem: read) }
attributes #3 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #5 = { nocallback nofree nounwind willreturn memory(argmem: write) }

!llvm.module.flags = !{!0, !1, !2}

!0 = !{i32 2, !"Debug Info Version", i32 3}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{!4, !4, i64 0}
!4 = !{!"any data access", !5, i64 0}
!5 = !{!"any access", !6, i64 0}
!6 = !{!"Flang Type TBAA Root"}
!7 = !{!8, !8, i64 0}
!8 = !{!"descriptor member", !5, i64 0}
